2023-11-01 14:15:57 +00:00
|
|
|
use crate::storage::*;
|
|
|
|
|
2023-11-02 11:18:43 +00:00
|
|
|
#[derive(Clone, Debug, Hash)]
|
2023-12-16 10:13:32 +00:00
|
|
|
pub struct GarageBuilder {
|
2023-11-23 16:19:35 +00:00
|
|
|
pub region: String,
|
|
|
|
pub s3_endpoint: String,
|
|
|
|
pub k2v_endpoint: String,
|
|
|
|
pub aws_access_key_id: String,
|
|
|
|
pub aws_secret_access_key: String,
|
|
|
|
pub bucket: String,
|
|
|
|
}
|
2023-11-01 14:15:57 +00:00
|
|
|
|
2023-12-16 10:13:32 +00:00
|
|
|
impl IBuilder for GarageBuilder {
|
|
|
|
fn build(&self) -> Box<dyn IStore> {
|
2023-11-01 14:15:57 +00:00
|
|
|
unimplemented!();
|
|
|
|
}
|
2023-12-16 10:13:32 +00:00
|
|
|
}
|
2023-11-02 11:18:43 +00:00
|
|
|
|
2023-12-16 10:13:32 +00:00
|
|
|
pub struct GarageStore {
|
|
|
|
dummy: String,
|
2023-11-01 14:15:57 +00:00
|
|
|
}
|
|
|
|
|
2023-12-16 10:13:32 +00:00
|
|
|
#[async_trait]
|
|
|
|
impl IStore for GarageStore {
|
|
|
|
async fn row_fetch<'a>(&self, select: &Selector<'a>) -> Result<Vec<RowVal>, StorageError> {
|
2023-11-01 14:15:57 +00:00
|
|
|
unimplemented!();
|
|
|
|
}
|
2023-12-16 10:13:32 +00:00
|
|
|
async fn row_rm<'a>(&self, select: &Selector<'a>) -> Result<(), StorageError> {
|
2023-11-15 14:56:43 +00:00
|
|
|
unimplemented!();
|
|
|
|
}
|
2023-11-16 17:27:24 +00:00
|
|
|
|
2023-12-16 10:13:32 +00:00
|
|
|
async fn row_insert(&self, values: Vec<RowVal>) -> Result<(), StorageError> {
|
2023-11-16 17:27:24 +00:00
|
|
|
unimplemented!();
|
2023-11-17 09:46:13 +00:00
|
|
|
|
|
|
|
}
|
2023-12-16 10:13:32 +00:00
|
|
|
async fn row_poll(&self, value: RowRef) -> Result<RowVal, StorageError> {
|
2023-11-02 14:28:19 +00:00
|
|
|
unimplemented!();
|
|
|
|
}
|
|
|
|
|
2023-12-16 10:13:32 +00:00
|
|
|
async fn blob_fetch(&self, blob_ref: &BlobRef) -> Result<BlobVal, StorageError> {
|
2023-11-15 14:56:43 +00:00
|
|
|
unimplemented!();
|
|
|
|
|
2023-11-01 14:15:57 +00:00
|
|
|
}
|
2023-12-16 10:13:32 +00:00
|
|
|
async fn blob_copy(&self, src: &BlobRef, dst: &BlobRef) -> Result<BlobVal, StorageError> {
|
2023-11-01 14:15:57 +00:00
|
|
|
unimplemented!();
|
|
|
|
|
2023-11-17 11:15:44 +00:00
|
|
|
}
|
2023-12-16 10:13:32 +00:00
|
|
|
async fn blob_list(&self, prefix: &str) -> Result<Vec<BlobRef>, StorageError> {
|
2023-11-01 14:15:57 +00:00
|
|
|
unimplemented!();
|
|
|
|
}
|
2023-12-16 10:13:32 +00:00
|
|
|
async fn blob_rm(&self, blob_ref: &BlobRef) -> Result<(), StorageError> {
|
2023-11-01 14:15:57 +00:00
|
|
|
unimplemented!();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|