eBay / nuraft_mesg

A session management and gRPC service layer for NuRaft.
Apache License 2.0
6 stars 11 forks source link

Exposing Leader to upper layer #63

Closed xiaoxichen closed 8 months ago

xiaoxichen commented 8 months ago

SM needs to return leader in both response of some API call as well as PGStat report.

This helps client(of SM) to know up-to-date leader and send requests to leader.

codecov-commenter commented 8 months ago

Codecov Report

Attention: 2 lines in your changes are missing coverage. Please review.

Comparison is base (6abaabb) 72.56% compared to head (5f44d5b) 75.18%.

Files Patch % Lines
src/lib/repl_service_ctx.cpp 60.00% 1 Missing and 1 partial :warning:

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #63 +/- ## ========================================== + Coverage 72.56% 75.18% +2.62% ========================================== Files 21 20 -1 Lines 831 802 -29 Branches 95 91 -4 ========================================== Hits 603 603 + Misses 168 136 -32 - Partials 60 63 +3 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

xiaoxichen commented 8 months ago

just added a few line of UT https://github.com/eBay/nuraft_mesg/compare/30b499f2e92984dc9b08c0f129cdfd4fa2c3a058..fe567bc351cbec992fb4f6ef7766768e1a62ff0d

sorry for the force-push

xiaoxichen commented 8 months ago

Thanks @szmyd , the static assert added, that is much better