Class SessionConfigBuilder
The builder to build a SessionConfig.
public sealed class SessionConfigBuilder
- Inheritance
-
SessionConfigBuilder
- Inherited Members
- Extension Methods
Methods
- ForDatabase(string)
Returns an action on SessionConfigBuilder which will set the database name to the value specified.
- WithAuthToken(IAuthToken)
Use this overwrite the authentication information for the session. This requires the server to support re-authentication on the protocol level. You can check this by calling SupportsSessionAuthAsync().
It is not possible to overwrite the authentication information for the session with no authentication, i.e., downgrade the authentication at session level. Instead, you should create a driver with no authentication and upgrade the authentication at session level as needed.
- WithBookmarkManager(IBookmarkManager)
Sets the IBookmarkManager for maintaining bookmarks for the lifetime of the session.
- WithBookmarks(params Bookmark[])
Sets the initial bookmarks to be used by the constructed session.
- WithBookmarks(params Bookmarks[])
Sets the initial bookmarks to be used by the constructed session.
- WithDatabase(string)
Sets the target database name for queries executed within the constructed session.
- WithDefaultAccessMode(AccessMode)
Sets the type of access required by the constructed session.
- WithFetchSize(long)
Sets the default fetch size. Since Bolt v4 (Neo4j 4.0+), the query running result (records) are pulled from server in batches. This fetch size defines how many records to pull in each batch. Use Infinite to disable batching and always pull all records in one batch instead.
- WithImpersonatedUser(string)
Allows the specification of a username that the user wants to impersonate for the duration of the session. Once set this cannot be changed for the duration of the session's lifetime.
- WithNotifications(Severity?, Category[])
Override configuration for which INotifications should be emitted for the lifetime of the session.
Unspecified configuration will be provided by configuration specified in the server or the driver's WithNotifications(Severity?, Category[]).
If the driver has disabled notifications with WithNotificationsDisabled(), the unspecified values will be provided by the server.
Disabling categories or severities allows the server to skip analysis for those, which can speed up query execution.
- WithNotifications(Severity?, Classification[])
This is a preview API, This API may change between minor revisions.
Override configuration for which IGqlStatusObject and INotification should be emitted for the lifetime of the session.
Unspecified configuration will be provided by configuration specified in the server or the driver's NotificationsConfig.
If the driver has disabled notifications with WithNotificationsDisabled(), the unspecified values will be provided by the server.
Disabling categories or severities allows the server to skip analysis for those, which can speed up query execution.
- WithNotificationsDisabled()
Disable all notifications for the lifetime of the session.