Add a scoped instance replica status API - #274
Draft
PranaviAncha wants to merge 3 commits into
Draft
PranaviAncha wants to merge 3 commits into
PranaviAncha wants to merge 3 commits into
Conversation
Expose one read-only observation for non-task replica states, native drain coverage, pending messages, and future assignment eligibility. Report incomplete and unsupported coverage conservatively instead of treating partial data as drained. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Treat a current-state record with no partitions as an empty replica scope. Do not require IdealState metadata for a resource that has no observed replicas. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Treat missing CURRENTSTATES and TASKCURRENTSTATES parent paths as an empty observed scope. Metadata access failures still propagate instead of producing successful coverage. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issues
Description
The response keeps non-task replica state, native drain completion, and future assignment eligibility separate. It reports an observation time, current-state sessions, state counts, ERROR replica details, pending messages, supported resource coverage, and typed blockers.
Drain completion is reported only when the FULL_AUTO and CUSTOMIZED scope is completely evaluated. Missing metadata, session inconsistencies, unsupported rebalance modes, and changes detected during the read produce conservative coverage instead of successful drain status. Existing evacuation and drain APIs retain their current behavior.
Tests
The following tests are written for this issue:
TestInstanceReplicaStatusTestPerInstanceAccessor#testGetInstanceReplicaStatusLocal code review completed
The following is the result of the
mvn testcommand on the appropriate modules:TestInstanceReplicaStatus: 8 run, 0 failures, 0 errors, 0 skippedTestPerInstanceAccessor#testGetInstanceReplicaStatus: 1 run, 0 failures, 0 errors, 0 skippedBoth commands ran with JDK 11 through the shared validation lock.
Changes that Break Backward Compatibility (Optional)
Documentation (Optional)
Commits
Code Quality
git diff --check.🤖 Generated with GitHub Copilot CLI