java.lang.Object
org.jgroups.raft.util.CommitTable
Keeps track of next_index and match_index for each cluster member (excluding this leader).
Used to (1) compute the commit_index and (2) to resend log entries to members which haven't yet seen them. Only created on the leader.
- Since:
- 0.1
- Author:
- Bela Ban
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final ConcurrentMap<org.jgroups.Address, CommitTable.Entry> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidforEach(BiConsumer<org.jgroups.Address, CommitTable.Entry> function) Applies a function to all elements of the commit tableget(org.jgroups.Address a) Set<org.jgroups.Address> keys()toString()update(org.jgroups.Address member, long match_index, long next_index, long commit_index, boolean single_resend) update(org.jgroups.Address member, long match_index, long next_index, long commit_index, boolean single_resend, boolean overwrite)
-
Field Details
-
map
-
-
Constructor Details
-
CommitTable
-
-
Method Details
-
keys
-
get
-
adjust
-
update
public CommitTable update(org.jgroups.Address member, long match_index, long next_index, long commit_index, boolean single_resend) -
update
public CommitTable update(org.jgroups.Address member, long match_index, long next_index, long commit_index, boolean single_resend, boolean overwrite) -
forEach
Applies a function to all elements of the commit table -
toString
-