Closed smerrell closed 9 years ago
This could use some discussion since it makes a pretty big change to Alter.Collection.
This change allows "additional" changes that need to happen along side the changes to the collection to be batched in the same transaction. This is very important. You don't want changes that rely on each other to pass/fail independently. :+1:
Indeed. I'm curious to see what people think about the API changes. We've gone from an Action<RavenJObject, RavenJObject>
to a Func<RavenJObject, RavenJObject, IEnumerable<ICommandData>>
. This is a pretty big API change so I'm curious if others would want to have the old API around as well or if it is ok to just change from the Action to the Func.
Yep, this would be a breaking change and would require a major version bump. Is there a better way to do this to make it backwards compatible? Or is this the cleanest way?
Merged as part of #33.
Alter.Collection can be used now to add additional ICommandData to the Alter.Collection batch. This makes it so you can safely add new documents or make changes to additional documents and have it be part of the same batch / transaction.
This changes the API of Alter.Collection though, so this might need to be changed to allow for both the Action and the Func.