risingwavelabs/risingwave · error · SinkError::Config
`compaction.write_parquet_max_row_group_rows` must be…
Error message
`compaction.write_parquet_max_row_group_rows` must be greater than 0
What it means
Raised when `write_parquet_max_row_group_rows` is Some(0). This option caps rows per Parquet row group and must be positive; zero would produce invalid/empty row groups and is rejected during config parsing.
Solutions
- Set `write_parquet_max_row_group_rows` to a positive integer, e.g. 1000000.
- Remove the option to use the default row group row cap.
Example fix
// before WITH (connector = 'iceberg', write_parquet_max_row_group_rows = 0) // after WITH (connector = 'iceberg', write_parquet_max_row_group_rows = 1000000)
Defensive patterns
Strategy: validation
Validate before calling
if (opts.write_parquet_max_row_group_rows != null && Number(opts.write_parquet_max_row_group_rows) <= 0) {
throw new Error('`compaction.write_parquet_max_row_group_rows` must be greater than 0');
} Type guard
function isValidOptionalPositive(v) {
return v == null || (Number.isInteger(v) && v > 0);
} Try / catch
try {
await createIcebergSink(opts);
} catch (e) {
if (String(e).includes('write_parquet_max_row_group_rows')) {
delete opts.write_parquet_max_row_group_rows;
return createIcebergSink(opts);
}
throw e;
} Prevention
- Use positive integers for Parquet writer limits.
- Validate all write_parquet_* options before DDL submission.
- Omit the option instead of using 0 as a placeholder.
When it happens
Trigger: CREATE SINK with `compaction.write_parquet_max_row_group_rows = 0` in the WITH options.
Common situations: Zero placeholder in generated DDL; tuning attempts where the value was left unset in a variable; misunderstanding that 0 means 'no limit'.
Understand the failure class
Background: "Invalid value" and "allowed values are" config errors: what your library rejected and how to fix it — this error's family across 41 libraries.
Related errors
- `commit-checkpoint-interval` must be greater than 0
- `compaction.delete_files_count_threshold` must be greater…
- `compaction_interval_sec` must be greater than 0
- `compaction.max_snapshots_num` must be greater than 0
- `compaction.small_files_threshold_mb` must be greater than 0
AI-assisted analysis of risingwavelabs/risingwave@6469eb736d (2026-09-11).
Data as JSON: /api/errors/058b3099c2a27c8c.
Report an issue: GitHub.
Appendix: source
Thrown at src/connector/src/sink/iceberg/config.rs:667
return Err(SinkError::Config(anyhow!(
"`compaction.small_files_threshold_mb` must be greater than 0"
)));
}
if config.delete_files_count_threshold == Some(0) {
return Err(SinkError::Config(anyhow!(
"`compaction.delete_files_count_threshold` must be greater than 0"
)));
}
if config.target_file_size_mb == Some(0) {
return Err(SinkError::Config(anyhow!(
"`compaction.target_file_size_mb` must be greater than 0"
)));
}
if config.write_parquet_max_row_group_rows == Some(0) {
return Err(SinkError::Config(anyhow!(
"`compaction.write_parquet_max_row_group_rows` must be greater than 0"
)));
}
if config.write_parquet_max_row_group_bytes == Some(0) {
return Err(SinkError::Config(anyhow!(
"`compaction.write_parquet_max_row_group_bytes` must be greater than 0"
)));
}
if config.manifest_rewrite_target_size_bytes == Some(0) {
return Err(SinkError::Config(anyhow!(
"`manifest_rewrite_target_size_bytes` must be greater than 0"
)));
}
if config.manifest_rewrite_min_count_to_merge == Some(0) {
return Err(SinkError::Config(anyhow!(View on GitHub (pinned to 6469eb736d)