pub struct AutoBuildPolicyBuilder { /* private fields */ }Expand description
Builder for AutoBuildPolicy.
Implementations§
Source§impl AutoBuildPolicyBuilder
impl AutoBuildPolicyBuilder
Sourcepub fn policy_type<VALUE: Into<AutoBuildPolicyType>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn policy_type<VALUE: Into<AutoBuildPolicyType>>( &mut self, value: VALUE, ) -> &mut Self
the policy type of the index: timing: regularly build indexes, only build once, periodical: periodically building indexes, row_count_increment: build index based on new added rows.
Sourcepub fn timing<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn timing<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
time format: LOCAL(%Y-%m-%d %H:%M:%S) and UTC(%Y-%m-%dT%H:%M:%Z), only build once when the policyType is ‘timing’ and it takes effect, When policyType is ‘periodic’, the incoming time serves as the start time of the periodic policy.
Sourcepub fn period_in_second<VALUE: Into<u64>>(&mut self, value: VALUE) -> &mut Self
pub fn period_in_second<VALUE: Into<u64>>(&mut self, value: VALUE) -> &mut Self
periodInSecond: the interval of periodic building indexes, build index periodically when policyType is ‘periodic’.
Sourcepub fn row_count_increment<VALUE: Into<u64>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn row_count_increment<VALUE: Into<u64>>( &mut self, value: VALUE, ) -> &mut Self
build an index when the number of rows in a tablet increases or decreases by more than rowCountIncrement
Sourcepub fn row_count_increment_ratio<VALUE: Into<f64>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn row_count_increment_ratio<VALUE: Into<f64>>( &mut self, value: VALUE, ) -> &mut Self
build index once when the percentage of rows added or decreased by the tablet is greater than rowCountIncrementRatio
Sourcepub fn build(&self) -> Result<AutoBuildPolicy, AutoBuildPolicyBuilderError>
pub fn build(&self) -> Result<AutoBuildPolicy, AutoBuildPolicyBuilderError>
Trait Implementations§
Source§impl Clone for AutoBuildPolicyBuilder
impl Clone for AutoBuildPolicyBuilder
Source§fn clone(&self) -> AutoBuildPolicyBuilder
fn clone(&self) -> AutoBuildPolicyBuilder
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more