Struct delta_sharing_server::manager::postgres::PostgresShareReader
source · pub struct PostgresShareReader { /* private fields */ }Expand description
ShareReader implementation leveraging Postgres as backing store.
Implementations§
sourcepub fn from_pool(pool: PgPool) -> Self
pub fn from_pool(pool: PgPool) -> Self
Create a new PostgresShareReader from an existing PgPool.
Insert a new share into the database.
Delete a share from the database.
Delete all shares from the database.
sourcepub async fn insert_schema(
&self,
share: &Share,
schema_name: &str
) -> Result<Schema, Error>
pub async fn insert_schema( &self, share: &Share, schema_name: &str ) -> Result<Schema, Error>
Insert a new schema into the database.
sourcepub async fn delete_schema_by_name(
&self,
schema_name: &str
) -> Result<(), Error>
pub async fn delete_schema_by_name( &self, schema_name: &str ) -> Result<(), Error>
Delete a schema from the database.
sourcepub async fn delete_schemas(&self) -> Result<(), Error>
pub async fn delete_schemas(&self) -> Result<(), Error>
Delete all schemas from the database.
sourcepub async fn insert_table(
&self,
schema: &Schema,
table_name: &str,
storage_path: &str,
storage_format: Option<&String>
) -> Result<Table, Error>
pub async fn insert_table( &self, schema: &Schema, table_name: &str, storage_path: &str, storage_format: Option<&String> ) -> Result<Table, Error>
Insert a new table into the database.
sourcepub async fn delete_table_by_name(
&self,
share_name: &str,
schema_name: &str,
table_name: &str
) -> Result<(), Error>
pub async fn delete_table_by_name( &self, share_name: &str, schema_name: &str, table_name: &str ) -> Result<(), Error>
Delete a table from the database.
sourcepub async fn delete_tables(&self) -> Result<(), Error>
pub async fn delete_tables(&self) -> Result<(), Error>
Delete all tables from the database.
Trait Implementations§
Fetch a list of shares stored on the sharing server store. The list
cursor is used to limit the amount of returned shares and to resume
listing from a specified point in the collection.
Get share details by name
source§fn list_schemas<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
share_name: &'life1 str,
cursor: &'life2 ListCursor
) -> Pin<Box<dyn Future<Output = Result<List<Schema>, ShareIoError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn list_schemas<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, share_name: &'life1 str, cursor: &'life2 ListCursor ) -> Pin<Box<dyn Future<Output = Result<List<Schema>, ShareIoError>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,
Fetch a list of schemas stored on the sharing server store under a
spcific share. The list cursor is used to limit the amount of returned
schemas and to resume listing from a specified point in the collection.
Fetch a list of tables stored on the sharing server store under a
spcific share combination. The list cursor is used to limit
the amount of returned tables and to resume listing from a specified
point in the collection.
source§fn list_tables_in_schema<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
share_name: &'life1 str,
schema_name: &'life2 str,
cursor: &'life3 ListCursor
) -> Pin<Box<dyn Future<Output = Result<List<Table>, ShareIoError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn list_tables_in_schema<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, share_name: &'life1 str, schema_name: &'life2 str, cursor: &'life3 ListCursor ) -> Pin<Box<dyn Future<Output = Result<List<Table>, ShareIoError>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait,
Fetch a list of tables stored on the sharing server store under a
spcific share + schema combination. The list cursor is used to limit
the amount of returned tables and to resume listing from a specified
point in the collection.
source§fn get_table<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
share_name: &'life1 str,
schema_name: &'life2 str,
table_name: &'life3 str
) -> Pin<Box<dyn Future<Output = Result<Table, ShareIoError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn get_table<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, share_name: &'life1 str, schema_name: &'life2 str, table_name: &'life3 str ) -> Pin<Box<dyn Future<Output = Result<Table, ShareIoError>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait,
Get table specifics for a combination of share + schema + name.
Auto Trait Implementations§
Blanket Implementations§
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more