feat: partial success in trace ingestion#7892
Conversation
|
@codex review |
There was a problem hiding this comment.
Code Review
This pull request implements a chunked ingestion strategy for OTLP trace spans, featuring a fallback mechanism that retries individual spans when deterministic chunk failures occur. It introduces a TraceIngestOutcome struct to support OTLP partial success responses, allowing the server to report accepted and rejected spans to the client. The parsing logic has been refactored to preserve resource and scope groupings, and the system now updates auxiliary tables for services and operations based on successfully ingested spans. Review feedback focuses on refining the error classification logic to avoid wasteful retries on metadata errors, ensuring transient errors are propagated rather than swallowed to allow client-side retries, and optimizing the parsing process by removing redundant span count calculations.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 6a05653073
ℹ️ 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".
6a05653 to
fe02acc
Compare
Signed-off-by: shuiyisong <xixing.sys@gmail.com>
Signed-off-by: shuiyisong <xixing.sys@gmail.com>
Signed-off-by: shuiyisong <xixing.sys@gmail.com>
Signed-off-by: shuiyisong <xixing.sys@gmail.com>
Signed-off-by: shuiyisong <xixing.sys@gmail.com>
fe02acc to
2811f22
Compare
Signed-off-by: shuiyisong <xixing.sys@gmail.com>
Signed-off-by: shuiyisong <xixing.sys@gmail.com>
Signed-off-by: shuiyisong <xixing.sys@gmail.com>
killme2008
left a comment
There was a problem hiding this comment.
LGTM
Recommend adding more tests that simulate span or chunk write failures.
Signed-off-by: shuiyisong <xixing.sys@gmail.com>
I hereby agree to the terms of the GreptimeDB CLA.
Refer to a related PR or issue link (optional)
close #7875
What's changed and what's your intention?
This PR changes OTLP trace ingestion to preserve valid spans when part of a request fails, instead of failing the entire batch.
PR Checklist
Please convert it to a draft if some of the following conditions are not met.