rabbitmq / ra

A Multi-Raft implementation for Erlang and Elixir that strives to be efficient and make it easier to use multiple Raft clusters in a single system.
Other
830 stars 95 forks source link

ra_aux: Expose effective machine version, current term #474

Closed the-mikedavis closed 1 month ago

the-mikedavis commented 2 months ago

A machine might want to know the effective machine version to determine if it should emit an effect like {append, NewCmd} that can only be handled once a cluster reaches an effective machine version.

This change also exposes the current_term so that the callers of the ra_aux API have essentially the same metadata as is passed to the RaMachine:apply/3 callback.