Merge branch 'cancellation' into 'main'

Fix cancellation before next query

See merge request x433485/minisql!20
This commit is contained in:
Maxim Svistunov 2024-01-28 22:23:34 +01:00
commit a184657d41

View file

@ -167,6 +167,9 @@ async fn handle_query<W>(writer: &mut W, state: &SharedDbState, query: String, t
where where
W: BackendProtoWriter + ProtoFlush + Send, W: BackendProtoWriter + ProtoFlush + Send,
{ {
// Make sure token is reset before next query
token.reset();
let operation = { let operation = {
let state = state.read().await; let state = state.read().await;
let db_schema = state.db_schema(); let db_schema = state.db_schema();