mirror of
https://github.com/GreptimeTeam/greptimedb.git
synced 2026-05-23 08:20:36 +00:00
refactor: combine Copy To and Copy From (#1197)
* refactor: combine Copy To and Copy From * Apply suggestions from code review Co-authored-by: LFC <bayinamine@gmail.com> * Apply suggestions from code review Co-authored-by: Lei, HUANG <6406592+v0y4g3r@users.noreply.github.com> --------- Co-authored-by: LFC <bayinamine@gmail.com> Co-authored-by: Lei, HUANG <6406592+v0y4g3r@users.noreply.github.com>
This commit is contained in:
@@ -190,24 +190,22 @@ pub struct DeleteRequest {
|
||||
pub key_column_values: HashMap<String, VectorRef>,
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
pub enum CopyDirection {
|
||||
Export,
|
||||
Import,
|
||||
}
|
||||
|
||||
/// Copy table request
|
||||
#[derive(Debug)]
|
||||
pub struct CopyTableRequest {
|
||||
pub catalog_name: String,
|
||||
pub schema_name: String,
|
||||
pub table_name: String,
|
||||
pub file_name: String,
|
||||
pub connection: HashMap<String, String>,
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct CopyTableFromRequest {
|
||||
pub catalog_name: String,
|
||||
pub schema_name: String,
|
||||
pub table_name: String,
|
||||
pub location: String,
|
||||
pub connection: HashMap<String, String>,
|
||||
pub pattern: Option<String>,
|
||||
pub from: String,
|
||||
pub direction: CopyDirection,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, Default)]
|
||||
|
||||
Reference in New Issue
Block a user