title: CQRS - when aggregate roots in database and in a file?
body: <p>I have started planning for my first CQRS project with event sourcing and due to time constraints part of the model will remain in XML files. What I understand from DDD is that each update is done to an aggregate root and if I want to change another aggregate root from the first one (an event is raised in the domain) which first a command to modify the second aggregate. Each change has its own transactional boundary.</p>
  
  <p>Now, what concerns me is if I have committed the change to the first aggregate (in a database) how do I handle the situation where the second aggregate (writing to a file in this case) fails?</p>
  
  <p>I could issue a command to first update the file first (second aggregate) and then issue a command to change the first aggregate but once again I could have the second command fail but in this case here we have two separate commands which seem to go against the idea of events being raised in the domain that are handled as in the first case.</p>
  
  <p>I suppose even if I wasn't using a file and all the changes were recorded in a database, there is a possibility that the second aggregate change could fail. Am I right to think this?</p>
  
  <p>Still trying to get the concepts clear in my head so any help would be appreciated.</p>