-
Notifications
You must be signed in to change notification settings - Fork 753
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
feat: add endpoint /v1/session/logout and record client session ID in meta. #16281
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 27 of 27 files at r1, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @youngsofun)
src/query/management/src/client_session.rs
line 115 at r1 (raw file):
let upsert = UpsertPB::update(ident, value) .with(seq) .with_ttl(Duration::from_secs(ttl.as_secs()));
ttl is already a Duration
Suggestion:
.with_ttl(ttl);
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 26 of 28 files reviewed, 1 unresolved discussion (waiting on @drmingdrmer)
src/query/management/src/client_session.rs
line 115 at r1 (raw file):
Previously, drmingdrmer (张炎泼) wrote…
ttl is already a Duration
Done.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 2 of 2 files at r2, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @dantengsky, @flaneur2020, and @SkyFan2002)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 12 of 12 files at r3, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @dantengsky, @flaneur2020, @SkyFan2002, and @sundy-li)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 5 of 5 files at r4, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @dantengsky, @flaneur2020, @SkyFan2002, and @sundy-li)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 10 of 10 files at r5, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @dantengsky, @flaneur2020, @SkyFan2002, and @sundy-li)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 2 of 2 files at r6, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @dantengsky, @flaneur2020, @SkyFan2002, and @sundy-li)
I hereby agree to the terms of the CLA available at: https://docs.databend.com/dev/policies/cla/
Summary
/<tenant>/<client_session_id> -> {user_name:String}
to marking a session is alive, and objects liketmptable that lives in the session should not be recycled.
/v1/session/logout
so token and session_id can be remove faster from both mem and meta.Tests
Type of change
This change is