Skip to content

Keep bookmark returned after auto-commit tx #527

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

Merged
merged 2 commits into from
Sep 6, 2018

Conversation

lutovich
Copy link
Contributor

@lutovich lutovich commented Sep 4, 2018

Auto-commit transactions return bookmarks in Bolt V3. They were previously unused. This PR makes driver extract such bookmarks and expose them via Session#lastBookmark(). It then possible for explicit and auto-commit transactions within the same session to be chained with bookmarks.

@lutovich lutovich requested a review from zhenlineo September 4, 2018 14:20
Auto-commit transactions return bookmarks in Bolt V3. They were
previously unused. This commit makes driver extract such bookmarks
and expose them via `Session#lastBookmark()`. It then possible for
explicit and auto-commit transactions within the same session to be
chained with bookmarks.
@lutovich lutovich force-pushed the 1.7-bookmark-after-auto-commit-tx branch from ee80e58 to 86cf222 Compare September 5, 2018 08:28
@zhenlineo
Copy link
Contributor

The concept of BookmarkHolder is really good. Wondering if it also makes sense to make Tx to get and set bookmark via BookmarkHolder too.

Pass it directly to the session, when the transaction is committed.
This simplifies `ExplicitTransaction` a bit by removing all bookmark
handling from it.
@lutovich
Copy link
Contributor Author

lutovich commented Sep 5, 2018

@zhenlineo I removed all the bookmark handling from transaction :)
ExplicitTransaction will now propagate bookmark directly to the session after commit.

@zhenlineo zhenlineo merged commit 9f5a32d into neo4j:1.7 Sep 6, 2018
@lutovich lutovich deleted the 1.7-bookmark-after-auto-commit-tx branch September 6, 2018 12:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants