pub struct CreateTableArgsBuilder { /* private fields */ }Expand description
Builder for CreateTableArgs.
Implementations§
Source§impl CreateTableArgsBuilder
impl CreateTableArgsBuilder
pub fn database<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn table<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
Sourcepub fn description<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn description<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
the description of table
Sourcepub fn replication<VALUE: Into<u32>>(&mut self, value: VALUE) -> &mut Self
pub fn replication<VALUE: Into<u32>>(&mut self, value: VALUE) -> &mut Self
the number of replicas(including primary replica) for a single tablet, range of [1, 10], for high availability, it is recommended >= 3, note: the number of relicas needs to less than or equal to the number of DataNodes
Sourcepub fn partition<VALUE: Into<Partition>>(&mut self, value: VALUE) -> &mut Self
pub fn partition<VALUE: Into<Partition>>(&mut self, value: VALUE) -> &mut Self
The number of partitions in the table, with a value range of [1,1000]. Suggest evaluating the number of partitions based on the expected total number of records. Suggest controlling the number of records in a single partition between 1 million and 10 million.
Sourcepub fn enable_dynamic_field(&mut self, value: bool) -> &mut Self
pub fn enable_dynamic_field(&mut self, value: bool) -> &mut Self
is suppport dynamic field, default is false
Sourcepub fn schema<VALUE: Into<TableSchema>>(&mut self, value: VALUE) -> &mut Self
pub fn schema<VALUE: Into<TableSchema>>(&mut self, value: VALUE) -> &mut Self
schema args for table
Sourcepub fn build(&self) -> Result<CreateTableArgs, CreateTableArgsBuilderError>
pub fn build(&self) -> Result<CreateTableArgs, CreateTableArgsBuilderError>
Trait Implementations§
Source§impl Clone for CreateTableArgsBuilder
impl Clone for CreateTableArgsBuilder
Source§fn clone(&self) -> CreateTableArgsBuilder
fn clone(&self) -> CreateTableArgsBuilder
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for CreateTableArgsBuilder
impl RefUnwindSafe for CreateTableArgsBuilder
impl Send for CreateTableArgsBuilder
impl Sync for CreateTableArgsBuilder
impl Unpin for CreateTableArgsBuilder
impl UnwindSafe for CreateTableArgsBuilder
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more