[fix](cloud) Prevent old clients from decoding unknown MetaServiceCode as OK - #64148
Conversation
|
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
7a1de92 to
8a2a4cc
Compare
8a2a4cc to
af9acb3
Compare
|
run buildall |
Cloud UT Coverage ReportIncrement line coverage Increment coverage report
|
TPC-H: Total hot run time: 29319 ms |
TPC-DS: Total hot run time: 169488 ms |
BE Regression && UT Coverage ReportIncrement line coverage Increment coverage report
|
FE Regression Coverage ReportIncrement line coverage |
|
/review |
There was a problem hiding this comment.
Summary:
I found one blocking compatibility/backpressure issue. The PR adds the request capability bit and correctly avoids returning the new MS_TOO_BUSY enum to requests that do not advertise support, but the unsupported path currently skips the MS-wide stress rejection entirely instead of downgrading it to a legacy retryable code. That leaves old BEs able to continue full traffic during rolling upgrade exactly when the meta service is trying to shed load.
Critical checkpoints:
- Goal/test: The goal is to gate MS_TOO_BUSY by BE capability. The capability marking and proto fields are present, and helper tests cover reflection/whitelist behavior, but the legacy unsupported-client behavior is not covered and does not match the intended downgrade behavior.
- Scope/focus: The actual PR is small and focused on cloud meta-service rate-limit compatibility.
- Concurrency/lifecycle: No new shared mutable state beyond existing atomics/whitelist lock patterns; no new lifecycle hazard found in the reviewed patch.
- Configuration: No new config item. Existing rate-limit switches are reused.
- Compatibility: Blocking issue below: old clients avoid the unknown enum, but they also bypass MS-wide stress rejection instead of receiving a known retryable status.
- Parallel paths: retry_rpc request types were updated with the capability field; manual get_rowset marks the field too.
- Tests: Added unit tests do not cover an old request without support_ms_too_busy under stress.
- Observability/performance/transactions: No additional issue found beyond the backpressure bypass risk.
User focus: No additional user-provided review focus was specified.
af9acb3 to
e9c6a9b
Compare
|
run buildall |
|
run cloudut |
FE UT Coverage ReportIncrement line coverage `` 🎉 |
BE Regression && UT Coverage ReportIncrement line coverage Increment coverage report
|
FE Regression Coverage ReportIncrement line coverage |
|
/review |
There was a problem hiding this comment.
Review summary for e9c6a9b.
I did not submit any new inline comments. The only substantiated issue I found is the legacy-request stress rejection problem already covered by existing inline thread 3379332199 on cloud/src/meta-service/meta_service_helper.h; I treated it as duplicate context rather than posting the same issue again. That thread still appears applicable to the current patch and should be resolved before merge.
Critical checkpoint conclusions:
- Goal/test: The PR tries to gate
MS_TOO_BUSYby request capability. New BE requests sent throughretry_rpcand the hand-rolled GetRowset path are marked, but the legacy no-field behavior described in the PR is already called out by the existing thread. No new test was added; the missing old-client/no-field test is part of that existing feedback. - Scope: The code change is small and limited to BE cloud request marking, meta-service preprocessing, and proto request fields.
- Concurrency/lifecycle: No new shared mutable lifecycle or lock ordering issue found.
- Config/compatibility: No new config was added. This is a rolling-upgrade/proto compatibility change; field numbers were appended, and the remaining compatibility concern is the existing duplicate thread.
- Parallel paths: The generic
retry_rpcpath and the specialsync_tablet_rowsets_unlockedGetRowset path both set the capability marker. The default MS stress whitelist maps to request types that received the new field. - Transaction/persistence/data correctness: No additional transaction, persistence, or visible-version issue found beyond the existing busy-code compatibility concern.
- Performance/observability: No new blocking performance or observability issue found. The added reflection is outside a proven hot enough path for a separate review comment.
- Validation: Verified the current PR head and GitHub changed-file list. The exact GitHub patch reverse-applies cleanly with whitespace errors treated as failures. I did not run a build or tests because this runner lacks
thirdparty/installedandthirdparty/installed/bin/protoc; the checkout is also shallow/grafted, so GitHub PR metadata was used as authoritative scope.
User focus: no additional user-provided review focus was supplied.
Subagent conclusions: optimizer-rewrite and tests-session-config both returned NO_NEW_VALUABLE_FINDINGS for the final ledger/comment set in convergence round C-001. No subagent candidate became a new inline comment; M-001 was merged as duplicate_of_existing_thread 3379332199.
TPC-H: Total hot run time: 29491 ms |
TPC-DS: Total hot run time: 180302 ms |
ClickBench: Total hot run time: 24.88 s |
d328f8d to
08f0603
Compare
47712fd to
13d30c5
Compare
13d30c5 to
b8a9fe7
Compare
|
run buildall |
TPC-H: Total hot run time: 29082 ms |
TPC-DS: Total hot run time: 168812 ms |
ClickBench: Total hot run time: 25.41 s |
FE UT Coverage ReportIncrement line coverage |
BE Regression && UT Coverage ReportIncrement line coverage Increment coverage report
|
FE Regression Coverage ReportIncrement line coverage |
|
PR approved by at least one committer and no changes requested. |
…e as OK (apache#64148) Problem Summary: Older BE versions may treat unknown meta service enum codes as OK under proto2 semantics. Add a request capability marker so MS only returns MS_TOO_BUSY to BE versions that can handle it, and downgrade otherwise. - Behavior changed: Yes (MS_TOO_BUSY is returned only when the BE request declares support; legacy requests receive KV_TXN_CONFLICT instead)
…e as OK (apache#64148) Problem Summary: Older BE versions may treat unknown meta service enum codes as OK under proto2 semantics. Add a request capability marker so MS only returns MS_TOO_BUSY to BE versions that can handle it, and downgrade otherwise. - Behavior changed: Yes (MS_TOO_BUSY is returned only when the BE request declares support; legacy requests receive KV_TXN_CONFLICT instead)
Issue Number: close #xxx
Related PR: #xxx
Problem Summary: Older BE versions may treat unknown meta service enum codes as OK under proto2 semantics. Add a request capability marker so MS only returns MS_TOO_BUSY to BE versions that can handle it, and downgrade otherwise.
None
Test: No need to test (not requested; compatibility marker and error-code gating only)
Behavior changed: Yes (MS_TOO_BUSY is returned only when the BE request declares support; legacy requests receive KV_TXN_CONFLICT instead)
Does this need documentation: No
What problem does this PR solve?
Issue Number: close #xxx
Related PR: #xxx
Problem Summary:
Release note
None
Check List (For Author)
Test
Behavior changed:
Does this need documentation?
Check List (For Reviewer who merge this PR)