fix: use PayloadConfig for OTEL ingest, make payload size configurable#1499
Conversation
Fix OTEL endpoints to use PayloadConfig instead of JsonConfig so large OTEL payloads are handled correctly replace const MAX_EVENT_PAYLOAD_SIZE with configurable value add validation to keep this size > 100 bytes and less than 100 MBs
WalkthroughThe changes convert a hardcoded maximum event payload size constant into a runtime-configurable option. A new CLI flag Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes Possibly related PRs
Suggested labels
Poem
Pre-merge checks and finishing touches❌ Failed checks (2 warnings)
✅ Passed checks (1 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: Repository UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (5)
🧰 Additional context used🧠 Learnings (2)📚 Learning: 2025-08-18T18:01:22.834ZApplied to files:
📚 Learning: 2025-08-25T01:31:41.786ZApplied to files:
🧬 Code graph analysis (4)src/cli.rs (1)
src/handlers/http/modal/query_server.rs (1)
src/option.rs (4)
src/handlers/http/modal/server.rs (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (9)
🔇 Additional comments (9)
Comment |
Fix OTEL endpoints to use PayloadConfig instead of JsonConfig so large OTEL payloads are handled correctly
replace const MAX_EVENT_PAYLOAD_SIZE with configurable value
add validation to keep this size > 100 bytes and less than 100 MBs
Summary by CodeRabbit
New Features
--max-event-payload-sizeCLI flag orP_MAX_EVENT_PAYLOAD_SIZEenvironment variableRefactor
✏️ Tip: You can customize this high-level summary in your review settings.