fix(log-ingestor): Handle killed compression jobs in CompressionJobSubmitter (fixes #1983).#1988
Conversation
WalkthroughModify compression job status handling to log Failed and Killed states using plain string formatting, use Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes 🚥 Pre-merge checks | ✅ 5 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
🧪 Generate unit tests (beta)
No actionable comments were generated in the recent review. 🎉 Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
components/log-ingestor/src/compression/compression_job_submitter.rs (1)
42-46:⚠️ Potential issue | 🔴 CriticalSpawned compression task failures are not propagated; files are not marked as failed.
The
JoinHandleis dropped, so when the spawnedsubmit_clp_compression_job_and_wait_for_completiondetects aFailedorKilledjob (lines 166–180), it only logs and exits. Thesubmit()method has already returnedOk(())to the caller, and there is no mechanism to mark the ingested files associated with that failed job as failed. Either this is handled at a different layer, or it remains TODO per the linked issue.
🤖 Fix all issues with AI agents
In `@components/log-ingestor/src/compression/compression_job_submitter.rs`:
- Line 170: In the tracing::error! calls where status_message is passed (in the
branches handling the process status, including the Killed branch), replace
status_message.unwrap_or_else(|| "None".to_string()) with
status_message.as_deref().unwrap_or("None") so you borrow an &str instead of
allocating a new String; update both occurrences that reference status_message
(the normal failure branch and the Killed branch) to use
as_deref().unwrap_or("None") so the log takes a &str with zero allocation.
Description
This PR fixes #1983 by properly handling the killed compression job inside the compression job submitter.
Checklist
breaking change.
Validation performed
Summary by CodeRabbit