Skip to content

feat(compaction): add adaptive batch sizing on failure#141

Merged
xe-nvdk merged 1 commit intomainfrom
feat/adaptive-compaction-retry
Jan 19, 2026
Merged

feat(compaction): add adaptive batch sizing on failure#141
xe-nvdk merged 1 commit intomainfrom
feat/adaptive-compaction-retry

Conversation

@xe-nvdk
Copy link
Copy Markdown
Member

@xe-nvdk xe-nvdk commented Jan 19, 2026

When compaction fails with recoverable errors (segfault, OOM kill, memory allocation errors), the batch is automatically split in half and retried recursively. This continues until either success or minimum batch size (2 files) is reached.

  • Add ClassifySubprocessError() to categorize subprocess failures
  • Add compactFilesAdaptively() for recursive batch splitting
  • Classify errors as recoverable (segfault, OOM, memory) or permanent (permission denied, file not found)
  • Non-recoverable errors are not retried to avoid wasting time
  • Maximum split depth of 4 levels (e.g., 30 → 15 → 7 → 3 files)
  • Includes comprehensive unit tests for error classification

When compaction fails with recoverable errors (segfault, OOM kill,
memory allocation errors), the batch is automatically split in half
and retried recursively. This continues until either success or
minimum batch size (2 files) is reached.

- Add ClassifySubprocessError() to categorize subprocess failures
- Add compactFilesAdaptively() for recursive batch splitting
- Classify errors as recoverable (segfault, OOM, memory) or permanent
  (permission denied, file not found)
- Non-recoverable errors are not retried to avoid wasting time
- Maximum split depth of 4 levels (e.g., 30 → 15 → 7 → 3 files)
- Includes comprehensive unit tests for error classification
@xe-nvdk xe-nvdk merged commit 355d856 into main Jan 19, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant