Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

khepri_cluster: Unify members() and nodes() with other query APIs #300

Merged
merged 1 commit into from
Oct 3, 2024

Conversation

dumbbell
Copy link
Member

@dumbbell dumbbell commented Oct 2, 2024

Why

It will be easier to work with the khepri_cluster:members() and khepri_cluster:nodes() functions if they take the same arguments as queries of the store.

How

The Timeout argument is replaced with a map of query options, the same as store queries. It supports the timeout and favor options. In particular, the favor option indicates if the query should be sent to the leader or the local Ra server.

The khepri_cluster:locally_known_*() variants became irrelevant and were deleted.

[Why]
It will be easier to work with the `members()` and `nodes()` functions
if they take the same arguments as queries of the store.

[How]
The `Timeout` argument is replaced with a map of query options, the same
as store queries. It supports the `timeout` and `favor` options. In
particular, the `favor` option indicates if the query should be sent to
the leader or the local Ra server.

The `locally_known_*()` variants became irrelevant and were deleted.
@dumbbell dumbbell added the enhancement New feature or request label Oct 2, 2024
@dumbbell dumbbell added this to the v0.17.0 milestone Oct 2, 2024
@dumbbell dumbbell requested a review from the-mikedavis October 2, 2024 15:36
@dumbbell dumbbell self-assigned this Oct 2, 2024
Copy link

codecov bot commented Oct 2, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 89.57%. Comparing base (81114c0) to head (37d1f17).
Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #300      +/-   ##
==========================================
+ Coverage   89.54%   89.57%   +0.02%     
==========================================
  Files          22       22              
  Lines        3263     3251      -12     
==========================================
- Hits         2922     2912      -10     
+ Misses        341      339       -2     
Flag Coverage Δ
erlang-25 88.74% <100.00%> (-0.08%) ⬇️
erlang-26 89.51% <100.00%> (+0.23%) ⬆️
erlang-27 89.32% <100.00%> (+0.05%) ⬆️
os-ubuntu-latest 89.57% <100.00%> (+0.20%) ⬆️
os-windows-latest 89.48% <100.00%> (-0.04%) ⬇️

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.

@dumbbell dumbbell marked this pull request as ready for review October 3, 2024 07:49
@dumbbell dumbbell merged commit a69d642 into main Oct 3, 2024
12 checks passed
@dumbbell dumbbell deleted the unify-members-api branch October 3, 2024 07:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants