Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MODE-1136 Corrected lock and unlock handling in graph batches #51

Merged
merged 1 commit into from Mar 31, 2011

Conversation

rhauch
Copy link
Contributor

@rhauch rhauch commented Mar 31, 2011

Graph.Batch methods related to locking and unlocking were incorrectly being processed immediately rather than being added to the batch (like all other operations). This results in extra sets of operations being pushed to the connector, and inconsistent/incorrect behavior and possible re-ordering of the individual requests.

This change corrects this behavior. When the Graph.Batch operations were changed to correctly use the batch, several unit and TCK tests related to observation failed. Apparently, there was some checks inside JcrObservationManager that was ignoring all net changes for a node if the net change included any lock or unlock operations. Obviously, if the net change included a lock operation and some other operations (e.g., update properties), then these other operations would be ignored and not converted into the appropriate events. Simply removing that check made this work.

After these changes were made, all unit and integration tests pass again.

Graph.Batch methods related to locking and unlocking were incorrectly being processed immediately rather than being added to the batch (like all other operations). This results in extra sets of operations being pushed to the connector, and inconsistent/incorrect behavior and possible re-ordering of the individual requests.

This change corrects this behavior. When the Graph.Batch operations were changed to correctly use the batch, several unit and TCK tests related to observation failed. Apparently, there was some checks inside JcrObservationManager that was ignoring all net changes for a node if the net change included any lock or unlock operations. Obviously, if the net change included a lock operation and some other operations (e.g., update properties), then these other operations would be ignored and not converted into the appropriate events. Simply removing that check made this work.

After these changes were made, all unit and integration tests pass again.
@rhauch rhauch merged commit f8d9b0c into ModeShape:master Mar 31, 2011
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant