-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #531 from splitgraph/inline-metastore
Add support for inline-ing metastore over Flight
- Loading branch information
Showing
20 changed files
with
433 additions
and
319 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
use crate::catalog::{ | ||
CatalogResult, CatalogStore, FunctionStore, SchemaStore, TableStore, | ||
}; | ||
use crate::repository::interface::AllDatabaseFunctionsResult; | ||
use clade::schema::ListSchemaResponse; | ||
|
||
#[derive(Clone)] | ||
pub struct MemoryStore { | ||
pub schemas: ListSchemaResponse, | ||
} | ||
|
||
#[tonic::async_trait] | ||
impl CatalogStore for MemoryStore {} | ||
|
||
#[tonic::async_trait] | ||
impl SchemaStore for MemoryStore { | ||
async fn list(&self, _catalog_name: &str) -> CatalogResult<ListSchemaResponse> { | ||
Ok(self.schemas.clone()) | ||
} | ||
} | ||
|
||
#[tonic::async_trait] | ||
impl TableStore for MemoryStore {} | ||
|
||
#[tonic::async_trait] | ||
impl FunctionStore for MemoryStore { | ||
async fn list( | ||
&self, | ||
_catalog_name: &str, | ||
) -> CatalogResult<Vec<AllDatabaseFunctionsResult>> { | ||
Ok(vec![]) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.