risingwavelabs/risingwave · error · HummockError
CompactionGroup error: {0}
Error message
CompactionGroup error: {0} What it means
HummockError::CompactionGroupError (src/storage/src/hummock/error.rs:71-72, constructor compaction_group_error at error.rs:165-167) wraps failures from the compaction-group subsystem, which manages which SSTables belong to which compaction/group configuration (e.g. groups registered with the meta service, ACL/worker-group filtering). It is thrown when group metadata lookup, registration, or update fails or is inconsistent.
Source
Thrown at src/storage/src/hummock/error.rs:71
#[error("Time-travel version expired: table {table_id}, epoch {epoch}")]
TimeTravelVersionExpired { table_id: TableId, epoch: u64 },
#[error(
"Committed epoch mismatch: table {table_id}, committed_epoch {committed_epoch}, read_epoch {read_epoch}"
)]
CommittedEpochMismatch {
table_id: TableId,
committed_epoch: u64,
read_epoch: u64,
},
#[error("Barrier read is unavailable for now. Likely the cluster is recovering")]
ReadCurrentEpoch,
#[error("CompactionExecutor error: {0}")]
CompactionExecutor(String),
#[error("FileCache error: {0}")]
FileCache(String),
#[error("SstObjectIdTracker error: {0}")]
SstObjectIdTrackerError(String),
#[error("CompactionGroup error: {0}")]
CompactionGroupError(String),
#[error("SstableUpload error: {0}")]
SstableUploadError(String),
#[error("Read backup error: {0}")]
ReadBackupError(String),
#[error("Foyer error: {0}")]
FoyerError(#[from] foyer::Error),
#[error("Other error: {0}")]
Other(String),
}
impl HummockError {
pub fn invalid_format_version(v: u32) -> HummockError {
HummockErrorInner::InvalidFormatVersion(v).into()
}
pub fn invalid_block() -> HummockError {
HummockErrorInner::InvalidBlock.into()View on GitHub (pinned to 6469eb736d)
Solutions
- Verify the compaction group referenced in the error still exists in meta (query meta's compaction-group tables or metrics)
- Re-trigger compaction or the table/group registration; transient meta desync often resolves on the next scheduling pass
- Ensure cleanup/drop operations completed fully; if a group was manually deleted, restore it or recreate affected tables/materialized views
- Upgrade all nodes to the same version if the error appeared after a rolling upgrade
Example fix
// before: compactor panics on missing group state
// after: validate group existence before scheduling
let groups = hummock_manager.list_compaction_groups().await?;
let group_exists = groups.iter().any(|g| g.id == task.compaction_group_id);
if !group_exists {
// skip/reschedule instead of surfacing CompactionGroup error
return Ok(CompactionStatus::Ignored);
} Defensive patterns
Strategy: try-catch
Validate before calling
// before scheduling compaction for a task, confirm the group exists
let groups = hummock_manager.list_compaction_groups().await?;
assert!(
groups.iter().any(|g| g.id == task.compaction_group_id),
"compaction group {} no longer exists",
task.compaction_group_id
); Type guard
fn is_compaction_group_err(e: &HummockError) -> bool {
e.to_report_string().starts_with("CompactionGroup error:")
} Try / catch
match schedule_compaction(task).await {
Err(e) if is_compaction_group_err(&e) => {
warn!(error = %e.report(), group = task.compaction_group_id, "group state invalid; rescheduling");
CompactionStatus::Ignored // let scheduler re-derive group state
}
other => other,
} Prevention
- Do not manually delete or edit compaction-group state in meta; use admin tooling
- Ensure table drops complete before removing their compaction groups
- Re-check group membership after rolling upgrades to a new version
- Treat this as an internal-inconsistency signal: capture full report and escalate if persistent
When it happens
Trigger: Looking up or updating a compaction group's config (member tables, compaction config) via the meta client fails; a table is mapped to a group that no longer exists; validating compaction-group state during compactor task scheduling.
Common situations: Objects belonging to a group deleted while a compaction task referencing them is still in flight; manual table/group manipulation or cleanup tools desynchronizing meta state; version upgrade changing group metadata schema.
Understand the failure class
Background: "This is a bug, please report it": internal invariant violations, unreachable panics, and SNH errors explained — this error's family across 47 libraries.
Related errors
- SST {0} is invalid
- Failed to get compaction task for compaction_group {}
- Unsupported task type for copy-on-write iceberg compaction:
- CompactionExecutor error: {0}
- SstObjectIdTracker error: {0}
AI-assisted analysis of risingwavelabs/risingwave@6469eb736d (2026-09-11).
Data as JSON: /api/errors/9252af6f478f45a1.
Report an issue: GitHub.