mirror of
https://github.com/GreptimeTeam/greptimedb.git
synced 2026-09-13 00:42:14 +00:00
fix(meta): address enterprise flow checks
Signed-off-by: discord9 <discord9@163.com>
This commit is contained in:
@@ -571,19 +571,16 @@ pub fn validate_flow_options(flow_task: &CreateFlowTask) -> Result<()> {
|
||||
if let Some(value) = flow_task
|
||||
.flow_options
|
||||
.get(FLOW_EXPERIMENTAL_ENABLE_INCREMENTAL_READ_KEY)
|
||||
&& value != FLOW_EXPERIMENTAL_ENABLE_INCREMENTAL_READ_SEQUENCE_RANGE
|
||||
{
|
||||
if value != FLOW_EXPERIMENTAL_ENABLE_INCREMENTAL_READ_SEQUENCE_RANGE {
|
||||
value
|
||||
.parse::<bool>()
|
||||
.map_err(|_| {
|
||||
UnexpectedSnafu {
|
||||
err_msg: format!(
|
||||
"Invalid flow option {FLOW_EXPERIMENTAL_ENABLE_INCREMENTAL_READ_KEY}: {value}"
|
||||
),
|
||||
}
|
||||
.build()
|
||||
})?;
|
||||
}
|
||||
value.parse::<bool>().map_err(|_| {
|
||||
UnexpectedSnafu {
|
||||
err_msg: format!(
|
||||
"Invalid flow option {FLOW_EXPERIMENTAL_ENABLE_INCREMENTAL_READ_KEY}: {value}"
|
||||
),
|
||||
}
|
||||
.build()
|
||||
})?;
|
||||
}
|
||||
|
||||
defer_on_missing_source(flow_task)?;
|
||||
|
||||
@@ -1776,6 +1776,7 @@ mod tests {
|
||||
create_if_not_exists: false,
|
||||
expire_after: None,
|
||||
eval_interval_secs: None,
|
||||
eval_offset_secs: None,
|
||||
comment: String::new(),
|
||||
sql: "select 1".to_string(),
|
||||
flow_options: Default::default(),
|
||||
|
||||
Reference in New Issue
Block a user