Skip to content

Commit

Permalink
chore: remove term from StateMachine.exec()
Browse files Browse the repository at this point in the history
  • Loading branch information
areyouok committed Jun 20, 2024
1 parent d2dfc4e commit 974d772
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public Decoder<? extends Encodable> createBodyDecoder(int bizType) {
}

@Override
public FiberFuture<Object> exec(long index, int term, RaftInput input) {
public FiberFuture<Object> exec(long index, RaftInput input) {
KvStatus kvStatus = this.kvStatus;
ensureRunning(kvStatus);
StrEncoder key = (StrEncoder) input.getHeader();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ private FrameCallResult exec(RaftTask rt, long index, FrameCall<Void> resumePoin
FiberFuture<Object> f = null;
Throwable execEx = null;
try {
f = stateMachine.exec(index, rt.getItem().getTerm(), input);
f = stateMachine.exec(index, input);
execCount++;
} catch (Throwable e) {
execEx = e;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public interface StateMachine extends LifeCircle, RaftCodecFactory {
/**
* this method is called in raft thread.
*/
FiberFuture<Object> exec(long index, int term, RaftInput input);
FiberFuture<Object> exec(long index, RaftInput input);

/**
* this method is called in raft thread.
Expand Down

0 comments on commit 974d772

Please sign in to comment.