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

Rename Driver.queryBookmarkManager() to Driver.queryTaskBookmarkManager() #1373

Merged
merged 1 commit into from
Feb 7, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions driver/clirr-ignored-differences.xml
Original file line number Diff line number Diff line change
Expand Up @@ -421,4 +421,10 @@
<method>org.neo4j.driver.BookmarkManager queryBookmarkManager()</method>
</difference>

<difference>
<className>org/neo4j/driver/Driver</className>
<differenceType>7012</differenceType>
<method>org.neo4j.driver.BookmarkManager queryTaskBookmarkManager()</method>
</difference>

</differences>
4 changes: 2 additions & 2 deletions driver/src/main/java/org/neo4j/driver/Driver.java
Original file line number Diff line number Diff line change
Expand Up @@ -78,10 +78,10 @@ public interface Driver extends AutoCloseable {
* Returns an instance of {@link BookmarkManager} used by {@link QueryTask} instances by default.
*
* @return bookmark manager, must not be {@code null}
* @since 5.5
* @since 5.6
*/
@Experimental
BookmarkManager queryBookmarkManager();
BookmarkManager queryTaskBookmarkManager();

/**
* Return a flag to indicate whether or not encryption is used for this driver.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ public QueryTask queryTask(String query) {
}

@Override
public BookmarkManager queryBookmarkManager() {
public BookmarkManager queryTaskBookmarkManager() {
return queryBookmarkManager;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ public <A, R, T> T execute(Collector<Record, A, R> recordCollector, ResultFinish
var sessionConfigBuilder = SessionConfig.builder();
config.database().ifPresent(sessionConfigBuilder::withDatabase);
config.impersonatedUser().ifPresent(sessionConfigBuilder::withImpersonatedUser);
config.bookmarkManager(driver.queryBookmarkManager()).ifPresent(sessionConfigBuilder::withBookmarkManager);
config.bookmarkManager(driver.queryTaskBookmarkManager()).ifPresent(sessionConfigBuilder::withBookmarkManager);
var supplier = recordCollector.supplier();
var accumulator = recordCollector.accumulator();
var finisher = recordCollector.finisher();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ void shouldExecuteAndReturnResult(RoutingControl routingControl) {
// GIVEN
var driver = mock(Driver.class);
var bookmarkManager = mock(BookmarkManager.class);
given(driver.queryBookmarkManager()).willReturn(bookmarkManager);
given(driver.queryTaskBookmarkManager()).willReturn(bookmarkManager);
var session = mock(Session.class);
given(driver.session(any(SessionConfig.class))).willReturn(session);
var txContext = mock(TransactionContext.class);
Expand Down