Skip to content

Conversation

@bseto
Copy link
Contributor

@bseto bseto commented Aug 20, 2025

./_build/kvctl failover shard 1 -n test-ns -c test-cluster0 --preferred amzFeDtPXNLPwWHIeG7Ip50cDUJT0bH1O0uYwjm7
error: EOF

after fix

./_build/kvctl failover shard 1 -n test-ns -c test-cluster0 --preferred amzFeDtPXNLPwWHIeG7Ip50cDUJT0bH1O0uYwjm7
failover shard 1 successfully, new master id: amzFeDtPXNLPwWHIeG7Ip50cDUJT0bH1O0uYwjm7.

ShouldBindJSON would give an error EOF because preferred_node_id was not in the body
https://github.com/apache/kvrocks-controller/blob/unstable/server/api/shard.go#L125

@codecov-commenter
Copy link

Codecov Report

❌ Patch coverage is 0% with 3 lines in your changes missing coverage. Please review.
✅ Project coverage is 47.13%. Comparing base (6c56470) to head (83baac3).
⚠️ Report is 83 commits behind head on unstable.

Files with missing lines Patch % Lines
cmd/client/command/failover.go 0.00% 3 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##           unstable     #344      +/-   ##
============================================
+ Coverage     43.38%   47.13%   +3.74%     
============================================
  Files            37       45       +8     
  Lines          2971     4428    +1457     
============================================
+ Hits           1289     2087     +798     
- Misses         1544     2132     +588     
- Partials        138      209      +71     
Flag Coverage Δ
unittests 47.13% <0.00%> (+3.74%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@PragmaTwice PragmaTwice merged commit 751cf95 into apache:unstable Aug 21, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants