mirror of
https://github.com/rustfs/rustfs.git
synced 2026-08-22 04:16:38 +00:00
fix(select): pin object snapshot for query lifetime (#5835)
This commit is contained in:
@@ -22,6 +22,7 @@ use super::{
|
||||
Query,
|
||||
execution::{Output, QueryStateMachine},
|
||||
logical_planner::Plan,
|
||||
session::QueryAdmission,
|
||||
};
|
||||
|
||||
#[async_trait]
|
||||
@@ -32,6 +33,14 @@ pub trait QueryDispatcher: Send + Sync {
|
||||
|
||||
async fn execute_query(&self, query: &Query) -> QueryResult<Output>;
|
||||
|
||||
fn try_reserve_query(&self) -> QueryResult<QueryAdmission> {
|
||||
Ok(QueryAdmission::unmanaged())
|
||||
}
|
||||
|
||||
async fn execute_query_admitted(&self, query: &Query, _admission: QueryAdmission) -> QueryResult<Output> {
|
||||
self.execute_query(query).await
|
||||
}
|
||||
|
||||
async fn build_logical_plan(&self, query_state_machine: Arc<QueryStateMachine>) -> QueryResult<Option<Plan>>;
|
||||
|
||||
async fn execute_logical_plan(&self, logical_plan: Plan, query_state_machine: Arc<QueryStateMachine>) -> QueryResult<Output>;
|
||||
|
||||
Reference in New Issue
Block a user