pub struct ExecutionsApi<'a> { /* private fields */ }Expand description
Executions API
Implementations§
Source§impl<'a> ExecutionsApi<'a>
impl<'a> ExecutionsApi<'a>
Sourcepub async fn execute(&self, query_id: i64) -> Result<ExecuteQueryResponse>
pub async fn execute(&self, query_id: i64) -> Result<ExecuteQueryResponse>
Execute a saved query by ID
Sourcepub async fn execute_with_options(
&self,
query_id: i64,
request: &ExecuteQueryRequest,
) -> Result<ExecuteQueryResponse>
pub async fn execute_with_options( &self, query_id: i64, request: &ExecuteQueryRequest, ) -> Result<ExecuteQueryResponse>
Execute a saved query with options
Sourcepub async fn execute_sql(
&self,
request: &ExecuteSqlRequest,
) -> Result<ExecuteQueryResponse>
pub async fn execute_sql( &self, request: &ExecuteSqlRequest, ) -> Result<ExecuteQueryResponse>
Execute raw SQL
Sourcepub async fn status(&self, execution_id: &str) -> Result<ExecutionStatus>
pub async fn status(&self, execution_id: &str) -> Result<ExecutionStatus>
Get execution status
Sourcepub async fn results(&self, execution_id: &str) -> Result<ExecutionResult>
pub async fn results(&self, execution_id: &str) -> Result<ExecutionResult>
Get execution results
Sourcepub async fn results_with_options(
&self,
execution_id: &str,
options: &GetResultsOptions,
) -> Result<ExecutionResult>
pub async fn results_with_options( &self, execution_id: &str, options: &GetResultsOptions, ) -> Result<ExecutionResult>
Get execution results with options
Sourcepub async fn results_csv(&self, execution_id: &str) -> Result<String>
pub async fn results_csv(&self, execution_id: &str) -> Result<String>
Get execution results as CSV
Sourcepub async fn results_csv_with_options(
&self,
execution_id: &str,
options: &GetResultsOptions,
) -> Result<String>
pub async fn results_csv_with_options( &self, execution_id: &str, options: &GetResultsOptions, ) -> Result<String>
Get execution results as CSV with options
Sourcepub async fn cancel(
&self,
execution_id: &str,
) -> Result<CancelExecutionResponse>
pub async fn cancel( &self, execution_id: &str, ) -> Result<CancelExecutionResponse>
Cancel an execution
Sourcepub async fn query_results(&self, query_id: i64) -> Result<ExecutionResult>
pub async fn query_results(&self, query_id: i64) -> Result<ExecutionResult>
Get the latest results for a saved query (uses cached results if available)
Sourcepub async fn query_results_with_options(
&self,
query_id: i64,
options: &GetResultsOptions,
) -> Result<ExecutionResult>
pub async fn query_results_with_options( &self, query_id: i64, options: &GetResultsOptions, ) -> Result<ExecutionResult>
Get the latest results for a saved query with options
Sourcepub async fn query_results_csv(&self, query_id: i64) -> Result<String>
pub async fn query_results_csv(&self, query_id: i64) -> Result<String>
Get the latest results for a saved query as CSV
Sourcepub async fn query_results_csv_with_options(
&self,
query_id: i64,
options: &GetResultsOptions,
) -> Result<String>
pub async fn query_results_csv_with_options( &self, query_id: i64, options: &GetResultsOptions, ) -> Result<String>
Get the latest results for a saved query as CSV with options
Sourcepub async fn run_query(
&self,
query_id: i64,
timeout_secs: Option<u64>,
) -> Result<ExecutionResult>
pub async fn run_query( &self, query_id: i64, timeout_secs: Option<u64>, ) -> Result<ExecutionResult>
Execute a query and wait for results (convenience method)
This method polls for completion with exponential backoff. Timeout is in seconds (default 300 = 5 minutes).
Sourcepub async fn run_query_with_options(
&self,
query_id: i64,
request: &ExecuteQueryRequest,
timeout_secs: Option<u64>,
) -> Result<ExecutionResult>
pub async fn run_query_with_options( &self, query_id: i64, request: &ExecuteQueryRequest, timeout_secs: Option<u64>, ) -> Result<ExecutionResult>
Execute a query with options and wait for results
Sourcepub async fn run_sql(
&self,
sql: &str,
timeout_secs: Option<u64>,
) -> Result<ExecutionResult>
pub async fn run_sql( &self, sql: &str, timeout_secs: Option<u64>, ) -> Result<ExecutionResult>
Execute SQL and wait for results (convenience method)
Sourcepub async fn run_sql_with_options(
&self,
request: &ExecuteSqlRequest,
timeout_secs: Option<u64>,
) -> Result<ExecutionResult>
pub async fn run_sql_with_options( &self, request: &ExecuteSqlRequest, timeout_secs: Option<u64>, ) -> Result<ExecutionResult>
Execute SQL with options and wait for results