feat(streaming): add Kafka two-pass analysis service - #55
Conversation
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (15)
📝 WalkthroughWalkthroughAdds the ChangesKafka streaming analysis pipeline
Estimated code review effort: 4 (Complex) | ~45 minutes Sequence Diagram(s)sequenceDiagram
participant Producer
participant ChapiStreamingProcessor
participant StreamingAnalysisEngine
participant KafkaStreamingState
participant OutputTopics
Producer->>ChapiStreamingProcessor: publish keyed CodeChangeEvent
ChapiStreamingProcessor->>KafkaStreamingState: check event and load project state
ChapiStreamingProcessor->>StreamingAnalysisEngine: analyze event
StreamingAnalysisEngine->>KafkaStreamingState: update sources and processed-event state
StreamingAnalysisEngine-->>ChapiStreamingProcessor: return AST and diagnostic events
ChapiStreamingProcessor->>OutputTopics: publish raw, resolved, and diagnostic events
✨ Finishing Touches 💡 1🛠️ Fix failing CI checks 💡
📝 Generate docstrings
🧪 Generate unit tests (beta)
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.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 03a20cf266
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| private val currentTimeMillis: () -> Long = System::currentTimeMillis, | ||
| ) { | ||
| fun process(event: CodeChangeEvent): AnalysisBatch { | ||
| if (state.isProcessed(event.eventId)) { |
There was a problem hiding this comment.
Do not deduplicate blank event IDs
When the first event with a blank eventId reaches validation, it is recorded under the empty string; every subsequent blank-ID event handled by the same task then hits this check and is silently discarded, even when it belongs to a different project or file. This suppresses the required validation diagnostics after one malformed message, so blank IDs should not be stored or checked as normal deduplication keys.
Useful? React with 👍 / 👎.
Summary by CodeRabbit
New Features
Documentation
Tests