query completion attrs3 #112
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Save Query Attrs
current_database/current_schemaFeatures
In this PR - by default embucket/lambda won't persist SessionRecord when session created. Though Session updates will be persisted.
state-store-persist-session-oncreatewhen enabled - it allows saving empty session (having just session_id)User Context behaviour changed
Previously, the context received in the login request was persisted in the state store.
Now, context such as UserName, Warehouse, Database, Schema, AccountName, ClientAppId, and ClientAppVersion is encoded directly in the authentication token.
This approach improves query latency because the query request can be sent immediately after the login request (~20 ms vs. >200 ms).
It also makes the Lambda cheaper when invoked from SnowSQL, which by default issues a login request for every query. As a result, we have fewer state-store reads and writes.
Changed behaviour: current_database / current_schema
Unittests updated & refactored