risingwavelabs/risingwave · error

no reports to aggregate for iceberg pk-index sink coordinato

Error message

no reports to aggregate for iceberg pk-index sink coordinator

What it means

`aggregate_reports` merges the per-task sink metadata reports for one epoch into a single aggregation result. If the report list is empty there is nothing to commit, and committing an empty overwrite would be wrong, so it bails with this error before `pre_commit` proceeds.

Source

Thrown at src/meta/src/manager/iceberg_pk_index_sink/coordinator.rs:568

    schema_id: i32,
    partition_spec_id: i32,
    data_files: Vec<SerializedDataFile>,
    delete_files: Vec<SerializedDataFile>,
    overwrite_files: Vec<SerializedDataFile>,
}

fn aggregate_reports(
    reports: &[PbIcebergPkIndexSinkMetadata],
) -> Result<IcebergPkIndexSinkAggResult> {
    let mut shared_schema_id: Option<i32> = None;
    let mut shared_partition_spec_id: Option<i32> = None;

    let mut data_files: Vec<SerializedDataFile> = Vec::new();
    let mut delete_files: Vec<SerializedDataFile> = Vec::new();
    let mut overwrite_files: Vec<SerializedDataFile> = Vec::new();

    if reports.is_empty() {
        bail!("no reports to aggregate for iceberg pk-index sink coordinator");
    }

    for r in reports {
        let Some(meta) = &r.metadata else {
            bail!("iceberg pk-index sink report missing metadata in aggregate_reports");
        };

        // Validate role: explicitly-Unspecified is a wire-format bug.
        let role = PbIcebergPkIndexSinkRole::try_from(r.role)
            .ok()
            .filter(|r| !matches!(r, PbIcebergPkIndexSinkRole::Unspecified))
            .ok_or_else(|| anyhow!("iceberg pk-index sink report has invalid role: {}", r.role))?;

        match role {
            PbIcebergPkIndexSinkRole::Writer => {
                let commit_result = IcebergCommitResult::try_from(meta)?;
                align_report_id(
                    commit_result.schema_id,

View on GitHub (pinned to 6469eb736d)

Solutions

  1. Check stream job / actor health for the epoch — look for writer or position-delete-merger panics or failures preceding this error.
  2. Inspect how reports were collected in `pre_commit` (epoch filtering) to ensure reports weren't dropped or mis-attributed to another epoch.
  3. Retry the epoch or restart the affected sink actors so fresh reports are produced.

Example fix

null
Defensive patterns

Strategy: validation

Validate before calling

anyhow::ensure!(!reports.is_empty(), "skipping pre_commit: no sink reports collected for this epoch");

Prevention

When it happens

Trigger: `pre_commit` invokes `aggregate_reports` with zero `PbIcebergPkIndexSinkMetadata` reports — e.g. all writers/mergers of the epoch failed before reporting, or the barrier collected no sink metadata.

Common situations: Upstream streaming job stalled or failed to produce a commit barrier with sink reports; sink actor configuration regression that removed writer tasks; collecting reports from the wrong epoch range.

Understand the failure class

Background: EmptyResultError / "no results found": when an API or scraper succeeds but returns zero rows — this error's family across 9 libraries.

Related errors


AI-assisted analysis of risingwavelabs/risingwave@6469eb736d (2026-09-11). Data as JSON: /api/errors/961edaee1c0d4927. Report an issue: GitHub.