Skip to content

Conversation

@technige
Copy link
Contributor

@technige technige commented Dec 5, 2016

No description provided.

@technige technige changed the title Bookmarking [NOT READY FOR MERGE] Bookmarking Dec 5, 2016
@apcj apcj requested a review from lutovich December 8, 2016 09:26
Copy link
Contributor

@lutovich lutovich left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nigelsmall review completed, couple small comments.

:return: Cypher result
:rtype: :class:`.StatementResult`
"""
self.last_bookmark = None
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need to do this initialization together with initialization in line 314?

Copy link
Contributor Author

@technige technige Dec 14, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, yes we do. This clears the bookmark before a run, it's not initialisation.

def commit_transaction(self):
self.run("COMMIT")
result = self.run("COMMIT")
self.connection.sync()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a way to test that we send commit and rollback messages eagerly?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tests added for that.

self.der_encoded_server_certificate = config.get("der_encoded_server_certificate")

def on_success(metadata):
self.server_version = metadata.get("server")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

server_version field is initialized here but where is it read?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just used in a test right now. It will conflict with #108 so I'll adjust it properly for that.


def begin_transaction(self):
def begin_transaction(self, bookmark=None):
""" Create a new :class:`.Transaction` within this session.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should docstring also say something about the bookmark parameter?

@technige technige merged commit a39c181 into 1.1 Dec 14, 2016
@technige technige deleted the 1.1-bookmarking branch December 14, 2016 15:10
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