Skip to main content

Database

Trait Database 

Source
pub trait Database:
    Send
    + Sync
    + Any
    + Debug
    + Display
    + 'static {
Show 39 methods // Required methods fn uri(&self) -> &str; fn read_consistency<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<ReadConsistency>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn list_namespaces<'life0, 'async_trait>( &'life0 self, request: ListNamespacesRequest, ) -> Pin<Box<dyn Future<Output = Result<ListNamespacesResponse>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn create_namespace<'life0, 'async_trait>( &'life0 self, request: CreateNamespaceRequest, ) -> Pin<Box<dyn Future<Output = Result<CreateNamespaceResponse>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn drop_namespace<'life0, 'async_trait>( &'life0 self, request: DropNamespaceRequest, ) -> Pin<Box<dyn Future<Output = Result<DropNamespaceResponse>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn describe_namespace<'life0, 'async_trait>( &'life0 self, request: DescribeNamespaceRequest, ) -> Pin<Box<dyn Future<Output = Result<DescribeNamespaceResponse>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn table_names<'life0, 'async_trait>( &'life0 self, request: TableNamesRequest, ) -> Pin<Box<dyn Future<Output = Result<Vec<String>>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn list_tables<'life0, 'async_trait>( &'life0 self, request: ListTablesRequest, ) -> Pin<Box<dyn Future<Output = Result<ListTablesResponse>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn create_table<'life0, 'async_trait>( &'life0 self, request: CreateTableRequest, ) -> Pin<Box<dyn Future<Output = Result<Arc<dyn BaseTable>>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn clone_table<'life0, 'async_trait>( &'life0 self, request: CloneTableRequest, ) -> Pin<Box<dyn Future<Output = Result<Arc<dyn BaseTable>>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn open_table<'life0, 'async_trait>( &'life0 self, request: OpenTableRequest, ) -> Pin<Box<dyn Future<Output = Result<Arc<dyn BaseTable>>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn rename_table<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>( &'life0 self, cur_name: &'life1 str, new_name: &'life2 str, cur_namespace_path: &'life3 [String], new_namespace_path: &'life4 [String], ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait, 'life4: 'async_trait; fn drop_table<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, name: &'life1 str, namespace_path: &'life2 [String], ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait; fn drop_all_tables<'life0, 'life1, 'async_trait>( &'life0 self, namespace_path: &'life1 [String], ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn as_any(&self) -> &dyn Any; fn namespace_client<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Arc<dyn LanceNamespace>>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn namespace_client_config<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<(String, HashMap<String, String>)>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; // Provided methods fn create_function_async<'life0, 'life1, 'async_trait>( &'life0 self, _request: FunctionRegistrationRequest, _namespace_path: &'life1 [String], ) -> Pin<Box<dyn Future<Output = Result<Job<FunctionVersion>>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn get_function<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, _name: &'life1 str, _version: &'life2 str, _namespace_path: &'life3 [String], ) -> Pin<Box<dyn Future<Output = Result<FunctionVersion>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait { ... } fn list_functions<'life0, 'life1, 'async_trait>( &'life0 self, _namespace_path: &'life1 [String], ) -> Pin<Box<dyn Future<Output = Result<Vec<FunctionVersion>>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn drop_function<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, _name: &'life1 str, _version: &'life2 str, _namespace_path: &'life3 [String], ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait { ... } fn drop_function_async<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, name: &'life1 str, version: &'life2 str, namespace_path: &'life3 [String], ) -> Pin<Box<dyn Future<Output = Result<(bool, Job)>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait { ... } fn create_secret<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, _name: &'life1 str, _value: &'life2 str, _namespace_path: &'life3 [String], ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait { ... } fn alter_secret<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, _name: &'life1 str, _value: &'life2 str, _namespace_path: &'life3 [String], ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait { ... } fn list_secrets<'life0, 'life1, 'async_trait>( &'life0 self, _namespace_path: &'life1 [String], ) -> Pin<Box<dyn Future<Output = Result<Vec<String>>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn drop_secret<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, _name: &'life1 str, _namespace_path: &'life2 [String], ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait { ... } fn describe_secret<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, _name: &'life1 str, _namespace_path: &'life2 [String], ) -> Pin<Box<dyn Future<Output = Result<SecretInfo>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait { ... } fn create_view<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, _name: &'life1 str, _query: &'life2 str, _namespace_path: &'life3 [String], ) -> Pin<Box<dyn Future<Output = Result<ViewDescription>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait { ... } fn describe_view<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, _name: &'life1 str, _namespace_path: &'life2 [String], ) -> Pin<Box<dyn Future<Output = Result<ViewDescription>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait { ... } fn drop_view<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, _name: &'life1 str, _namespace_path: &'life2 [String], ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait { ... } fn list_views<'life0, 'life1, 'async_trait>( &'life0 self, _namespace_path: &'life1 [String], ) -> Pin<Box<dyn Future<Output = Result<Vec<String>>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn open_job<'life0, 'life1, 'async_trait>( &'life0 self, _job_id: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<Job>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn list_jobs<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Vec<JobInfo>>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn cancel_job<'life0, 'life1, 'async_trait>( &'life0 self, _job_id: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn pause_job<'life0, 'life1, 'async_trait>( &'life0 self, _job_id: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<PauseJobStatus>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn resume_job<'life0, 'life1, 'async_trait>( &'life0 self, _job_id: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<ResumeJobStatus>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn execute_query_async<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, _query: &'life1 str, _default_namespace_path: &'life2 [String], ) -> Pin<Box<dyn Future<Output = Result<Query>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait { ... } fn describe_query<'life0, 'async_trait>( &'life0 self, _query_id: Uuid, ) -> Pin<Box<dyn Future<Output = Result<QueryDescription>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait { ... } fn drop_table_async<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, name: &'life1 str, namespace_path: &'life2 [String], ) -> Pin<Box<dyn Future<Output = Result<Job>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait { ... }
}
Expand description

The Database trait defines the interface for database implementations.

A database is responsible for managing tables and their metadata.

Required Methods§

Source

fn uri(&self) -> &str

Get the uri of the database

Source

fn read_consistency<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<ReadConsistency>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the read consistency of the database

Source

fn list_namespaces<'life0, 'async_trait>( &'life0 self, request: ListNamespacesRequest, ) -> Pin<Box<dyn Future<Output = Result<ListNamespacesResponse>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

List immediate child namespace names in the given namespace

Source

fn create_namespace<'life0, 'async_trait>( &'life0 self, request: CreateNamespaceRequest, ) -> Pin<Box<dyn Future<Output = Result<CreateNamespaceResponse>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Create a new namespace

Source

fn drop_namespace<'life0, 'async_trait>( &'life0 self, request: DropNamespaceRequest, ) -> Pin<Box<dyn Future<Output = Result<DropNamespaceResponse>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Drop a namespace

Source

fn describe_namespace<'life0, 'async_trait>( &'life0 self, request: DescribeNamespaceRequest, ) -> Pin<Box<dyn Future<Output = Result<DescribeNamespaceResponse>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Describe a namespace (get its properties)

Source

fn table_names<'life0, 'async_trait>( &'life0 self, request: TableNamesRequest, ) -> Pin<Box<dyn Future<Output = Result<Vec<String>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

👎Deprecated:

Use list_tables instead

List the names of tables in the database

§Deprecated

Use list_tables instead for pagination support

Source

fn list_tables<'life0, 'async_trait>( &'life0 self, request: ListTablesRequest, ) -> Pin<Box<dyn Future<Output = Result<ListTablesResponse>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

List tables in the database with pagination support

Source

fn create_table<'life0, 'async_trait>( &'life0 self, request: CreateTableRequest, ) -> Pin<Box<dyn Future<Output = Result<Arc<dyn BaseTable>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Create a table in the database

Source

fn clone_table<'life0, 'async_trait>( &'life0 self, request: CloneTableRequest, ) -> Pin<Box<dyn Future<Output = Result<Arc<dyn BaseTable>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Clone a table in the database.

Creates a shallow clone of the source table, sharing underlying data files but with an independent manifest. Both tables can evolve separately after cloning.

See CloneTableRequest for detailed documentation and examples.

Source

fn open_table<'life0, 'async_trait>( &'life0 self, request: OpenTableRequest, ) -> Pin<Box<dyn Future<Output = Result<Arc<dyn BaseTable>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Open a table in the database

Source

fn rename_table<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>( &'life0 self, cur_name: &'life1 str, new_name: &'life2 str, cur_namespace_path: &'life3 [String], new_namespace_path: &'life4 [String], ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait, 'life4: 'async_trait,

Rename a table in the database

Source

fn drop_table<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, name: &'life1 str, namespace_path: &'life2 [String], ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Drop a table in the database

Source

fn drop_all_tables<'life0, 'life1, 'async_trait>( &'life0 self, namespace_path: &'life1 [String], ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Drop all tables in the database

Source

fn as_any(&self) -> &dyn Any

Source

fn namespace_client<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Arc<dyn LanceNamespace>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the equivalent namespace client of this database For LanceNamespaceDatabase, it is the underlying LanceNamespace. For ListingDatabase, it is the equivalent DirectoryNamespace. For RemoteDatabase, it is the equivalent RestNamespace.

Source

fn namespace_client_config<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<(String, HashMap<String, String>)>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the configuration for constructing an equivalent namespace client. Returns (impl_type, properties) where:

  • impl_type: “dir” for DirectoryNamespace, “rest” for RestNamespace
  • properties: configuration properties for the namespace

This is useful for Python bindings where we want to return a Python namespace object rather than a Rust trait object.

Provided Methods§

Source

fn create_function_async<'life0, 'life1, 'async_trait>( &'life0 self, _request: FunctionRegistrationRequest, _namespace_path: &'life1 [String], ) -> Pin<Box<dyn Future<Output = Result<Job<FunctionVersion>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Submit a Function creation job that builds an image and registers it in namespace_path.

Source

fn get_function<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, _name: &'life1 str, _version: &'life2 str, _namespace_path: &'life3 [String], ) -> Pin<Box<dyn Future<Output = Result<FunctionVersion>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait,

Look up one exact immutable Function version.

Source

fn list_functions<'life0, 'life1, 'async_trait>( &'life0 self, _namespace_path: &'life1 [String], ) -> Pin<Box<dyn Future<Output = Result<Vec<FunctionVersion>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

List every published immutable Function version in one namespace of the remote catalog.

Source

fn drop_function<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, _name: &'life1 str, _version: &'life2 str, _namespace_path: &'life3 [String], ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait,

Remove the current Function name binding, retaining the object history.

Source

fn drop_function_async<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, name: &'life1 str, version: &'life2 str, namespace_path: &'life3 [String], ) -> Pin<Box<dyn Future<Output = Result<(bool, Job)>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait,

Start dropping a Function and return a handle to the cleanup job.

Backends without asynchronous cleanup complete the drop before returning an already-finished job.

Source

fn create_secret<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, _name: &'life1 str, _value: &'life2 str, _namespace_path: &'life3 [String], ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait,

Create a named Secret in this database. Fails if the name is taken, so a create can never silently become a rotation.

Source

fn alter_secret<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, _name: &'life1 str, _value: &'life2 str, _namespace_path: &'life3 [String], ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait,

Replace the credential behind an existing Secret. Fails if it does not exist. Every Function bound to it resolves the new value from its next execution, with no new Function version.

Source

fn list_secrets<'life0, 'life1, 'async_trait>( &'life0 self, _namespace_path: &'life1 [String], ) -> Pin<Box<dyn Future<Output = Result<Vec<String>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

The names of every Secret in this database.

Names only. No API path returns a stored credential, by construction rather than by policy.

Source

fn drop_secret<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, _name: &'life1 str, _namespace_path: &'life2 [String], ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Drop a Secret. Functions bound to it fail at their next job, which is the revocation path.

Source

fn describe_secret<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, _name: &'life1 str, _namespace_path: &'life2 [String], ) -> Pin<Box<dyn Future<Output = Result<SecretInfo>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

What the database records about one Secret: its name and timestamps, never its value.

Source

fn create_view<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, _name: &'life1 str, _query: &'life2 str, _namespace_path: &'life3 [String], ) -> Pin<Box<dyn Future<Output = Result<ViewDescription>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait,

Create a view from a defining query. The query is planned once, by the database, so one that cannot be planned is refused now rather than at the first read.

Source

fn describe_view<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, _name: &'life1 str, _namespace_path: &'life2 [String], ) -> Pin<Box<dyn Future<Output = Result<ViewDescription>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

What the database records about one view: its defining query and the schema that query resolved to.

Source

fn drop_view<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, _name: &'life1 str, _namespace_path: &'life2 [String], ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Drop a view and wait for its definition to be deleted. Its sources are untouched – a view holds no rows of its own.

Source

fn list_views<'life0, 'life1, 'async_trait>( &'life0 self, _namespace_path: &'life1 [String], ) -> Pin<Box<dyn Future<Output = Result<Vec<String>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

The names of the views in one namespace.

Source

fn open_job<'life0, 'life1, 'async_trait>( &'life0 self, _job_id: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<Job>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Open a job by id, returning a handle with its record already populated. Fails with crate::Error::JobNotFound when the server has no such job.

Source

fn list_jobs<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Vec<JobInfo>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

List server-side jobs across the database’s tables.

Source

fn cancel_job<'life0, 'life1, 'async_trait>( &'life0 self, _job_id: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Request cancellation of a job by id. Returns true if the server accepted the cancellation, false if no such job exists. Cancelling an already-terminal job is a no-op success.

Source

fn pause_job<'life0, 'life1, 'async_trait>( &'life0 self, _job_id: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<PauseJobStatus>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Pause a job by id. The job’s workers drain and it stays parked until resumed; see PauseJobStatus for the outcomes.

Source

fn resume_job<'life0, 'life1, 'async_trait>( &'life0 self, _job_id: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<ResumeJobStatus>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Resume a paused job by id. It re-enters the queue and its workers pick their work back up from checkpoints; see ResumeJobStatus.

Source

fn execute_query_async<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, _query: &'life1 str, _default_namespace_path: &'life2 [String], ) -> Pin<Box<dyn Future<Output = Result<Query>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Start executing a SQL statement on a remote database.

Source

fn describe_query<'life0, 'async_trait>( &'life0 self, _query_id: Uuid, ) -> Pin<Box<dyn Future<Output = Result<QueryDescription>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Describe a submitted SQL query by its connection-scoped id.

Source

fn drop_table_async<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, name: &'life1 str, namespace_path: &'life2 [String], ) -> Pin<Box<dyn Future<Output = Result<Job>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Start dropping a table and return a handle to the cleanup job.

Backends without asynchronous cleanup complete the drop before returning an already-finished job.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§