[DEBUG] [09/02/2025 21:13:30.622] [main] [EventStream(pekko://test)] logger log1-TestEventListener started 09:13:30,622 PM [test-pekko.actor.default-dispatcher-4] [INFO] Slf4jLogger - Slf4jLogger started [DEBUG] [09/02/2025 21:13:30.622] [main] [EventStream(pekko://test)] logger log2-Slf4jLogger started [DEBUG] [09/02/2025 21:13:30.622] [main] [EventStream(pekko://test)] Default Loggers started [INFO] [09/02/2025 21:13:30.635] [main] [ArteryTransport(pekko://test)] Remoting started with transport [Artery tcp]; listening on address [pekko://test@10.30.170.48:17355] with UID [512385547328518185] 09:13:30,635 PM [test-pekko.actor.default-dispatcher-4] [INFO] ArteryTransport - Remoting started with transport [Artery tcp]; listening on address [pekko://test@10.30.170.48:17355] with UID [512385547328518185] [INFO] [09/02/2025 21:13:30.636] [main] [Cluster(pekko://test)] Cluster Node [pekko://test@10.30.170.48:17355] - Starting up, Pekko version [1.1.5] ... 09:13:30,636 PM [test-pekko.actor.default-dispatcher-4] [INFO] Cluster - Cluster Node [pekko://test@10.30.170.48:17355] - Starting up, Pekko version [1.1.5] ... [INFO] [09/02/2025 21:13:30.639] [main] [Cluster(pekko://test)] Cluster Node [pekko://test@10.30.170.48:17355] - Registered cluster JMX MBean [pekko:type=Cluster] 09:13:30,639 PM [test-pekko.actor.default-dispatcher-4] [INFO] Cluster - Cluster Node [pekko://test@10.30.170.48:17355] - Registered cluster JMX MBean [pekko:type=Cluster] [INFO] [09/02/2025 21:13:30.639] [main] [Cluster(pekko://test)] Cluster Node [pekko://test@10.30.170.48:17355] - Started up successfully 09:13:30,639 PM [test-pekko.actor.default-dispatcher-4] [INFO] Cluster - Cluster Node [pekko://test@10.30.170.48:17355] - Started up successfully 09:13:30,641 PM [test-pekko.actor.default-dispatcher-4] [INFO] Cluster - Cluster Node [pekko://test@10.30.170.48:17355] - No downing-provider-class configured, manual cluster downing required, see https://pekko.apache.org/docs/pekko/current/typed/cluster.html#downing 09:13:30,641 PM [test-pekko.actor.default-dispatcher-4] [INFO] Cluster - Cluster Node [pekko://test@10.30.170.48:17355] - No seed-nodes configured, manual cluster join required, see https://pekko.apache.org/docs/pekko/current/typed/cluster.html#joining [INFO] [09/02/2025 21:13:30.641] [test-pekko.actor.internal-dispatcher-2] [Cluster(pekko://test)] Cluster Node [pekko://test@10.30.170.48:17355] - No downing-provider-class configured, manual cluster downing required, see https://pekko.apache.org/docs/pekko/current/typed/cluster.html#downing [INFO] [09/02/2025 21:13:30.641] [test-pekko.actor.internal-dispatcher-2] [Cluster(pekko://test)] Cluster Node [pekko://test@10.30.170.48:17355] - No seed-nodes configured, manual cluster join required, see https://pekko.apache.org/docs/pekko/current/typed/cluster.html#joining 09:13:30,653 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:30,765 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): In requestVote: RequestVote{term=1, candidateId=test, lastLogIndex=10000, lastLogTerm=999} - currentTerm: 1, votedFor: test, lastIndex: 1, lastTerm: 1 09:13:30,765 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): requestVote returning: RequestVoteReply{term=1, voteGranted=true} 09:13:30,767 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior424#536981657] 09:13:30,795 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower425#864741100] 09:13:30,795 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader426#577395384] 09:13:30,805 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:30,808 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader-1, prevLogIndex=-1, prevLogTerm=-1, leaderCommit=2, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[SimpleReplicatedLogEntry [index=0, term=2, payload=zero]]} 09:13:30,809 PM [main] [DEBUG] Follower - follower (Follower): Number of entries to be appended = 1 09:13:30,809 PM [main] [DEBUG] Follower - follower (Follower): matchEntry SimpleReplicatedLogEntry [index=0, term=2, payload=zero] is present: existingEntryTerm: 2 09:13:30,809 PM [main] [DEBUG] Follower - follower (Follower): After cleanup, lastIndex: 0, entries to be added from: 1 09:13:30,809 PM [main] [DEBUG] Follower - follower (Follower): Log size is now 1 09:13:30,809 PM [main] [DEBUG] Follower - follower (Follower): Commit index set to 0 09:13:30,809 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries returning : AppendEntriesReply{term=2, success=true, followerId=follower, logLastIndex=0, logLastTerm=2, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:30,809 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader-1, need to catch up to 2 09:13:30,809 PM [main] [DEBUG] Follower - follower (Follower): applyLogToStateMachine, appendEntries.getLeaderCommit(): 2, context.getLastApplied(): -1, lastIndex(): 0 09:13:30,811 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Setting last applied to 0 09:13:30,811 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 0 09:13:30,811 PM [main] [WARN] RaftActorBehavior - follower (Follower): Missing index 1 from log. Cannot apply state. Ignoring 1 to 2 09:13:30,811 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior427#75009681] 09:13:30,822 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower428#-213988734] 09:13:30,822 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader429#-999732401] 09:13:30,826 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:30,828 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): In requestVote: RequestVote{term=1, candidateId=test, lastLogIndex=1999, lastLogTerm=1} - currentTerm: 1, votedFor: test, lastIndex: 2000, lastTerm: 1 09:13:30,829 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): requestVote returning: RequestVoteReply{term=1, voteGranted=false} 09:13:30,829 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior430#-856292483] 09:13:30,840 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower431#775185495] 09:13:30,840 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader432#-1073470616] 09:13:30,844 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:30,845 PM [main] [INFO] Follower - follower (Follower): Term 100 in "AppendEntries{term=100, leaderId=leader-1, prevLogIndex=0, prevLogTerm=0, leaderCommit=1, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[]}" message is greater than follower's term 1 - updating term 09:13:30,846 PM [main] [INFO] Follower - follower (Follower): The prevLogIndex 0 was found in the log but the term 1 is not equal to the append entries prevLogTerm 0 - lastIndex: 0, snapshotIndex: -1, snapshotTerm: -1 09:13:30,846 PM [main] [INFO] Follower - follower (Follower): Follower is out-of-sync so sending negative reply: AppendEntriesReply{term=100, success=false, followerId=follower, logLastIndex=0, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:30,847 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader-1, need to catch up to 1 09:13:30,848 PM [main] [INFO] Follower - follower (Follower): Term 100 in "AppendEntriesReply{term=100, success=false, followerId=follower-1, logLastIndex=100, logLastTerm=100, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=0, raftVersion=5, recipientRaftVersion=5}" message is greater than follower's term 1 - updating term 09:13:30,851 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Found higher term in RequestVote rpc, verifying whether it's safe to update term. 09:13:30,851 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Cluster state: [] 09:13:30,851 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Candidate in requestVote:RequestVote{term=100, candidateId=candidate-1, lastLogIndex=10, lastLogTerm=100} with higher term appears reachable, updating term. 09:13:30,851 PM [main] [INFO] Follower - follower (Follower): Term 100 in "RequestVote{term=100, candidateId=candidate-1, lastLogIndex=10, lastLogTerm=100}" message is greater than follower's term 1 - updating term 09:13:30,852 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): In requestVote: RequestVote{term=100, candidateId=candidate-1, lastLogIndex=10, lastLogTerm=100} - currentTerm: 100, votedFor: null, lastIndex: 0, lastTerm: 1 09:13:30,852 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): requestVote returning: RequestVoteReply{term=100, voteGranted=true} 09:13:30,853 PM [main] [INFO] Follower - follower (Follower): Term 100 in "RequestVoteReply{term=100, voteGranted=false}" message is greater than follower's term 1 - updating term 09:13:30,854 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior433#-1803304550] 09:13:30,855 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower434#-1354922173] 09:13:30,855 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader435#-2088639344] 09:13:30,859 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:30,859 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 0 09:13:30,860 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 0 09:13:30,861 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:30,861 PM [main] [DEBUG] SnapshotManager - test: fakeSnapshot purging log to 0 for term 1 09:13:30,862 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 2 09:13:30,862 PM [main] [DEBUG] SnapshotManager - test: fakeSnapshot purging log to 1 for term 1 09:13:30,863 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 2 09:13:30,863 PM [main] [DEBUG] SnapshotManager - test: fakeSnapshot purging log to 1 for term 1 09:13:30,863 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior436#-1426504159] 09:13:30,874 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower437#-162820116] 09:13:30,874 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader438#733596531] 09:13:30,879 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:30,881 PM [main] [INFO] RaftActorBehavior - follower (Follower): Cannot append entries because sender's term 100 is less than 1000 09:13:30,882 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior439#-724500469] 09:13:30,893 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower440#1230388895] 09:13:30,893 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader441#1389267150] 09:13:30,897 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:30,898 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): In requestVote: RequestVote{term=999, candidateId=test, lastLogIndex=10000, lastLogTerm=999} - currentTerm: 1000, votedFor: null, lastIndex: 1, lastTerm: 1 09:13:30,899 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): requestVote returning: RequestVoteReply{term=1000, voteGranted=false} 09:13:30,899 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior442#-1919465665] 09:13:30,910 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower443#-2094369050] 09:13:30,911 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader444#1308665206] 09:13:30,915 PM [main] [INFO] FollowerTest - Starting testHandleInstallSnapshot 09:13:30,916 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:30,920 PM [main] [DEBUG] Follower - follower (Follower): handleInstallSnapshot: InstallSnapshot{term=1, leaderId=leader, lastIncludedIndex=1, lastIncludedTerm=1, datasize=50, chunk=1/2, lastChunkHashCode=OptionalInt.empty} 09:13:30,921 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader, need to catch up to 1 09:13:30,921 PM [main] [DEBUG] SnapshotTracker - follower (Follower): addChunk: chunkIndex=1, lastChunkIndex=0, collectedChunks.size=0, lastChunkHashCode=-1 09:13:30,921 PM [main] [DEBUG] Follower - follower (Follower): handleInstallSnapshot returning: InstallSnapshotReply{term=1, followerId=follower, chunkIndex=1, success=true} 09:13:30,922 PM [main] [DEBUG] Follower - follower (Follower): handleInstallSnapshot: InstallSnapshot{term=1, leaderId=leader, lastIncludedIndex=2, lastIncludedTerm=1, datasize=29, chunk=2/2, lastChunkHashCode=OptionalInt.empty} 09:13:30,923 PM [main] [DEBUG] SyncStatusTracker - follower: Lagging 1 entries behind leader leader and reached 1 (of expected 1) 09:13:30,923 PM [main] [DEBUG] SnapshotTracker - follower (Follower): addChunk: chunkIndex=2, lastChunkIndex=1, collectedChunks.size=50, lastChunkHashCode=675006801 09:13:30,923 PM [main] [INFO] Follower - follower (Follower): Snapshot received from leader: leader 09:13:30,926 PM [main] [DEBUG] Follower - follower (Follower): handleInstallSnapshot returning: InstallSnapshotReply{term=1, followerId=follower, chunkIndex=2, success=true} 09:13:30,927 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior445#140015564] 09:13:30,937 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower446#-1263614745] 09:13:30,938 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader447#-1447307139] 09:13:30,940 PM [main] [INFO] FollowerTest - Starting testHandleAppendEntriesPreviousLogEntryMissing 09:13:30,940 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:30,942 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=1, leaderId=leader, prevLogIndex=3, prevLogTerm=1, leaderCommit=4, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=4, term=1, command=four]]} 09:13:30,942 PM [main] [INFO] Follower - follower (Follower): The log is not empty but the prevLogIndex 3 was not found in it - lastIndex: 2, snapshotIndex: -1, snapshotTerm: -1 09:13:30,942 PM [main] [INFO] Follower - follower (Follower): Follower is out-of-sync so sending negative reply: AppendEntriesReply{term=1, success=false, followerId=follower, logLastIndex=2, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:30,942 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader, need to catch up to 4 09:13:30,943 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior448#-2129721442] 09:13:30,954 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower449#1448534258] 09:13:30,954 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader450#-1266009371] 09:13:30,958 PM [main] [INFO] FollowerTest - Starting testInitialSyncUpWithHandleInstallSnapshot 09:13:30,958 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:30,959 PM [main] [DEBUG] Follower - follower (Follower): handleInstallSnapshot: InstallSnapshot{term=1, leaderId=leader, lastIncludedIndex=1, lastIncludedTerm=1, datasize=50, chunk=1/2, lastChunkHashCode=OptionalInt.empty} 09:13:30,959 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader, need to catch up to 1 09:13:30,960 PM [main] [DEBUG] SnapshotTracker - follower (Follower): addChunk: chunkIndex=1, lastChunkIndex=0, collectedChunks.size=0, lastChunkHashCode=-1 09:13:30,960 PM [main] [DEBUG] Follower - follower (Follower): handleInstallSnapshot returning: InstallSnapshotReply{term=1, followerId=follower, chunkIndex=1, success=true} 09:13:30,960 PM [main] [DEBUG] Follower - follower (Follower): handleInstallSnapshot: InstallSnapshot{term=1, leaderId=leader, lastIncludedIndex=2, lastIncludedTerm=1, datasize=29, chunk=2/2, lastChunkHashCode=OptionalInt.empty} 09:13:30,960 PM [main] [DEBUG] SnapshotTracker - follower (Follower): addChunk: chunkIndex=2, lastChunkIndex=1, collectedChunks.size=50, lastChunkHashCode=675006801 09:13:30,961 PM [main] [INFO] Follower - follower (Follower): Snapshot received from leader: leader 09:13:30,961 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 101 09:13:30,961 PM [main] [INFO] Follower - follower (Follower): Term 2 in "AppendEntries{term=2, leaderId=leader, prevLogIndex=101, prevLogTerm=1, leaderCommit=102, replicatedToAllIndex=101, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]}" message is greater than follower's term 1 - updating term 09:13:30,962 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader, prevLogIndex=101, prevLogTerm=1, leaderCommit=102, replicatedToAllIndex=101, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]} 09:13:30,962 PM [main] [INFO] Follower - follower (Follower): The log is not empty but the prevLogIndex 101 was not found in it - lastIndex: 101, snapshotIndex: -1, snapshotTerm: -1 09:13:30,962 PM [main] [INFO] Follower - follower (Follower): Follower is out-of-sync so sending negative reply: AppendEntriesReply{term=2, success=false, followerId=follower, logLastIndex=101, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:30,962 PM [main] [DEBUG] SyncStatusTracker - follower: Lagging 1 entries behind leader leader and reached 101 (of expected 1) 09:13:30,963 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior451#65594682] 09:13:30,973 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower452#1691896310] 09:13:30,974 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader453#-1907592812] 09:13:30,976 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:30,977 PM [main] [INFO] Follower - follower (Follower): Term 100 in "RequestVoteReply{term=100, voteGranted=false}" message is greater than follower's term 1 - updating term 09:13:30,978 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior454#-383649588] 09:13:30,989 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower455#735567349] 09:13:30,989 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader456#-1485109486] 09:13:30,993 PM [main] [INFO] FollowerTest - Starting testHandleFirstAppendEntries 09:13:30,993 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:30,994 PM [main] [INFO] Follower - follower (Follower): Term 2 in "AppendEntries{term=2, leaderId=leader-1, prevLogIndex=100, prevLogTerm=1, leaderCommit=101, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]}" message is greater than follower's term 1 - updating term 09:13:30,994 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader-1, prevLogIndex=100, prevLogTerm=1, leaderCommit=101, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]} 09:13:30,995 PM [main] [DEBUG] Follower - follower (Follower): Number of entries to be appended = 1 09:13:30,995 PM [main] [DEBUG] Follower - follower (Follower): After cleanup, lastIndex: 100, entries to be added from: 0 09:13:30,995 PM [main] [DEBUG] Follower - follower (Follower): Append entry to log foo 09:13:30,995 PM [main] [DEBUG] Follower - follower (Follower): Log size is now 2 09:13:30,995 PM [main] [DEBUG] Follower - follower (Follower): Commit index set to 101 09:13:30,995 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries returning : AppendEntriesReply{term=2, success=true, followerId=follower, logLastIndex=101, logLastTerm=2, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:30,995 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader-1, need to catch up to 101 09:13:30,996 PM [main] [DEBUG] Follower - follower (Follower): applyLogToStateMachine, appendEntries.getLeaderCommit(): 101, context.getLastApplied(): 1, lastIndex(): 101 09:13:30,996 PM [main] [WARN] RaftActorBehavior - follower (Follower): Missing index 2 from log. Cannot apply state. Ignoring 2 to 101 09:13:30,997 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior457#983059372] 09:13:31,8 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower458#-611320703] 09:13:31,8 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader459#1043417963] 09:13:31,14 PM [main] [INFO] FollowerTest - Starting testHandleAppendEntriesWithExistingLogEntry 09:13:31,14 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,15 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=1, leaderId=leader, prevLogIndex=0, prevLogTerm=1, leaderCommit=1, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=1, term=1, command=one]]} 09:13:31,16 PM [main] [DEBUG] Follower - follower (Follower): Number of entries to be appended = 1 09:13:31,16 PM [main] [DEBUG] Follower - follower (Follower): matchEntry DefaultLogEntry[index=1, term=1, command=one] is present: existingEntryTerm: 1 09:13:31,16 PM [main] [DEBUG] Follower - follower (Follower): After cleanup, lastIndex: 1, entries to be added from: 1 09:13:31,16 PM [main] [DEBUG] Follower - follower (Follower): Log size is now 2 09:13:31,16 PM [main] [DEBUG] Follower - follower (Follower): Commit index set to 1 09:13:31,16 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries returning : AppendEntriesReply{term=1, success=true, followerId=follower, logLastIndex=1, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,16 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader, need to catch up to 1 09:13:31,16 PM [main] [DEBUG] Follower - follower (Follower): applyLogToStateMachine, appendEntries.getLeaderCommit(): 1, context.getLastApplied(): -1, lastIndex(): 1 09:13:31,17 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Setting last applied to 0 09:13:31,17 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 0 09:13:31,17 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Setting last applied to 1 09:13:31,17 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from 0 to 1 09:13:31,18 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=1, leaderId=leader, prevLogIndex=0, prevLogTerm=1, leaderCommit=2, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=1, term=1, command=one], DefaultLogEntry[index=2, term=1, command=two]]} 09:13:31,18 PM [main] [DEBUG] Follower - follower (Follower): Number of entries to be appended = 2 09:13:31,18 PM [main] [DEBUG] Follower - follower (Follower): matchEntry DefaultLogEntry[index=1, term=1, command=one] is present: existingEntryTerm: 1 09:13:31,18 PM [main] [DEBUG] Follower - follower (Follower): After cleanup, lastIndex: 1, entries to be added from: 1 09:13:31,18 PM [main] [DEBUG] Follower - follower (Follower): Append entry to log two 09:13:31,18 PM [main] [DEBUG] Follower - follower (Follower): Log size is now 3 09:13:31,18 PM [main] [DEBUG] Follower - follower (Follower): Commit index set to 2 09:13:31,18 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries returning : AppendEntriesReply{term=1, success=true, followerId=follower, logLastIndex=2, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,18 PM [main] [DEBUG] SyncStatusTracker - follower: Lagging 0 entries behind leader leader and reached 2 (of expected 1) 09:13:31,18 PM [main] [DEBUG] Follower - follower (Follower): applyLogToStateMachine, appendEntries.getLeaderCommit(): 2, context.getLastApplied(): 1, lastIndex(): 2 09:13:31,19 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Setting last applied to 2 09:13:31,19 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from 1 to 2 09:13:31,19 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior460#-28215470] 09:13:31,30 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower461#482737461] 09:13:31,30 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader462#-1633611433] 09:13:31,33 PM [main] [INFO] FollowerTest - Starting testHandleAppendEntriesSenderPrevLogTermNotSameAsReceiverPrevLogTerm 09:13:31,33 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,34 PM [main] [INFO] Follower - follower (Follower): Term 2 in "AppendEntries{term=2, leaderId=leader, prevLogIndex=0, prevLogTerm=2, leaderCommit=101, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[]}" message is greater than follower's term 1 - updating term 09:13:31,35 PM [main] [INFO] Follower - follower (Follower): The prevLogIndex 0 was found in the log but the term 1 is not equal to the append entries prevLogTerm 2 - lastIndex: 1, snapshotIndex: -1, snapshotTerm: -1 09:13:31,35 PM [main] [INFO] Follower - follower (Follower): Follower is out-of-sync so sending negative reply: AppendEntriesReply{term=2, success=false, followerId=follower, logLastIndex=1, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,36 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader, need to catch up to 101 09:13:31,36 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior463#1973868479] 09:13:31,47 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower464#-1203466786] 09:13:31,47 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader465#-105665704] 09:13:31,51 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,56 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior466#-732669609] 09:13:31,67 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower467#162303603] 09:13:31,67 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader468#774887141] 09:13:31,71 PM [main] [INFO] FollowerTest - Starting testHandleAppendEntriesWithNewerCommitIndex 09:13:31,71 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,71 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 100 09:13:31,72 PM [main] [INFO] Follower - follower (Follower): Term 2 in "AppendEntries{term=2, leaderId=leader-1, prevLogIndex=100, prevLogTerm=1, leaderCommit=101, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]}" message is greater than follower's term 1 - updating term 09:13:31,73 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader-1, prevLogIndex=100, prevLogTerm=1, leaderCommit=101, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]} 09:13:31,73 PM [main] [DEBUG] Follower - follower (Follower): Number of entries to be appended = 1 09:13:31,73 PM [main] [DEBUG] Follower - follower (Follower): After cleanup, lastIndex: 100, entries to be added from: 0 09:13:31,73 PM [main] [DEBUG] Follower - follower (Follower): Append entry to log foo 09:13:31,73 PM [main] [DEBUG] Follower - follower (Follower): Log size is now 2 09:13:31,73 PM [main] [DEBUG] Follower - follower (Follower): Commit index set to 101 09:13:31,73 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries returning : AppendEntriesReply{term=2, success=true, followerId=follower, logLastIndex=101, logLastTerm=2, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,73 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader-1, need to catch up to 101 09:13:31,73 PM [main] [DEBUG] Follower - follower (Follower): applyLogToStateMachine, appendEntries.getLeaderCommit(): 101, context.getLastApplied(): 100, lastIndex(): 101 09:13:31,73 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Setting last applied to 101 09:13:31,73 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from 100 to 101 09:13:31,74 PM [main] [DEBUG] SnapshotManager - follower: fakeSnapshot purging log to 100 for term 2 09:13:31,74 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior469#-1352071796] 09:13:31,85 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower470#-355831264] 09:13:31,85 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader471#-305234684] 09:13:31,89 PM [main] [INFO] FollowerTest - Starting testCaptureSnapshotOnLastEntryInAppendEntries 09:13:31,94 PM [main] [DEBUG] PropertiesTermInfoStore - testCaptureSnapshotOnLastEntryInAppendEntries: Set currentTerm=1, votedFor=null 09:13:31,95 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] MockRaftActor - Actor created TestActor[pekko://test/user/testCaptureSnapshotOnLastEntryInAppendEntries] [WARN] [09/02/2025 21:13:31.096] [test-pekko.actor.default-dispatcher-4] [pekko://test/user/termination-monitor] received dead letter from TestActor[pekko://test/user/testCaptureSnapshotOnLastEntryInAppendEntries]: org.opendaylight.controller.cluster.common.actor.Monitor@34f1642f 09:13:31,96 PM [test-pekko.actor.default-dispatcher-5] [INFO] RaftActor - testCaptureSnapshotOnLastEntryInAppendEntries: Starting recovery with journal batch size 1000 09:13:31,96 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: started executor 09:13:31,96 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: started executor [INFO] [pekkoDeadLetter][09/02/2025 21:13:31.096] [test-pekko.actor.default-dispatcher-11] [pekko://test/user/termination-monitor] Message [org.opendaylight.controller.cluster.common.actor.Monitor] from TestActor[pekko://test/user/testCaptureSnapshotOnLastEntryInAppendEntries] to Actor[pekko://test/user/termination-monitor] was not delivered. [1] dead letters encountered. If this is not an expected behavior then Actor[pekko://test/user/termination-monitor] may have terminated unexpectedly. This logging can be turned off or adjusted with configuration settings 'pekko.log-dead-letters' and 'pekko.log-dead-letters-during-shutdown'. 09:13:31,97 PM [test-pekko.actor.default-dispatcher-4] [INFO] EmptyLocalActorRef - pekkoDeadLetter Message [org.opendaylight.controller.cluster.common.actor.Monitor] from TestActor[pekko://test/user/testCaptureSnapshotOnLastEntryInAppendEntries] to Actor[pekko://test/user/termination-monitor] was not delivered. [1] dead letters encountered. If this is not an expected behavior then Actor[pekko://test/user/termination-monitor] may have terminated unexpectedly. This logging can be turned off or adjusted with configuration settings 'pekko.log-dead-letters' and 'pekko.log-dead-letters-during-shutdown'. 09:13:31,97 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnLastEntryInAppendEntries: metadata journal open: replayFrom=1 applyTo=0 09:13:31,98 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnLastEntryInAppendEntries: journal open: firstIndex=1 lastIndex=0 replayFrom=1 fileEntries=0 09:13:31,98 PM [test-pekko.actor.default-dispatcher-5] [INFO] EnabledRaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: journal open: applyTo=0 09:13:31,98 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftActor - testCaptureSnapshotOnLastEntryInAppendEntries: starting journal recovery 09:13:31,98 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] PropertiesTermInfoStore - /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/TermInfo.properties does not exist 09:13:31,98 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] JournalWriteTask - testCaptureSnapshotOnLastEntryInAppendEntries: journal writer started 09:13:31,98 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] JournalWriteTask - testCaptureSnapshotOnLastEntryInAppendEntries: waiting to receive commands 09:13:31,100 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] PropertiesTermInfoStore - testCaptureSnapshotOnLastEntryInAppendEntries: Set currentTerm=0, votedFor=null 09:13:31,100 PM [test-pekko.actor.default-dispatcher-5] [INFO] Recovery - testCaptureSnapshotOnLastEntryInAppendEntries: Local TermInfo store seeded with TermInfo{term=0} 09:13:31,100 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: skipping unrecognized file /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/TermInfo.properties 09:13:31,100 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: skipping unrecognized file /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/journal-v1-1.log 09:13:31,100 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: skipping unrecognized file /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/metadata-v1-1.log 09:13:31,100 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: no eligible files found 09:13:31,100 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] AbstractReplicatedLog - testCaptureSnapshotOnLastEntryInAppendEntries: Moving last applied index from -1 to -1 09:13:31,100 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] JournalRecovery - testCaptureSnapshotOnLastEntryInAppendEntries: empty journal: appending 0 entries 09:13:31,101 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnLastEntryInAppendEntries: updated meta to JournalMeta[replayFrom=1, applyTo=0] 09:13:31,101 PM [test-pekko.actor.default-dispatcher-5] [INFO] Recovery - testCaptureSnapshotOnLastEntryInAppendEntries: Recovery completed in in 2.458 ms: last log index = -1, last log term = -1, napshot index = -1, snapshot term = -1, journal size = 0 09:13:31,101 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftActor - testCaptureSnapshotOnLastEntryInAppendEntries: Recovery completed and can restore from snapshot 09:13:31,101 PM [main] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: skipping unrecognized file /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/TermInfo.properties 09:13:31,102 PM [main] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: skipping unrecognized file /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/journal-v1-1.log 09:13:31,102 PM [main] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: skipping unrecognized file /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/metadata-v1-1.log 09:13:31,102 PM [main] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: no eligible files found 09:13:31,102 PM [test-pekko.actor.default-dispatcher-5] [INFO] Follower - testCaptureSnapshotOnLastEntryInAppendEntries (Follower): Term 1 in "AppendEntries{term=1, leaderId=leader, prevLogIndex=-1, prevLogTerm=-1, leaderCommit=1, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=0, term=1, command=one], DefaultLogEntry[index=1, term=1, command=two]]}" message is greater than follower's term 0 - updating term 09:13:31,103 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] PropertiesTermInfoStore - testCaptureSnapshotOnLastEntryInAppendEntries: Set currentTerm=1, votedFor=null 09:13:31,103 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] Follower - testCaptureSnapshotOnLastEntryInAppendEntries (Follower): handleAppendEntries: AppendEntries{term=1, leaderId=leader, prevLogIndex=-1, prevLogTerm=-1, leaderCommit=1, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=0, term=1, command=one], DefaultLogEntry[index=1, term=1, command=two]]} 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] Follower - testCaptureSnapshotOnLastEntryInAppendEntries (Follower): Number of entries to be appended = 2 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] Follower - testCaptureSnapshotOnLastEntryInAppendEntries (Follower): After cleanup, lastIndex: -1, entries to be added from: 0 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] Follower - testCaptureSnapshotOnLastEntryInAppendEntries (Follower): Append entry to log one 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] ReplicatedLogImpl - testCaptureSnapshotOnLastEntryInAppendEntries: Append log entry and persist DefaultLogEntry[index=0, term=1, command=one] 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] Follower - testCaptureSnapshotOnLastEntryInAppendEntries (Follower): Append entry to log two 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] ReplicatedLogImpl - testCaptureSnapshotOnLastEntryInAppendEntries: Append log entry and persist DefaultLogEntry[index=1, term=1, command=two] 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] Follower - testCaptureSnapshotOnLastEntryInAppendEntries (Follower): Log size is now 2 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] Follower - testCaptureSnapshotOnLastEntryInAppendEntries (Follower): Commit index set to 1 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] Follower - testCaptureSnapshotOnLastEntryInAppendEntries (Follower): handleAppendEntries returning : AppendEntriesReply{term=1, success=true, followerId=testCaptureSnapshotOnLastEntryInAppendEntries, logLastIndex=1, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,104 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] JournalWriteTask - testCaptureSnapshotOnLastEntryInAppendEntries: received 1 commands after 5.488 ms 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] SyncStatusTracker - testCaptureSnapshotOnLastEntryInAppendEntries: Last sync leader does not match current leader leader, need to catch up to 1 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] Follower - testCaptureSnapshotOnLastEntryInAppendEntries (Follower): applyLogToStateMachine, appendEntries.getLeaderCommit(): 1, context.getLastApplied(): -1, lastIndex(): 1 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftActorBehavior - testCaptureSnapshotOnLastEntryInAppendEntries (Follower): Setting last applied to 0 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] AbstractReplicatedLog - testCaptureSnapshotOnLastEntryInAppendEntries: Moving last applied index from -1 to 0 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftActor - testCaptureSnapshotOnLastEntryInAppendEntries: Applying state for log index 0 data one 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [INFO] MockRaftActor - testCaptureSnapshotOnLastEntryInAppendEntries: applyState called: one 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftActorBehavior - testCaptureSnapshotOnLastEntryInAppendEntries (Follower): Setting last applied to 1 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] AbstractReplicatedLog - testCaptureSnapshotOnLastEntryInAppendEntries: Moving last applied index from 0 to 1 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftActor - testCaptureSnapshotOnLastEntryInAppendEntries: Applying state for log index 1 data two 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [INFO] MockRaftActor - testCaptureSnapshotOnLastEntryInAppendEntries: applyState called: two 09:13:31,104 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnLastEntryInAppendEntries: awaiting more completions to resolve 2 synchronized callback(s) 09:13:31,107 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnLastEntryInAppendEntries: 1 completion(s) pending 09:13:31,107 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnLastEntryInAppendEntries: running 1 completion(s) 09:13:31,107 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] JournalWriteTask - testCaptureSnapshotOnLastEntryInAppendEntries: completed 1 commands in 3.535 ms 09:13:31,107 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] ReplicatedLogImpl - testCaptureSnapshotOnLastEntryInAppendEntries: persist complete JournaledLogEntry{index=0, term=1, command=one, pending=false} 09:13:31,107 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnLastEntryInAppendEntries: completed synchronized callback AppendReceivedCallback{entry=JournaledLogEntry{index=0, term=1, command=one, pending=false}, callback=org.opendaylight.controller.cluster.raft.behaviors.Follower$$Lambda/0x00000007c08d4f50@7e5f2b38} 09:13:31,107 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] JournalWriteTask - testCaptureSnapshotOnLastEntryInAppendEntries: received 2 commands after 3.490 μs 09:13:31,107 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnLastEntryInAppendEntries: awaiting more completions to resolve 1 synchronized callback(s) 09:13:31,108 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnLastEntryInAppendEntries: updated meta to JournalMeta[replayFrom=1, applyTo=2] 09:13:31,108 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnLastEntryInAppendEntries: 2 completion(s) pending 09:13:31,109 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnLastEntryInAppendEntries: running 2 completion(s) 09:13:31,109 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] JournalWriteTask - testCaptureSnapshotOnLastEntryInAppendEntries: completed 2 commands in 1.016 ms 09:13:31,109 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] ReplicatedLogImpl - testCaptureSnapshotOnLastEntryInAppendEntries: persist complete JournaledLogEntry{index=1, term=1, command=two, pending=false} 09:13:31,109 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] JournalWriteTask - testCaptureSnapshotOnLastEntryInAppendEntries: waiting to receive commands 09:13:31,109 PM [test-pekko.actor.default-dispatcher-5] [INFO] SnapshotManager - testCaptureSnapshotOnLastEntryInAppendEntries: Initiating snapshot capture CaptureSnapshot [lastAppliedIndex=1, lastAppliedTerm=1, lastIndex=1, lastTerm=1, installSnapshotInitiated=, replicatedToAllIndex=-1, replicatedToAllTerm=-1, unAppliedEntries size=0, mandatoryTrim=false] 09:13:31,109 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] SnapshotManager - testCaptureSnapshotOnLastEntryInAppendEntries: captured snapshot at lastSequenceNumber: 2 09:13:31,109 PM [test-pekko.actor.default-dispatcher-5] [INFO] SnapshotManager - testCaptureSnapshotOnLastEntryInAppendEntries: Persising snapshot at EntryInfo[index=1, term=1]/EntryInfo[index=1, term=1] 09:13:31,109 PM [test-pekko.actor.default-dispatcher-5] [INFO] MockRaftActor - testCaptureSnapshotOnLastEntryInAppendEntries: support() called 09:13:31,109 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] SnapshotManager - testCaptureSnapshotOnLastEntryInAppendEntries: log size 2 exceeds the snapshot batch count 2 - doing snapshotPreCommit with index 1 09:13:31,109 PM [test-pekko.actor.default-dispatcher-5] [INFO] SnapshotManager - testCaptureSnapshotOnLastEntryInAppendEntries: Removed in-memory snapshotted entries, adjusted snapshotIndex: 1 and term: 1 09:13:31,109 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnLastEntryInAppendEntries: completed synchronized callback AppendReceivedCallback{entry=JournaledLogEntry{index=1, term=1, command=two, pending=false}, callback=org.opendaylight.controller.cluster.raft.behaviors.Follower$$Lambda/0x00000007c08d4f50@7e5f2b38} 09:13:31,109 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnLastEntryInAppendEntries: synchronized callbacks after 4.760 ms 09:13:31,109 PM [testCaptureSnapshotOnLastEntryInAppendEntries-%d960455] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: starting snapshot writeout to /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/snapshot-0000000068B75DFB-0682C661.tmp [WARN] [09/02/2025 21:13:31.109] [test-pekko.actor.default-dispatcher-5] [pekko://test/user/testCaptureSnapshotOnLastEntryInAppendEntries] unhandled message from Actor[pekko://test/deadLetters]: FollowerInitialSyncUpStatus[memberId=testCaptureSnapshotOnLastEntryInAppendEntries, initialSyncDone=false] [INFO] [pekkoDeadLetter][09/02/2025 21:13:31.109] [test-pekko.actor.default-dispatcher-4] [pekko://test/user/testCaptureSnapshotOnLastEntryInAppendEntries] Message [org.opendaylight.controller.cluster.raft.base.messages.FollowerInitialSyncUpStatus] to TestActor[pekko://test/user/testCaptureSnapshotOnLastEntryInAppendEntries] was unhandled. [2] dead letters encountered. This logging can be turned off or adjusted with configuration settings 'pekko.log-dead-letters' and 'pekko.log-dead-letters-during-shutdown'. 09:13:31,109 PM [test-pekko.actor.default-dispatcher-4] [INFO] TestActorRef - pekkoDeadLetter Message [org.opendaylight.controller.cluster.raft.base.messages.FollowerInitialSyncUpStatus] to TestActor[pekko://test/user/testCaptureSnapshotOnLastEntryInAppendEntries] was unhandled. [2] dead letters encountered. This logging can be turned off or adjusted with configuration settings 'pekko.log-dead-letters' and 'pekko.log-dead-letters-during-shutdown'. 09:13:31,114 PM [testCaptureSnapshotOnLastEntryInAppendEntries-%d960455] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: finished snapshot writeout to /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/snapshot-0000000068B75DFB-0682C661.v1 09:13:31,115 PM [testCaptureSnapshotOnLastEntryInAppendEntries-%d960455] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: skipping unrecognized file /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/TermInfo.properties 09:13:31,115 PM [testCaptureSnapshotOnLastEntryInAppendEntries-%d960455] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: selected SNAPSHOT_V1 to handle file /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/snapshot-0000000068B75DFB-0682C661.v1 09:13:31,115 PM [testCaptureSnapshotOnLastEntryInAppendEntries-%d960455] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: skipping unrecognized file /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/journal-v1-1.log 09:13:31,115 PM [testCaptureSnapshotOnLastEntryInAppendEntries-%d960455] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: skipping unrecognized file /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/metadata-v1-1.log 09:13:31,115 PM [testCaptureSnapshotOnLastEntryInAppendEntries-%d960455] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: retaining snapshot SnapshotFileV1{lastIncluded=EntryInfo[index=1, term=1], timestamp=2025-09-02T21:13:31.109233761Z, file=/tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/snapshot-0000000068B75DFB-0682C661.v1, size=555, entryCompress=NONE, stateCompress=NONE} 09:13:31,115 PM [testCaptureSnapshotOnLastEntryInAppendEntries-%d960455] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnLastEntryInAppendEntries: 1 completion(s) pending 09:13:31,115 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnLastEntryInAppendEntries: running 1 completion(s) 09:13:31,115 PM [test-pekko.actor.default-dispatcher-4] [INFO] SnapshotManager - testCaptureSnapshotOnLastEntryInAppendEntries: snapshot is durable as of 2025-09-02T21:13:31.109233761Z 09:13:31,115 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] SnapshotManager - testCaptureSnapshotOnLastEntryInAppendEntries: Snapshot success, discarding journal entries up to 2 09:13:31,115 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] JournalWriteTask - testCaptureSnapshotOnLastEntryInAppendEntries: received 1 commands after 6.616 ms 09:13:31,115 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftActorSnapshotMessageSupport - testCaptureSnapshotOnLastEntryInAppendEntries: SnapshotComplete received 09:13:31,115 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnLastEntryInAppendEntries: updated meta to JournalMeta[replayFrom=3, applyTo=2] 09:13:31,115 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnLastEntryInAppendEntries: discarded entries up to (and including) 2 09:13:31,115 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnLastEntryInAppendEntries: 1 completion(s) pending 09:13:31,115 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] JournalWriteTask - testCaptureSnapshotOnLastEntryInAppendEntries: completed 1 commands in 195.4 μs 09:13:31,115 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] JournalWriteTask - testCaptureSnapshotOnLastEntryInAppendEntries: waiting to receive commands 09:13:31,115 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnLastEntryInAppendEntries: running 1 completion(s) 09:13:31,203 PM [awaitility-thread] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: skipping unrecognized file /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/TermInfo.properties 09:13:31,203 PM [awaitility-thread] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: selected SNAPSHOT_V1 to handle file /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/snapshot-0000000068B75DFB-0682C661.v1 09:13:31,203 PM [awaitility-thread] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: skipping unrecognized file /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/journal-v1-1.log 09:13:31,203 PM [awaitility-thread] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: skipping unrecognized file /tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/metadata-v1-1.log 09:13:31,203 PM [awaitility-thread] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: picked SnapshotFileV1{lastIncluded=EntryInfo[index=1, term=1], timestamp=2025-09-02T21:13:31.109233761Z, file=/tmp/junit-5874651314923817804/testCaptureSnapshotOnLastEntryInAppendEntries/snapshot-0000000068B75DFB-0682C661.v1, size=555, entryCompress=NONE, stateCompress=NONE} as the latest file 09:13:31,206 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior472#176707151] 09:13:31,217 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower473#1888593754] 09:13:31,217 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader474#-534678677] 09:13:31,217 PM [main] [INFO] TestActorFactory - Killing actor TestActor[pekko://test/user/testCaptureSnapshotOnLastEntryInAppendEntries] 09:13:31,218 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] EnabledRaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: terminating thread VirtualThread[#631,testCaptureSnapshotOnLastEntryInAppendEntries-writer-156]/waiting 09:13:31,218 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] JournalWriteTask - testCaptureSnapshotOnLastEntryInAppendEntries: received 1 commands after 102.3 ms 09:13:31,218 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] JournalWriteTask - testCaptureSnapshotOnLastEntryInAppendEntries: completed 1 commands in 29.13 μs 09:13:31,218 PM [testCaptureSnapshotOnLastEntryInAppendEntries-writer-156] [DEBUG] JournalWriteTask - testCaptureSnapshotOnLastEntryInAppendEntries: journal writer stopped 09:13:31,218 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnLastEntryInAppendEntries: journal closed 09:13:31,218 PM [test-pekko.actor.default-dispatcher-4] [INFO] EnabledRaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: journal closed 09:13:31,218 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: stopped executor with 0 remaining tasks 09:13:31,218 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnLastEntryInAppendEntries: stopped executor with 0 remaining tasks 09:13:31,223 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,224 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior475#-442364975] 09:13:31,225 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower476#-1184713453] 09:13:31,225 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader477#-262609994] 09:13:31,227 PM [main] [INFO] FollowerTest - Starting testHandleRequestVoteWhenSenderTermEqualToCurrentTermAndVotedForIsNotTheSameAsCandidateId 09:13:31,227 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,228 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): In requestVote: RequestVote{term=1000, candidateId=candidate, lastLogIndex=10000, lastLogTerm=999} - currentTerm: 1000, votedFor: test, lastIndex: 1, lastTerm: 1 09:13:31,228 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): requestVote returning: RequestVoteReply{term=1000, voteGranted=false} 09:13:31,228 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior478#2090681942] 09:13:31,229 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower479#166744223] 09:13:31,229 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader480#-1286252] 09:13:31,231 PM [main] [INFO] FollowerTest - Starting testHandleFirstAppendEntriesWithPrevIndexMinusOneAndReplicatedToAllIndexPresentInSnapshot 09:13:31,231 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,232 PM [main] [INFO] Follower - follower (Follower): Term 2 in "AppendEntries{term=2, leaderId=leader-1, prevLogIndex=-1, prevLogTerm=-1, leaderCommit=101, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]}" message is greater than follower's term 1 - updating term 09:13:31,232 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader-1, prevLogIndex=-1, prevLogTerm=-1, leaderCommit=101, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]} 09:13:31,232 PM [main] [DEBUG] Follower - follower (Follower): Number of entries to be appended = 1 09:13:31,232 PM [main] [DEBUG] Follower - follower (Follower): After cleanup, lastIndex: 100, entries to be added from: 0 09:13:31,232 PM [main] [DEBUG] Follower - follower (Follower): Append entry to log foo 09:13:31,232 PM [main] [DEBUG] Follower - follower (Follower): Log size is now 1 09:13:31,232 PM [main] [DEBUG] Follower - follower (Follower): Commit index set to 101 09:13:31,232 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries returning : AppendEntriesReply{term=2, success=true, followerId=follower, logLastIndex=101, logLastTerm=2, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,232 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader-1, need to catch up to 101 09:13:31,232 PM [main] [DEBUG] Follower - follower (Follower): applyLogToStateMachine, appendEntries.getLeaderCommit(): 101, context.getLastApplied(): 1, lastIndex(): 101 09:13:31,233 PM [main] [WARN] RaftActorBehavior - follower (Follower): Missing index 2 from log. Cannot apply state. Ignoring 2 to 101 09:13:31,233 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior481#-788682177] 09:13:31,233 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower482#1074739016] 09:13:31,233 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader483#1097439796] 09:13:31,235 PM [main] [INFO] FollowerTest - Starting testHandleAppendEntriesLeaderChangedBeforeSyncUpComplete 09:13:31,236 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,236 PM [main] [INFO] Follower - follower (Follower): Term 2 in "AppendEntries{term=2, leaderId=leader-1, prevLogIndex=100, prevLogTerm=1, leaderCommit=101, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]}" message is greater than follower's term 1 - updating term 09:13:31,236 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader-1, prevLogIndex=100, prevLogTerm=1, leaderCommit=101, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]} 09:13:31,236 PM [main] [INFO] Follower - follower (Follower): The log is not empty but the prevLogIndex 100 was not found in it - lastIndex: 1, snapshotIndex: -1, snapshotTerm: -1 09:13:31,237 PM [main] [INFO] Follower - follower (Follower): Follower is out-of-sync so sending negative reply: AppendEntriesReply{term=2, success=false, followerId=follower, logLastIndex=1, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,237 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader-1, need to catch up to 101 09:13:31,237 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from 1 to 100 09:13:31,237 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader-2, prevLogIndex=45, prevLogTerm=1, leaderCommit=46, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]} 09:13:31,238 PM [main] [INFO] Follower - follower (Follower): The log is not empty but the prevLogIndex 45 was not found in it - lastIndex: 100, snapshotIndex: -1, snapshotTerm: -1 09:13:31,238 PM [main] [INFO] Follower - follower (Follower): Follower is out-of-sync so sending negative reply: AppendEntriesReply{term=2, success=false, followerId=follower, logLastIndex=100, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,238 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader-2, need to catch up to 46 09:13:31,238 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior484#-1532492655] 09:13:31,239 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower485#94229062] 09:13:31,239 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader486#6062139] 09:13:31,241 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,241 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior487#1492636801] 09:13:31,241 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower488#1987734705] 09:13:31,241 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader489#1386115366] 09:13:31,243 PM [main] [INFO] FollowerTest - Starting testHandleSyncUpAppendEntries 09:13:31,243 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,244 PM [main] [INFO] Follower - follower (Follower): Term 2 in "AppendEntries{term=2, leaderId=leader-1, prevLogIndex=100, prevLogTerm=1, leaderCommit=101, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]}" message is greater than follower's term 1 - updating term 09:13:31,244 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader-1, prevLogIndex=100, prevLogTerm=1, leaderCommit=101, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]} 09:13:31,244 PM [main] [INFO] Follower - follower (Follower): The log is not empty but the prevLogIndex 100 was not found in it - lastIndex: 1, snapshotIndex: -1, snapshotTerm: -1 09:13:31,245 PM [main] [INFO] Follower - follower (Follower): Follower is out-of-sync so sending negative reply: AppendEntriesReply{term=2, success=false, followerId=follower, logLastIndex=1, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,245 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader-1, need to catch up to 101 09:13:31,245 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 101 09:13:31,245 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader-1, prevLogIndex=101, prevLogTerm=1, leaderCommit=102, replicatedToAllIndex=101, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]} 09:13:31,245 PM [main] [INFO] Follower - follower (Follower): The log is not empty but the prevLogIndex 101 was not found in it - lastIndex: 101, snapshotIndex: -1, snapshotTerm: -1 09:13:31,245 PM [main] [INFO] Follower - follower (Follower): Follower is out-of-sync so sending negative reply: AppendEntriesReply{term=2, success=false, followerId=follower, logLastIndex=101, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,246 PM [main] [DEBUG] SyncStatusTracker - follower: Lagging 1 entries behind leader leader-1 and reached 101 (of expected 101) 09:13:31,246 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader-1, prevLogIndex=101, prevLogTerm=1, leaderCommit=102, replicatedToAllIndex=101, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]} 09:13:31,246 PM [main] [INFO] Follower - follower (Follower): The log is not empty but the prevLogIndex 101 was not found in it - lastIndex: 101, snapshotIndex: -1, snapshotTerm: -1 09:13:31,246 PM [main] [INFO] Follower - follower (Follower): Follower is out-of-sync so sending negative reply: AppendEntriesReply{term=2, success=false, followerId=follower, logLastIndex=101, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,246 PM [main] [DEBUG] SyncStatusTracker - follower: Lagging 1 entries behind leader leader-1 and reached 101 (of expected 101) 09:13:31,247 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior490#-2131651404] 09:13:31,247 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower491#523255594] 09:13:31,247 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader492#-671425732] 09:13:31,250 PM [main] [INFO] FollowerTest - Starting testHandleAppendAfterInstallingSnapshot 09:13:31,250 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,250 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=1, leaderId=leader, prevLogIndex=3, prevLogTerm=1, leaderCommit=4, replicatedToAllIndex=3, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=4, term=1, command=four]]} 09:13:31,250 PM [main] [DEBUG] Follower - follower (Follower): Number of entries to be appended = 1 09:13:31,250 PM [main] [DEBUG] Follower - follower (Follower): After cleanup, lastIndex: 3, entries to be added from: 0 09:13:31,250 PM [main] [DEBUG] Follower - follower (Follower): Append entry to log four 09:13:31,251 PM [main] [DEBUG] Follower - follower (Follower): Log size is now 1 09:13:31,251 PM [main] [DEBUG] Follower - follower (Follower): Commit index set to 4 09:13:31,251 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries returning : AppendEntriesReply{term=1, success=true, followerId=follower, logLastIndex=4, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,251 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader, need to catch up to 4 09:13:31,251 PM [main] [DEBUG] Follower - follower (Follower): applyLogToStateMachine, appendEntries.getLeaderCommit(): 4, context.getLastApplied(): -1, lastIndex(): 4 09:13:31,251 PM [main] [WARN] RaftActorBehavior - follower (Follower): Missing index 0 from log. Cannot apply state. Ignoring 0 to 4 09:13:31,251 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior493#212827882] 09:13:31,252 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower494#-177547669] 09:13:31,252 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader495#578841709] 09:13:31,254 PM [main] [INFO] FollowerTest - Starting testNeedsLeaderAddress 09:13:31,254 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,255 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader, need to catch up to -1 09:13:31,255 PM [main] [DEBUG] Follower - New leader address: pekko://test/user/leader498 09:13:31,255 PM [main] [INFO] PeerInfos - follower: Peer address for peer leader set to pekko://test/user/leader498 09:13:31,257 PM [main] [DEBUG] SyncStatusTracker - follower: Lagging 0 entries behind leader leader and reached -1 (of expected -1) 09:13:31,257 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior496#-2048483434] 09:13:31,258 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower497#-57165815] 09:13:31,258 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader498#-1036249635] 09:13:31,260 PM [main] [INFO] FollowerTest - Starting testHandleFirstAppendEntriesWithPrevIndexMinusOneAndReplicatedToAllIndexPresentInLog 09:13:31,261 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,261 PM [main] [INFO] Follower - follower (Follower): Term 2 in "AppendEntries{term=2, leaderId=leader-1, prevLogIndex=-1, prevLogTerm=-1, leaderCommit=101, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]}" message is greater than follower's term 1 - updating term 09:13:31,262 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader-1, prevLogIndex=-1, prevLogTerm=-1, leaderCommit=101, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]} 09:13:31,262 PM [main] [DEBUG] Follower - follower (Follower): Number of entries to be appended = 1 09:13:31,262 PM [main] [DEBUG] Follower - follower (Follower): After cleanup, lastIndex: 100, entries to be added from: 0 09:13:31,262 PM [main] [DEBUG] Follower - follower (Follower): Append entry to log foo 09:13:31,262 PM [main] [DEBUG] Follower - follower (Follower): Log size is now 2 09:13:31,262 PM [main] [DEBUG] Follower - follower (Follower): Commit index set to 101 09:13:31,262 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries returning : AppendEntriesReply{term=2, success=true, followerId=follower, logLastIndex=101, logLastTerm=2, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,262 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader-1, need to catch up to 101 09:13:31,262 PM [main] [DEBUG] Follower - follower (Follower): applyLogToStateMachine, appendEntries.getLeaderCommit(): 101, context.getLastApplied(): 1, lastIndex(): 101 09:13:31,262 PM [main] [WARN] RaftActorBehavior - follower (Follower): Missing index 2 from log. Cannot apply state. Ignoring 2 to 101 09:13:31,263 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior499#1452777579] 09:13:31,263 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower500#-488751014] 09:13:31,263 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader501#-1769667415] 09:13:31,265 PM [main] [INFO] FollowerTest - Starting testHandleFirstAppendEntries 09:13:31,266 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,266 PM [main] [INFO] Follower - follower (Follower): Term 2 in "AppendEntries{term=2, leaderId=leader-1, prevLogIndex=-1, prevLogTerm=-1, leaderCommit=101, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]}" message is greater than follower's term 1 - updating term 09:13:31,266 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader-1, prevLogIndex=-1, prevLogTerm=-1, leaderCommit=101, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]} 09:13:31,266 PM [main] [INFO] Follower - follower (Follower): Cannot append entries because the replicatedToAllIndex 100 does not appear to be in the in-memory journal - lastIndex: 1, snapshotIndex: -1, snapshotTerm: -1 09:13:31,267 PM [main] [INFO] Follower - follower (Follower): Follower is out-of-sync so sending negative reply: AppendEntriesReply{term=2, success=false, followerId=follower, logLastIndex=1, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,267 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader-1, need to catch up to 101 09:13:31,267 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior502#-167364799] 09:13:31,268 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower503#1960107875] 09:13:31,268 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader504#-1487031435] 09:13:31,270 PM [main] [INFO] FollowerTest - Starting testCaptureSnapshotOnAppendEntriesWithUnapplied 09:13:31,273 PM [main] [DEBUG] PropertiesTermInfoStore - testCaptureSnapshotOnAppendEntriesWithUnapplied: Set currentTerm=1, votedFor=null 09:13:31,273 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] MockRaftActor - Actor created TestActor[pekko://test/user/testCaptureSnapshotOnAppendEntriesWithUnapplied] [WARN] [09/02/2025 21:13:31.274] [test-pekko.actor.default-dispatcher-5] [pekko://test/user/termination-monitor] received dead letter from TestActor[pekko://test/user/testCaptureSnapshotOnAppendEntriesWithUnapplied]: org.opendaylight.controller.cluster.common.actor.Monitor@79466c14 [INFO] [pekkoDeadLetter][09/02/2025 21:13:31.274] [test-pekko.actor.default-dispatcher-11] [pekko://test/user/termination-monitor] Message [org.opendaylight.controller.cluster.common.actor.Monitor] from TestActor[pekko://test/user/testCaptureSnapshotOnAppendEntriesWithUnapplied] to Actor[pekko://test/user/termination-monitor] was not delivered. [3] dead letters encountered. If this is not an expected behavior then Actor[pekko://test/user/termination-monitor] may have terminated unexpectedly. This logging can be turned off or adjusted with configuration settings 'pekko.log-dead-letters' and 'pekko.log-dead-letters-during-shutdown'. 09:13:31,274 PM [test-pekko.actor.default-dispatcher-5] [INFO] EmptyLocalActorRef - pekkoDeadLetter Message [org.opendaylight.controller.cluster.common.actor.Monitor] from TestActor[pekko://test/user/testCaptureSnapshotOnAppendEntriesWithUnapplied] to Actor[pekko://test/user/termination-monitor] was not delivered. [3] dead letters encountered. If this is not an expected behavior then Actor[pekko://test/user/termination-monitor] may have terminated unexpectedly. This logging can be turned off or adjusted with configuration settings 'pekko.log-dead-letters' and 'pekko.log-dead-letters-during-shutdown'. 09:13:31,274 PM [test-pekko.actor.default-dispatcher-4] [INFO] RaftActor - testCaptureSnapshotOnAppendEntriesWithUnapplied: Starting recovery with journal batch size 1000 09:13:31,274 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: started executor 09:13:31,274 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: started executor 09:13:31,275 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnAppendEntriesWithUnapplied: metadata journal open: replayFrom=1 applyTo=0 09:13:31,275 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnAppendEntriesWithUnapplied: journal open: firstIndex=1 lastIndex=0 replayFrom=1 fileEntries=0 09:13:31,275 PM [test-pekko.actor.default-dispatcher-4] [INFO] EnabledRaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: journal open: applyTo=0 09:13:31,275 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftActor - testCaptureSnapshotOnAppendEntriesWithUnapplied: starting journal recovery 09:13:31,275 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] JournalWriteTask - testCaptureSnapshotOnAppendEntriesWithUnapplied: journal writer started 09:13:31,275 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] PropertiesTermInfoStore - /tmp/junit-13147018424612011515/testCaptureSnapshotOnAppendEntriesWithUnapplied/TermInfo.properties does not exist 09:13:31,275 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] JournalWriteTask - testCaptureSnapshotOnAppendEntriesWithUnapplied: waiting to receive commands 09:13:31,277 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] PropertiesTermInfoStore - testCaptureSnapshotOnAppendEntriesWithUnapplied: Set currentTerm=0, votedFor=null 09:13:31,277 PM [test-pekko.actor.default-dispatcher-4] [INFO] Recovery - testCaptureSnapshotOnAppendEntriesWithUnapplied: Local TermInfo store seeded with TermInfo{term=0} 09:13:31,277 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: skipping unrecognized file /tmp/junit-13147018424612011515/testCaptureSnapshotOnAppendEntriesWithUnapplied/TermInfo.properties 09:13:31,277 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: skipping unrecognized file /tmp/junit-13147018424612011515/testCaptureSnapshotOnAppendEntriesWithUnapplied/journal-v1-1.log 09:13:31,277 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: skipping unrecognized file /tmp/junit-13147018424612011515/testCaptureSnapshotOnAppendEntriesWithUnapplied/metadata-v1-1.log 09:13:31,277 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: no eligible files found 09:13:31,277 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] AbstractReplicatedLog - testCaptureSnapshotOnAppendEntriesWithUnapplied: Moving last applied index from -1 to -1 09:13:31,277 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] JournalRecovery - testCaptureSnapshotOnAppendEntriesWithUnapplied: empty journal: appending 0 entries 09:13:31,277 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnAppendEntriesWithUnapplied: updated meta to JournalMeta[replayFrom=1, applyTo=0] 09:13:31,277 PM [test-pekko.actor.default-dispatcher-4] [INFO] Recovery - testCaptureSnapshotOnAppendEntriesWithUnapplied: Recovery completed in in 1.731 ms: last log index = -1, last log term = -1, napshot index = -1, snapshot term = -1, journal size = 0 09:13:31,277 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftActor - testCaptureSnapshotOnAppendEntriesWithUnapplied: Recovery completed and can restore from snapshot 09:13:31,277 PM [test-pekko.actor.default-dispatcher-4] [INFO] Follower - testCaptureSnapshotOnAppendEntriesWithUnapplied (Follower): Term 1 in "AppendEntries{term=1, leaderId=leader, prevLogIndex=-1, prevLogTerm=-1, leaderCommit=0, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=0, term=1, command=one], DefaultLogEntry[index=1, term=1, command=two], DefaultLogEntry[index=2, term=1, command=three]]}" message is greater than follower's term 0 - updating term 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] PropertiesTermInfoStore - testCaptureSnapshotOnAppendEntriesWithUnapplied: Set currentTerm=1, votedFor=null 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnAppendEntriesWithUnapplied (Follower): handleAppendEntries: AppendEntries{term=1, leaderId=leader, prevLogIndex=-1, prevLogTerm=-1, leaderCommit=0, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=0, term=1, command=one], DefaultLogEntry[index=1, term=1, command=two], DefaultLogEntry[index=2, term=1, command=three]]} 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnAppendEntriesWithUnapplied (Follower): Number of entries to be appended = 3 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnAppendEntriesWithUnapplied (Follower): After cleanup, lastIndex: -1, entries to be added from: 0 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnAppendEntriesWithUnapplied (Follower): Append entry to log one 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] ReplicatedLogImpl - testCaptureSnapshotOnAppendEntriesWithUnapplied: Append log entry and persist DefaultLogEntry[index=0, term=1, command=one] 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnAppendEntriesWithUnapplied (Follower): Append entry to log two 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] ReplicatedLogImpl - testCaptureSnapshotOnAppendEntriesWithUnapplied: Append log entry and persist DefaultLogEntry[index=1, term=1, command=two] 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnAppendEntriesWithUnapplied (Follower): Append entry to log three 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] ReplicatedLogImpl - testCaptureSnapshotOnAppendEntriesWithUnapplied: Append log entry and persist DefaultLogEntry[index=2, term=1, command=three] 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnAppendEntriesWithUnapplied (Follower): Log size is now 3 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnAppendEntriesWithUnapplied (Follower): Commit index set to 0 09:13:31,279 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] JournalWriteTask - testCaptureSnapshotOnAppendEntriesWithUnapplied: received 1 commands after 3.900 ms 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnAppendEntriesWithUnapplied (Follower): handleAppendEntries returning : AppendEntriesReply{term=1, success=true, followerId=testCaptureSnapshotOnAppendEntriesWithUnapplied, logLastIndex=2, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] SyncStatusTracker - testCaptureSnapshotOnAppendEntriesWithUnapplied: Last sync leader does not match current leader leader, need to catch up to 0 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnAppendEntriesWithUnapplied (Follower): applyLogToStateMachine, appendEntries.getLeaderCommit(): 0, context.getLastApplied(): -1, lastIndex(): 2 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftActorBehavior - testCaptureSnapshotOnAppendEntriesWithUnapplied (Follower): Setting last applied to 0 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] AbstractReplicatedLog - testCaptureSnapshotOnAppendEntriesWithUnapplied: Moving last applied index from -1 to 0 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftActor - testCaptureSnapshotOnAppendEntriesWithUnapplied: Applying state for log index 0 data one 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [INFO] MockRaftActor - testCaptureSnapshotOnAppendEntriesWithUnapplied: applyState called: one 09:13:31,279 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnAppendEntriesWithUnapplied: awaiting more completions to resolve 3 synchronized callback(s) 09:13:31,283 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnAppendEntriesWithUnapplied: 1 completion(s) pending 09:13:31,283 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] JournalWriteTask - testCaptureSnapshotOnAppendEntriesWithUnapplied: completed 1 commands in 3.472 ms 09:13:31,283 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnAppendEntriesWithUnapplied: running 1 completion(s) 09:13:31,283 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] JournalWriteTask - testCaptureSnapshotOnAppendEntriesWithUnapplied: received 3 commands after 2.000 μs 09:13:31,283 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] ReplicatedLogImpl - testCaptureSnapshotOnAppendEntriesWithUnapplied: persist complete JournaledLogEntry{index=0, term=1, command=one, pending=false} 09:13:31,283 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnAppendEntriesWithUnapplied: completed synchronized callback AppendReceivedCallback{entry=JournaledLogEntry{index=0, term=1, command=one, pending=false}, callback=org.opendaylight.controller.cluster.raft.behaviors.Follower$$Lambda/0x00000007c08d4f50@2472a9ab} 09:13:31,283 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnAppendEntriesWithUnapplied: awaiting more completions to resolve 2 synchronized callback(s) 09:13:31,284 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnAppendEntriesWithUnapplied: updated meta to JournalMeta[replayFrom=1, applyTo=1] 09:13:31,284 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnAppendEntriesWithUnapplied: 3 completion(s) pending 09:13:31,284 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] JournalWriteTask - testCaptureSnapshotOnAppendEntriesWithUnapplied: completed 3 commands in 1.272 ms 09:13:31,284 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnAppendEntriesWithUnapplied: running 3 completion(s) 09:13:31,284 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] JournalWriteTask - testCaptureSnapshotOnAppendEntriesWithUnapplied: waiting to receive commands 09:13:31,284 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] ReplicatedLogImpl - testCaptureSnapshotOnAppendEntriesWithUnapplied: persist complete JournaledLogEntry{index=1, term=1, command=two, pending=false} 09:13:31,284 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnAppendEntriesWithUnapplied: completed synchronized callback AppendReceivedCallback{entry=JournaledLogEntry{index=1, term=1, command=two, pending=false}, callback=org.opendaylight.controller.cluster.raft.behaviors.Follower$$Lambda/0x00000007c08d4f50@2472a9ab} 09:13:31,284 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] ReplicatedLogImpl - testCaptureSnapshotOnAppendEntriesWithUnapplied: persist complete JournaledLogEntry{index=2, term=1, command=three, pending=false} 09:13:31,284 PM [test-pekko.actor.default-dispatcher-4] [INFO] SnapshotManager - testCaptureSnapshotOnAppendEntriesWithUnapplied: Initiating snapshot capture CaptureSnapshot [lastAppliedIndex=0, lastAppliedTerm=1, lastIndex=2, lastTerm=1, installSnapshotInitiated=, replicatedToAllIndex=-1, replicatedToAllTerm=-1, unAppliedEntries size=2, mandatoryTrim=false] 09:13:31,284 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] SnapshotManager - testCaptureSnapshotOnAppendEntriesWithUnapplied: captured snapshot at lastSequenceNumber: 1 09:13:31,284 PM [test-pekko.actor.default-dispatcher-4] [INFO] SnapshotManager - testCaptureSnapshotOnAppendEntriesWithUnapplied: Persising snapshot at EntryInfo[index=0, term=1]/EntryInfo[index=2, term=1] 09:13:31,284 PM [test-pekko.actor.default-dispatcher-4] [INFO] MockRaftActor - testCaptureSnapshotOnAppendEntriesWithUnapplied: support() called 09:13:31,284 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] SnapshotManager - testCaptureSnapshotOnAppendEntriesWithUnapplied: log size 3 exceeds the snapshot batch count 1 - doing snapshotPreCommit with index 0 09:13:31,284 PM [test-pekko.actor.default-dispatcher-4] [INFO] SnapshotManager - testCaptureSnapshotOnAppendEntriesWithUnapplied: Removed in-memory snapshotted entries, adjusted snapshotIndex: 0 and term: 1 09:13:31,284 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnAppendEntriesWithUnapplied: completed synchronized callback AppendReceivedCallback{entry=JournaledLogEntry{index=2, term=1, command=three, pending=false}, callback=org.opendaylight.controller.cluster.raft.behaviors.Follower$$Lambda/0x00000007c08d4f50@2472a9ab} 09:13:31,284 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-%d89015] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: starting snapshot writeout to /tmp/junit-13147018424612011515/testCaptureSnapshotOnAppendEntriesWithUnapplied/snapshot-0000000068B75DFB-10F5D8AB.tmp 09:13:31,284 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnAppendEntriesWithUnapplied: synchronized callbacks after 4.936 ms [WARN] [09/02/2025 21:13:31.284] [test-pekko.actor.default-dispatcher-4] [pekko://test/user/testCaptureSnapshotOnAppendEntriesWithUnapplied] unhandled message from Actor[pekko://test/deadLetters]: FollowerInitialSyncUpStatus[memberId=testCaptureSnapshotOnAppendEntriesWithUnapplied, initialSyncDone=false] [INFO] [pekkoDeadLetter][09/02/2025 21:13:31.284] [test-pekko.actor.default-dispatcher-5] [pekko://test/user/testCaptureSnapshotOnAppendEntriesWithUnapplied] Message [org.opendaylight.controller.cluster.raft.base.messages.FollowerInitialSyncUpStatus] to TestActor[pekko://test/user/testCaptureSnapshotOnAppendEntriesWithUnapplied] was unhandled. [4] dead letters encountered. This logging can be turned off or adjusted with configuration settings 'pekko.log-dead-letters' and 'pekko.log-dead-letters-during-shutdown'. 09:13:31,284 PM [test-pekko.actor.default-dispatcher-5] [INFO] TestActorRef - pekkoDeadLetter Message [org.opendaylight.controller.cluster.raft.base.messages.FollowerInitialSyncUpStatus] to TestActor[pekko://test/user/testCaptureSnapshotOnAppendEntriesWithUnapplied] was unhandled. [4] dead letters encountered. This logging can be turned off or adjusted with configuration settings 'pekko.log-dead-letters' and 'pekko.log-dead-letters-during-shutdown'. 09:13:31,286 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-%d89015] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: finished snapshot writeout to /tmp/junit-13147018424612011515/testCaptureSnapshotOnAppendEntriesWithUnapplied/snapshot-0000000068B75DFB-10F5D8AB.v1 09:13:31,286 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-%d89015] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: selected SNAPSHOT_V1 to handle file /tmp/junit-13147018424612011515/testCaptureSnapshotOnAppendEntriesWithUnapplied/snapshot-0000000068B75DFB-10F5D8AB.v1 09:13:31,286 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-%d89015] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: skipping unrecognized file /tmp/junit-13147018424612011515/testCaptureSnapshotOnAppendEntriesWithUnapplied/TermInfo.properties 09:13:31,286 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-%d89015] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: skipping unrecognized file /tmp/junit-13147018424612011515/testCaptureSnapshotOnAppendEntriesWithUnapplied/journal-v1-1.log 09:13:31,286 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-%d89015] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: skipping unrecognized file /tmp/junit-13147018424612011515/testCaptureSnapshotOnAppendEntriesWithUnapplied/metadata-v1-1.log 09:13:31,286 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-%d89015] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: retaining snapshot SnapshotFileV1{lastIncluded=EntryInfo[index=0, term=1], timestamp=2025-09-02T21:13:31.284547243Z, file=/tmp/junit-13147018424612011515/testCaptureSnapshotOnAppendEntriesWithUnapplied/snapshot-0000000068B75DFB-10F5D8AB.v1, size=539, entryCompress=NONE, stateCompress=NONE} 09:13:31,286 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-%d89015] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnAppendEntriesWithUnapplied: 1 completion(s) pending 09:13:31,286 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnAppendEntriesWithUnapplied: running 1 completion(s) 09:13:31,286 PM [test-pekko.actor.default-dispatcher-5] [INFO] SnapshotManager - testCaptureSnapshotOnAppendEntriesWithUnapplied: snapshot is durable as of 2025-09-02T21:13:31.284547243Z 09:13:31,286 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] SnapshotManager - testCaptureSnapshotOnAppendEntriesWithUnapplied: Snapshot success, discarding journal entries up to 1 09:13:31,286 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftActorSnapshotMessageSupport - testCaptureSnapshotOnAppendEntriesWithUnapplied: SnapshotComplete received 09:13:31,286 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] JournalWriteTask - testCaptureSnapshotOnAppendEntriesWithUnapplied: received 1 commands after 2.570 ms 09:13:31,287 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnAppendEntriesWithUnapplied: updated meta to JournalMeta[replayFrom=2, applyTo=1] 09:13:31,287 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnAppendEntriesWithUnapplied: discarded entries up to (and including) 1 09:13:31,287 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnAppendEntriesWithUnapplied: 1 completion(s) pending 09:13:31,287 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] JournalWriteTask - testCaptureSnapshotOnAppendEntriesWithUnapplied: completed 1 commands in 95.41 μs 09:13:31,287 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnAppendEntriesWithUnapplied: running 1 completion(s) 09:13:31,287 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] JournalWriteTask - testCaptureSnapshotOnAppendEntriesWithUnapplied: waiting to receive commands 09:13:31,430 PM [awaitility-thread] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: selected SNAPSHOT_V1 to handle file /tmp/junit-13147018424612011515/testCaptureSnapshotOnAppendEntriesWithUnapplied/snapshot-0000000068B75DFB-10F5D8AB.v1 09:13:31,430 PM [awaitility-thread] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: skipping unrecognized file /tmp/junit-13147018424612011515/testCaptureSnapshotOnAppendEntriesWithUnapplied/TermInfo.properties 09:13:31,430 PM [awaitility-thread] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: skipping unrecognized file /tmp/junit-13147018424612011515/testCaptureSnapshotOnAppendEntriesWithUnapplied/journal-v1-1.log 09:13:31,430 PM [awaitility-thread] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: skipping unrecognized file /tmp/junit-13147018424612011515/testCaptureSnapshotOnAppendEntriesWithUnapplied/metadata-v1-1.log 09:13:31,430 PM [awaitility-thread] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: picked SnapshotFileV1{lastIncluded=EntryInfo[index=0, term=1], timestamp=2025-09-02T21:13:31.284547243Z, file=/tmp/junit-13147018424612011515/testCaptureSnapshotOnAppendEntriesWithUnapplied/snapshot-0000000068B75DFB-10F5D8AB.v1, size=539, entryCompress=NONE, stateCompress=NONE} as the latest file 09:13:31,432 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior505#-649518689] 09:13:31,435 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower506#492105890] 09:13:31,435 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader507#-622002355] 09:13:31,435 PM [main] [INFO] TestActorFactory - Killing actor TestActor[pekko://test/user/testCaptureSnapshotOnAppendEntriesWithUnapplied] 09:13:31,435 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] EnabledRaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: terminating thread VirtualThread[#634,testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157]/waiting 09:13:31,435 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] JournalWriteTask - testCaptureSnapshotOnAppendEntriesWithUnapplied: received 1 commands after 148.8 ms 09:13:31,436 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] JournalWriteTask - testCaptureSnapshotOnAppendEntriesWithUnapplied: completed 1 commands in 18.55 μs 09:13:31,436 PM [testCaptureSnapshotOnAppendEntriesWithUnapplied-writer-157] [DEBUG] JournalWriteTask - testCaptureSnapshotOnAppendEntriesWithUnapplied: journal writer stopped 09:13:31,436 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnAppendEntriesWithUnapplied: journal closed 09:13:31,436 PM [test-pekko.actor.default-dispatcher-5] [INFO] EnabledRaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: journal closed 09:13:31,436 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: stopped executor with 0 remaining tasks 09:13:31,436 PM [test-pekko.actor.default-dispatcher-5] [DEBUG] RaftStorage - testCaptureSnapshotOnAppendEntriesWithUnapplied: stopped executor with 0 remaining tasks 09:13:31,442 PM [main] [INFO] FollowerTest - Starting testFirstAppendEntriesWithNoPrevIndexAndReplicatedToAllPresentInSnapshotButCalculatedPrevEntryMissing 09:13:31,442 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,443 PM [main] [INFO] Follower - follower (Follower): Term 2 in "AppendEntries{term=2, leaderId=leader-1, prevLogIndex=-1, prevLogTerm=-1, leaderCommit=105, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=105, term=2, command=foo]]}" message is greater than follower's term 1 - updating term 09:13:31,444 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader-1, prevLogIndex=-1, prevLogTerm=-1, leaderCommit=105, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=105, term=2, command=foo]]} 09:13:31,444 PM [main] [INFO] Follower - follower (Follower): Cannot append entries because the calculated previousIndex 104 was not found in the in-memory journal - lastIndex: 100, snapshotIndex: 100, snapshotTerm: -1 09:13:31,444 PM [main] [INFO] Follower - follower (Follower): Follower is out-of-sync so sending negative reply: AppendEntriesReply{term=2, success=false, followerId=follower, logLastIndex=100, logLastTerm=-1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,445 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader-1, need to catch up to 105 09:13:31,445 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior508#652496737] 09:13:31,456 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower509#238896368] 09:13:31,456 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader510#985748972] 09:13:31,459 PM [main] [INFO] FollowerTest - Starting testHandleAppendEntriesSenderPrevLogIndexIsInTheSnapshot 09:13:31,459 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,460 PM [main] [INFO] Follower - follower (Follower): Term 3 in "AppendEntries{term=3, leaderId=leader, prevLogIndex=1, prevLogTerm=3, leaderCommit=8, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[]}" message is greater than follower's term 1 - updating term 09:13:31,461 PM [main] [DEBUG] Follower - follower (Follower): Commit index set to 7 09:13:31,461 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader, need to catch up to 8 09:13:31,461 PM [main] [DEBUG] Follower - follower (Follower): applyLogToStateMachine, appendEntries.getLeaderCommit(): 8, context.getLastApplied(): -1, lastIndex(): 7 09:13:31,462 PM [main] [WARN] RaftActorBehavior - follower (Follower): Missing index 0 from log. Cannot apply state. Ignoring 0 to 8 09:13:31,463 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior511#2051762098] 09:13:31,473 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower512#1995207867] 09:13:31,474 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader513#308595735] 09:13:31,477 PM [main] [INFO] FollowerTest - Starting testHandleAppendEntriesCorrectReceiverLogEntries 09:13:31,477 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,478 PM [main] [INFO] Follower - follower (Follower): Term 2 in "AppendEntries{term=2, leaderId=leader, prevLogIndex=1, prevLogTerm=1, leaderCommit=3, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=2, term=2, command=two-1], DefaultLogEntry[index=3, term=2, command=three]]}" message is greater than follower's term 1 - updating term 09:13:31,479 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader, prevLogIndex=1, prevLogTerm=1, leaderCommit=3, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=2, term=2, command=two-1], DefaultLogEntry[index=3, term=2, command=three]]} 09:13:31,480 PM [main] [DEBUG] Follower - follower (Follower): Number of entries to be appended = 2 09:13:31,480 PM [main] [DEBUG] Follower - follower (Follower): matchEntry DefaultLogEntry[index=2, term=2, command=two-1] is present: existingEntryTerm: 1 09:13:31,480 PM [main] [DEBUG] DefaultConfigParamsImpl - No custom RaftPolicy specified. Using DefaultRaftPolicy 09:13:31,480 PM [main] [INFO] Follower - follower (Follower): Removing entries from log starting at 2, commitIndex: -1, lastApplied: -1 09:13:31,480 PM [main] [DEBUG] Follower - follower (Follower): After cleanup, lastIndex: 1, entries to be added from: 0 09:13:31,480 PM [main] [DEBUG] Follower - follower (Follower): Append entry to log two-1 09:13:31,480 PM [main] [DEBUG] Follower - follower (Follower): Append entry to log three 09:13:31,480 PM [main] [DEBUG] Follower - follower (Follower): Log size is now 4 09:13:31,481 PM [main] [DEBUG] Follower - follower (Follower): Commit index set to 3 09:13:31,481 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries returning : AppendEntriesReply{term=2, success=true, followerId=follower, logLastIndex=3, logLastTerm=2, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,481 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader, need to catch up to 3 09:13:31,481 PM [main] [DEBUG] Follower - follower (Follower): applyLogToStateMachine, appendEntries.getLeaderCommit(): 3, context.getLastApplied(): -1, lastIndex(): 3 09:13:31,481 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Setting last applied to 0 09:13:31,481 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 0 09:13:31,482 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Setting last applied to 1 09:13:31,482 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from 0 to 1 09:13:31,482 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Setting last applied to 2 09:13:31,482 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from 1 to 2 09:13:31,482 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Setting last applied to 3 09:13:31,482 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from 2 to 3 09:13:31,483 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior514#1372787858] 09:13:31,493 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower515#1483623893] 09:13:31,495 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader516#1106494905] 09:13:31,498 PM [main] [INFO] FollowerTest - Starting testHandleOutOfSequenceInstallSnapshot 09:13:31,499 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,500 PM [main] [DEBUG] Follower - follower (Follower): handleInstallSnapshot: InstallSnapshot{term=1, leaderId=leader, lastIncludedIndex=3, lastIncludedTerm=1, datasize=50, chunk=3/3, lastChunkHashCode=OptionalInt.empty} 09:13:31,500 PM [main] [DEBUG] Follower - follower (Follower): expected chunkIndex 1 got 3 09:13:31,501 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior517#1720160094] 09:13:31,512 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower518#1640354759] 09:13:31,512 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader519#1789503916] 09:13:31,517 PM [main] [INFO] FollowerTest - Starting testReceivingAppendEntriesDuringInstallSnapshotFromDifferentLeader 09:13:31,517 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,518 PM [main] [DEBUG] Follower - follower (Follower): handleInstallSnapshot: InstallSnapshot{term=1, leaderId=leader, lastIncludedIndex=1, lastIncludedTerm=1, datasize=50, chunk=1/2, lastChunkHashCode=OptionalInt.empty} 09:13:31,518 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader, need to catch up to 1 09:13:31,518 PM [main] [DEBUG] SnapshotTracker - follower (Follower): addChunk: chunkIndex=1, lastChunkIndex=0, collectedChunks.size=0, lastChunkHashCode=-1 09:13:31,518 PM [main] [DEBUG] Follower - follower (Follower): handleInstallSnapshot returning: InstallSnapshotReply{term=1, followerId=follower, chunkIndex=1, success=true} 09:13:31,520 PM [main] [INFO] Follower - follower (Follower): Term 2 in "AppendEntries{term=2, leaderId=new-leader, prevLogIndex=1, prevLogTerm=1, leaderCommit=2, replicatedToAllIndex=-1, payloadVersion=1, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=2, term=2, command=3]]}" message is greater than follower's term 1 - updating term 09:13:31,520 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=new-leader, prevLogIndex=1, prevLogTerm=1, leaderCommit=2, replicatedToAllIndex=-1, payloadVersion=1, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=2, term=2, command=3]]} 09:13:31,520 PM [main] [DEBUG] Follower - follower (Follower): snapshot install is in progress but the prior snapshot leaderId leader does not match the AppendEntries leaderId new-leader 09:13:31,521 PM [main] [DEBUG] Follower - follower (Follower): Number of entries to be appended = 1 09:13:31,521 PM [main] [DEBUG] Follower - follower (Follower): After cleanup, lastIndex: 1, entries to be added from: 0 09:13:31,521 PM [main] [DEBUG] Follower - follower (Follower): Append entry to log 3 09:13:31,521 PM [main] [DEBUG] Follower - follower (Follower): Log size is now 3 09:13:31,521 PM [main] [DEBUG] Follower - follower (Follower): Commit index set to 2 09:13:31,521 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries returning : AppendEntriesReply{term=2, success=true, followerId=follower, logLastIndex=2, logLastTerm=2, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,522 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader new-leader, need to catch up to 2 09:13:31,522 PM [main] [DEBUG] Follower - follower (Follower): applyLogToStateMachine, appendEntries.getLeaderCommit(): 2, context.getLastApplied(): 1, lastIndex(): 2 09:13:31,522 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Setting last applied to 2 09:13:31,522 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from 1 to 2 09:13:31,522 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior520#-2023304966] 09:13:31,533 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower521#-464767232] 09:13:31,533 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader522#1317067556] 09:13:31,537 PM [main] [INFO] FollowerTest - Starting testHandleAppendEntriesLeaderChangedAfterSyncUpComplete 09:13:31,537 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,537 PM [main] [INFO] Follower - follower (Follower): Term 2 in "AppendEntries{term=2, leaderId=leader-1, prevLogIndex=100, prevLogTerm=1, leaderCommit=101, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]}" message is greater than follower's term 1 - updating term 09:13:31,538 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader-1, prevLogIndex=100, prevLogTerm=1, leaderCommit=101, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]} 09:13:31,538 PM [main] [INFO] Follower - follower (Follower): The log is not empty but the prevLogIndex 100 was not found in it - lastIndex: 1, snapshotIndex: -1, snapshotTerm: -1 09:13:31,538 PM [main] [INFO] Follower - follower (Follower): Follower is out-of-sync so sending negative reply: AppendEntriesReply{term=2, success=false, followerId=follower, logLastIndex=1, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,538 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader-1, need to catch up to 101 09:13:31,538 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 101 09:13:31,539 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader-1, prevLogIndex=101, prevLogTerm=1, leaderCommit=102, replicatedToAllIndex=101, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]} 09:13:31,539 PM [main] [INFO] Follower - follower (Follower): The log is not empty but the prevLogIndex 101 was not found in it - lastIndex: 101, snapshotIndex: -1, snapshotTerm: -1 09:13:31,540 PM [main] [INFO] Follower - follower (Follower): Follower is out-of-sync so sending negative reply: AppendEntriesReply{term=2, success=false, followerId=follower, logLastIndex=101, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,540 PM [main] [DEBUG] SyncStatusTracker - follower: Lagging 1 entries behind leader leader-1 and reached 101 (of expected 101) 09:13:31,540 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 100 09:13:31,540 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader-2, prevLogIndex=45, prevLogTerm=1, leaderCommit=46, replicatedToAllIndex=100, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=101, term=2, command=foo]]} 09:13:31,541 PM [main] [INFO] Follower - follower (Follower): The log is not empty but the prevLogIndex 45 was not found in it - lastIndex: 100, snapshotIndex: -1, snapshotTerm: -1 09:13:31,541 PM [main] [INFO] Follower - follower (Follower): Follower is out-of-sync so sending negative reply: AppendEntriesReply{term=2, success=false, followerId=follower, logLastIndex=100, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:31,541 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader-2, need to catch up to 46 09:13:31,542 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior523#-1980322005] 09:13:31,552 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower524#2111498399] 09:13:31,553 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader525#-726559014] 09:13:31,557 PM [main] [INFO] FollowerTest - Starting testHandleElectionTimeoutWhenNoLeaderMessageReceived 09:13:31,557 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,757 PM [main] [DEBUG] DefaultConfigParamsImpl - No custom RaftPolicy specified. Using DefaultRaftPolicy 09:13:31,757 PM [main] [DEBUG] Follower - follower (Follower): Checking if this node is isolated in the cluster unreachable set [],all members [] self member: Member(pekko://test@10.30.170.48:17355, Removed) 09:13:31,758 PM [main] [DEBUG] Follower - follower (Follower): Received ElectionTimeout - switching to Candidate 09:13:31,758 PM [main] [DEBUG] Candidate - follower (Candidate): Election: Candidate has following voting peers: [] 09:13:31,758 PM [main] [INFO] Candidate - follower (Candidate): Starting new election term 2 09:13:31,758 PM [main] [INFO] RaftActorBehavior - follower (Follower) :- Switching from behavior Follower to Candidate, election term: 2 09:13:31,758 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior526#1330643498] 09:13:31,769 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower527#-1704661626] 09:13:31,769 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader528#-226062651] 09:13:31,774 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,774 PM [main] [DEBUG] PeerInfos - follower: Updated server config: isVoting: false, peers: [] 09:13:31,975 PM [main] [DEBUG] DefaultConfigParamsImpl - No custom RaftPolicy specified. Using DefaultRaftPolicy 09:13:31,975 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior529#733319161] 09:13:31,986 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower530#1883789574] 09:13:31,987 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader531#1987982147] 09:13:31,990 PM [main] [INFO] FollowerTest - Starting testHandleRequestVoteWhenSenderTermEqualToCurrentTermAndVotedForIsNull 09:13:31,991 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:31,993 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): In requestVote: RequestVote{term=1000, candidateId=test, lastLogIndex=10000, lastLogTerm=999} - currentTerm: 1000, votedFor: null, lastIndex: 1, lastTerm: 1 09:13:31,994 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): requestVote returning: RequestVoteReply{term=1000, voteGranted=true} 09:13:31,995 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior532#-990535090] 09:13:32,6 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower533#-296886538] 09:13:32,6 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader534#544349673] 09:13:32,11 PM [main] [INFO] FollowerTest - Starting testHandleAppendEntriesAddNewEntries 09:13:32,12 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:32,13 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=1, leaderId=leader-1, prevLogIndex=2, prevLogTerm=1, leaderCommit=4, replicatedToAllIndex=-1, payloadVersion=10, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=3, term=1, command=three], DefaultLogEntry[index=4, term=1, command=four]]} 09:13:32,14 PM [main] [DEBUG] Follower - follower (Follower): Number of entries to be appended = 2 09:13:32,14 PM [main] [DEBUG] Follower - follower (Follower): After cleanup, lastIndex: 2, entries to be added from: 0 09:13:32,14 PM [main] [DEBUG] Follower - follower (Follower): Append entry to log three 09:13:32,14 PM [main] [DEBUG] Follower - follower (Follower): Append entry to log four 09:13:32,14 PM [main] [DEBUG] Follower - follower (Follower): Log size is now 5 09:13:32,14 PM [main] [DEBUG] Follower - follower (Follower): Commit index set to 4 09:13:32,14 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries returning : AppendEntriesReply{term=1, success=true, followerId=follower, logLastIndex=4, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:32,15 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader-1, need to catch up to 4 09:13:32,15 PM [main] [DEBUG] Follower - follower (Follower): applyLogToStateMachine, appendEntries.getLeaderCommit(): 4, context.getLastApplied(): -1, lastIndex(): 4 09:13:32,15 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Setting last applied to 0 09:13:32,15 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 0 09:13:32,15 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Setting last applied to 1 09:13:32,15 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from 0 to 1 09:13:32,15 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Setting last applied to 2 09:13:32,15 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from 1 to 2 09:13:32,15 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Setting last applied to 3 09:13:32,15 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from 2 to 3 09:13:32,15 PM [main] [DEBUG] RaftActorBehavior - follower (Follower): Setting last applied to 4 09:13:32,15 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from 3 to 4 09:13:32,16 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior535#-1030381438] 09:13:32,26 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower536#-1626475170] 09:13:32,27 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader537#-1844160425] 09:13:32,30 PM [main] [INFO] FollowerTest - Starting testReceivingAppendEntriesDuringInstallSnapshot 09:13:32,30 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:32,31 PM [main] [DEBUG] Follower - follower (Follower): handleInstallSnapshot: InstallSnapshot{term=1, leaderId=leader, lastIncludedIndex=1, lastIncludedTerm=1, datasize=50, chunk=1/2, lastChunkHashCode=OptionalInt.empty} 09:13:32,31 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader, need to catch up to 1 09:13:32,31 PM [main] [DEBUG] SnapshotTracker - follower (Follower): addChunk: chunkIndex=1, lastChunkIndex=0, collectedChunks.size=0, lastChunkHashCode=-1 09:13:32,31 PM [main] [DEBUG] Follower - follower (Follower): handleInstallSnapshot returning: InstallSnapshotReply{term=1, followerId=follower, chunkIndex=1, success=true} 09:13:32,33 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=1, leaderId=leader, prevLogIndex=1, prevLogTerm=1, leaderCommit=2, replicatedToAllIndex=-1, payloadVersion=1, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=1, term=2, command=3]]} 09:13:32,34 PM [main] [DEBUG] Follower - follower (Follower): snapshot install is in progress, replying immediately with AppendEntriesReply{term=1, success=true, followerId=follower, logLastIndex=1, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:32,35 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior538#-745379714] 09:13:32,45 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower539#518326025] 09:13:32,45 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader540#-1829706211] 09:13:32,52 PM [main] [INFO] FollowerTest - Starting testHandleAppendEntriesWhenOutOfSyncLogDetectedRequestForceInstallSnapshot 09:13:32,52 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:32,53 PM [main] [INFO] Follower - follower (Follower): Term 2 in "AppendEntries{term=2, leaderId=leader, prevLogIndex=1, prevLogTerm=1, leaderCommit=3, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=2, term=2, command=two-1], DefaultLogEntry[index=3, term=2, command=three]]}" message is greater than follower's term 1 - updating term 09:13:32,54 PM [main] [DEBUG] Follower - follower (Follower): handleAppendEntries: AppendEntries{term=2, leaderId=leader, prevLogIndex=1, prevLogTerm=1, leaderCommit=3, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=2, term=2, command=two-1], DefaultLogEntry[index=3, term=2, command=three]]} 09:13:32,54 PM [main] [DEBUG] Follower - follower (Follower): Number of entries to be appended = 2 09:13:32,54 PM [main] [DEBUG] Follower - follower (Follower): matchEntry DefaultLogEntry[index=2, term=2, command=two-1] is present: existingEntryTerm: 1 09:13:32,54 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader, need to catch up to 3 09:13:32,55 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior541#756174381] 09:13:32,66 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower542#750644757] 09:13:32,66 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader543#1905428901] 09:13:32,69 PM [main] [INFO] FollowerTest - Starting testCaptureSnapshotOnMiddleEntryInAppendEntries 09:13:32,73 PM [main] [DEBUG] PropertiesTermInfoStore - testCaptureSnapshotOnMiddleEntryInAppendEntries: Set currentTerm=1, votedFor=null 09:13:32,73 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] MockRaftActor - Actor created TestActor[pekko://test/user/testCaptureSnapshotOnMiddleEntryInAppendEntries] [WARN] [09/02/2025 21:13:32.074] [test-pekko.actor.default-dispatcher-5] [pekko://test/user/termination-monitor] received dead letter from TestActor[pekko://test/user/testCaptureSnapshotOnMiddleEntryInAppendEntries]: org.opendaylight.controller.cluster.common.actor.Monitor@60a85ba0 [INFO] [pekkoDeadLetter][09/02/2025 21:13:32.074] [test-pekko.actor.default-dispatcher-11] [pekko://test/user/termination-monitor] Message [org.opendaylight.controller.cluster.common.actor.Monitor] from TestActor[pekko://test/user/testCaptureSnapshotOnMiddleEntryInAppendEntries] to Actor[pekko://test/user/termination-monitor] was not delivered. [5] dead letters encountered. If this is not an expected behavior then Actor[pekko://test/user/termination-monitor] may have terminated unexpectedly. This logging can be turned off or adjusted with configuration settings 'pekko.log-dead-letters' and 'pekko.log-dead-letters-during-shutdown'. 09:13:32,74 PM [test-pekko.actor.default-dispatcher-5] [INFO] EmptyLocalActorRef - pekkoDeadLetter Message [org.opendaylight.controller.cluster.common.actor.Monitor] from TestActor[pekko://test/user/testCaptureSnapshotOnMiddleEntryInAppendEntries] to Actor[pekko://test/user/termination-monitor] was not delivered. [5] dead letters encountered. If this is not an expected behavior then Actor[pekko://test/user/termination-monitor] may have terminated unexpectedly. This logging can be turned off or adjusted with configuration settings 'pekko.log-dead-letters' and 'pekko.log-dead-letters-during-shutdown'. 09:13:32,74 PM [test-pekko.actor.default-dispatcher-4] [INFO] RaftActor - testCaptureSnapshotOnMiddleEntryInAppendEntries: Starting recovery with journal batch size 1000 09:13:32,74 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: started executor 09:13:32,74 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: started executor 09:13:32,75 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnMiddleEntryInAppendEntries: metadata journal open: replayFrom=1 applyTo=0 09:13:32,75 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnMiddleEntryInAppendEntries: journal open: firstIndex=1 lastIndex=0 replayFrom=1 fileEntries=0 09:13:32,75 PM [test-pekko.actor.default-dispatcher-4] [INFO] EnabledRaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: journal open: applyTo=0 09:13:32,75 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftActor - testCaptureSnapshotOnMiddleEntryInAppendEntries: starting journal recovery 09:13:32,75 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: journal writer started 09:13:32,75 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: waiting to receive commands 09:13:32,75 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] PropertiesTermInfoStore - /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/TermInfo.properties does not exist 09:13:32,78 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] PropertiesTermInfoStore - testCaptureSnapshotOnMiddleEntryInAppendEntries: Set currentTerm=0, votedFor=null 09:13:32,78 PM [test-pekko.actor.default-dispatcher-4] [INFO] Recovery - testCaptureSnapshotOnMiddleEntryInAppendEntries: Local TermInfo store seeded with TermInfo{term=0} 09:13:32,78 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: skipping unrecognized file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/TermInfo.properties 09:13:32,78 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: skipping unrecognized file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/journal-v1-1.log 09:13:32,78 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: skipping unrecognized file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/metadata-v1-1.log 09:13:32,78 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: no eligible files found 09:13:32,78 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] AbstractReplicatedLog - testCaptureSnapshotOnMiddleEntryInAppendEntries: Moving last applied index from -1 to -1 09:13:32,78 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] JournalRecovery - testCaptureSnapshotOnMiddleEntryInAppendEntries: empty journal: appending 0 entries 09:13:32,79 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnMiddleEntryInAppendEntries: updated meta to JournalMeta[replayFrom=1, applyTo=0] 09:13:32,79 PM [test-pekko.actor.default-dispatcher-4] [INFO] Recovery - testCaptureSnapshotOnMiddleEntryInAppendEntries: Recovery completed in in 3.507 ms: last log index = -1, last log term = -1, napshot index = -1, snapshot term = -1, journal size = 0 09:13:32,79 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftActor - testCaptureSnapshotOnMiddleEntryInAppendEntries: Recovery completed and can restore from snapshot 09:13:32,79 PM [main] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: skipping unrecognized file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/TermInfo.properties 09:13:32,79 PM [main] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: skipping unrecognized file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/journal-v1-1.log 09:13:32,79 PM [main] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: skipping unrecognized file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/metadata-v1-1.log 09:13:32,79 PM [main] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: no eligible files found 09:13:32,79 PM [test-pekko.actor.default-dispatcher-4] [INFO] Follower - testCaptureSnapshotOnMiddleEntryInAppendEntries (Follower): Term 1 in "AppendEntries{term=1, leaderId=leader, prevLogIndex=-1, prevLogTerm=-1, leaderCommit=2, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=0, term=1, command=one], DefaultLogEntry[index=1, term=1, command=two], DefaultLogEntry[index=2, term=1, command=three]]}" message is greater than follower's term 0 - updating term 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] PropertiesTermInfoStore - testCaptureSnapshotOnMiddleEntryInAppendEntries: Set currentTerm=1, votedFor=null 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnMiddleEntryInAppendEntries (Follower): handleAppendEntries: AppendEntries{term=1, leaderId=leader, prevLogIndex=-1, prevLogTerm=-1, leaderCommit=2, replicatedToAllIndex=-1, payloadVersion=0, recipientRaftVersion=5, leaderRaftVersion=5, entries==[DefaultLogEntry[index=0, term=1, command=one], DefaultLogEntry[index=1, term=1, command=two], DefaultLogEntry[index=2, term=1, command=three]]} 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnMiddleEntryInAppendEntries (Follower): Number of entries to be appended = 3 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnMiddleEntryInAppendEntries (Follower): After cleanup, lastIndex: -1, entries to be added from: 0 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnMiddleEntryInAppendEntries (Follower): Append entry to log one 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] ReplicatedLogImpl - testCaptureSnapshotOnMiddleEntryInAppendEntries: Append log entry and persist DefaultLogEntry[index=0, term=1, command=one] 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnMiddleEntryInAppendEntries (Follower): Append entry to log two 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] ReplicatedLogImpl - testCaptureSnapshotOnMiddleEntryInAppendEntries: Append log entry and persist DefaultLogEntry[index=1, term=1, command=two] 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnMiddleEntryInAppendEntries (Follower): Append entry to log three 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] ReplicatedLogImpl - testCaptureSnapshotOnMiddleEntryInAppendEntries: Append log entry and persist DefaultLogEntry[index=2, term=1, command=three] 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnMiddleEntryInAppendEntries (Follower): Log size is now 3 09:13:32,83 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: received 1 commands after 7.725 ms 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnMiddleEntryInAppendEntries (Follower): Commit index set to 2 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnMiddleEntryInAppendEntries (Follower): handleAppendEntries returning : AppendEntriesReply{term=1, success=true, followerId=testCaptureSnapshotOnMiddleEntryInAppendEntries, logLastIndex=2, logLastTerm=1, forceInstallSnapshot=false, needsLeaderAddress=false, payloadVersion=5, raftVersion=5, recipientRaftVersion=5} 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] SyncStatusTracker - testCaptureSnapshotOnMiddleEntryInAppendEntries: Last sync leader does not match current leader leader, need to catch up to 2 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Follower - testCaptureSnapshotOnMiddleEntryInAppendEntries (Follower): applyLogToStateMachine, appendEntries.getLeaderCommit(): 2, context.getLastApplied(): -1, lastIndex(): 2 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftActorBehavior - testCaptureSnapshotOnMiddleEntryInAppendEntries (Follower): Setting last applied to 0 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] AbstractReplicatedLog - testCaptureSnapshotOnMiddleEntryInAppendEntries: Moving last applied index from -1 to 0 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftActor - testCaptureSnapshotOnMiddleEntryInAppendEntries: Applying state for log index 0 data one 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [INFO] MockRaftActor - testCaptureSnapshotOnMiddleEntryInAppendEntries: applyState called: one 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftActorBehavior - testCaptureSnapshotOnMiddleEntryInAppendEntries (Follower): Setting last applied to 1 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] AbstractReplicatedLog - testCaptureSnapshotOnMiddleEntryInAppendEntries: Moving last applied index from 0 to 1 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftActor - testCaptureSnapshotOnMiddleEntryInAppendEntries: Applying state for log index 1 data two 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [INFO] MockRaftActor - testCaptureSnapshotOnMiddleEntryInAppendEntries: applyState called: two 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftActorBehavior - testCaptureSnapshotOnMiddleEntryInAppendEntries (Follower): Setting last applied to 2 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] AbstractReplicatedLog - testCaptureSnapshotOnMiddleEntryInAppendEntries: Moving last applied index from 1 to 2 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftActor - testCaptureSnapshotOnMiddleEntryInAppendEntries: Applying state for log index 2 data three 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [INFO] MockRaftActor - testCaptureSnapshotOnMiddleEntryInAppendEntries: applyState called: three 09:13:32,83 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnMiddleEntryInAppendEntries: awaiting more completions to resolve 3 synchronized callback(s) 09:13:32,86 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnMiddleEntryInAppendEntries: 1 completion(s) pending 09:13:32,86 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnMiddleEntryInAppendEntries: running 1 completion(s) 09:13:32,86 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: completed 1 commands in 3.151 ms 09:13:32,86 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: received 3 commands after 2.880 μs 09:13:32,86 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] ReplicatedLogImpl - testCaptureSnapshotOnMiddleEntryInAppendEntries: persist complete JournaledLogEntry{index=0, term=1, command=one, pending=false} 09:13:32,86 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnMiddleEntryInAppendEntries: completed synchronized callback AppendReceivedCallback{entry=JournaledLogEntry{index=0, term=1, command=one, pending=false}, callback=org.opendaylight.controller.cluster.raft.behaviors.Follower$$Lambda/0x00000007c08d4f50@48064579} 09:13:32,86 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnMiddleEntryInAppendEntries: awaiting more completions to resolve 2 synchronized callback(s) 09:13:32,87 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnMiddleEntryInAppendEntries: updated meta to JournalMeta[replayFrom=1, applyTo=3] 09:13:32,87 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnMiddleEntryInAppendEntries: 3 completion(s) pending 09:13:32,87 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnMiddleEntryInAppendEntries: running 3 completion(s) 09:13:32,87 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: completed 3 commands in 1.217 ms 09:13:32,87 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: waiting to receive commands 09:13:32,87 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] ReplicatedLogImpl - testCaptureSnapshotOnMiddleEntryInAppendEntries: persist complete JournaledLogEntry{index=1, term=1, command=two, pending=false} 09:13:32,87 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnMiddleEntryInAppendEntries: completed synchronized callback AppendReceivedCallback{entry=JournaledLogEntry{index=1, term=1, command=two, pending=false}, callback=org.opendaylight.controller.cluster.raft.behaviors.Follower$$Lambda/0x00000007c08d4f50@48064579} 09:13:32,87 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] ReplicatedLogImpl - testCaptureSnapshotOnMiddleEntryInAppendEntries: persist complete JournaledLogEntry{index=2, term=1, command=three, pending=false} 09:13:32,87 PM [test-pekko.actor.default-dispatcher-4] [INFO] SnapshotManager - testCaptureSnapshotOnMiddleEntryInAppendEntries: Initiating snapshot capture CaptureSnapshot [lastAppliedIndex=2, lastAppliedTerm=1, lastIndex=2, lastTerm=1, installSnapshotInitiated=, replicatedToAllIndex=-1, replicatedToAllTerm=-1, unAppliedEntries size=0, mandatoryTrim=false] 09:13:32,87 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] SnapshotManager - testCaptureSnapshotOnMiddleEntryInAppendEntries: captured snapshot at lastSequenceNumber: 3 09:13:32,87 PM [test-pekko.actor.default-dispatcher-4] [INFO] SnapshotManager - testCaptureSnapshotOnMiddleEntryInAppendEntries: Persising snapshot at EntryInfo[index=2, term=1]/EntryInfo[index=2, term=1] 09:13:32,87 PM [test-pekko.actor.default-dispatcher-4] [INFO] MockRaftActor - testCaptureSnapshotOnMiddleEntryInAppendEntries: support() called 09:13:32,88 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] SnapshotManager - testCaptureSnapshotOnMiddleEntryInAppendEntries: log size 3 exceeds the snapshot batch count 2 - doing snapshotPreCommit with index 2 09:13:32,88 PM [test-pekko.actor.default-dispatcher-4] [INFO] SnapshotManager - testCaptureSnapshotOnMiddleEntryInAppendEntries: Removed in-memory snapshotted entries, adjusted snapshotIndex: 2 and term: 1 09:13:32,88 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnMiddleEntryInAppendEntries: completed synchronized callback AppendReceivedCallback{entry=JournaledLogEntry{index=2, term=1, command=three, pending=false}, callback=org.opendaylight.controller.cluster.raft.behaviors.Follower$$Lambda/0x00000007c08d4f50@48064579} 09:13:32,88 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-%d321870] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: starting snapshot writeout to /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/snapshot-0000000068B75DFC-053E10A1.tmp 09:13:32,88 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnMiddleEntryInAppendEntries: synchronized callbacks after 4.421 ms [WARN] [09/02/2025 21:13:32.088] [test-pekko.actor.default-dispatcher-4] [pekko://test/user/testCaptureSnapshotOnMiddleEntryInAppendEntries] unhandled message from Actor[pekko://test/deadLetters]: FollowerInitialSyncUpStatus[memberId=testCaptureSnapshotOnMiddleEntryInAppendEntries, initialSyncDone=false] 09:13:32,88 PM [test-pekko.actor.default-dispatcher-5] [INFO] TestActorRef - pekkoDeadLetter Message [org.opendaylight.controller.cluster.raft.base.messages.FollowerInitialSyncUpStatus] to TestActor[pekko://test/user/testCaptureSnapshotOnMiddleEntryInAppendEntries] was unhandled. [6] dead letters encountered. This logging can be turned off or adjusted with configuration settings 'pekko.log-dead-letters' and 'pekko.log-dead-letters-during-shutdown'. [INFO] [pekkoDeadLetter][09/02/2025 21:13:32.088] [test-pekko.actor.default-dispatcher-5] [pekko://test/user/testCaptureSnapshotOnMiddleEntryInAppendEntries] Message [org.opendaylight.controller.cluster.raft.base.messages.FollowerInitialSyncUpStatus] to TestActor[pekko://test/user/testCaptureSnapshotOnMiddleEntryInAppendEntries] was unhandled. [6] dead letters encountered. This logging can be turned off or adjusted with configuration settings 'pekko.log-dead-letters' and 'pekko.log-dead-letters-during-shutdown'. 09:13:32,91 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-%d321870] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: finished snapshot writeout to /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/snapshot-0000000068B75DFC-053E10A1.v1 09:13:32,91 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-%d321870] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: selected SNAPSHOT_V1 to handle file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/snapshot-0000000068B75DFC-053E10A1.v1 09:13:32,91 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-%d321870] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: skipping unrecognized file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/TermInfo.properties 09:13:32,91 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-%d321870] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: skipping unrecognized file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/journal-v1-1.log 09:13:32,91 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-%d321870] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: skipping unrecognized file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/metadata-v1-1.log 09:13:32,91 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-%d321870] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: retaining snapshot SnapshotFileV1{lastIncluded=EntryInfo[index=2, term=1], timestamp=2025-09-02T21:13:32.087953569Z, file=/tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/snapshot-0000000068B75DFC-053E10A1.v1, size=573, entryCompress=NONE, stateCompress=NONE} 09:13:32,91 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-%d321870] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnMiddleEntryInAppendEntries: 1 completion(s) pending 09:13:32,91 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnMiddleEntryInAppendEntries: running 1 completion(s) 09:13:32,91 PM [test-pekko.actor.default-dispatcher-4] [INFO] SnapshotManager - testCaptureSnapshotOnMiddleEntryInAppendEntries: snapshot is durable as of 2025-09-02T21:13:32.087953569Z 09:13:32,91 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] SnapshotManager - testCaptureSnapshotOnMiddleEntryInAppendEntries: Snapshot success, discarding journal entries up to 3 09:13:32,91 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftActorSnapshotMessageSupport - testCaptureSnapshotOnMiddleEntryInAppendEntries: SnapshotComplete received 09:13:32,91 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: received 1 commands after 4.181 ms 09:13:32,92 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnMiddleEntryInAppendEntries: updated meta to JournalMeta[replayFrom=4, applyTo=3] 09:13:32,92 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnMiddleEntryInAppendEntries: discarded entries up to (and including) 3 09:13:32,92 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnMiddleEntryInAppendEntries: 1 completion(s) pending 09:13:32,92 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: completed 1 commands in 102.4 μs 09:13:32,92 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: waiting to receive commands 09:13:32,92 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorageCompleter - testCaptureSnapshotOnMiddleEntryInAppendEntries: running 1 completion(s) 09:13:32,231 PM [awaitility-thread] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: selected SNAPSHOT_V1 to handle file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/snapshot-0000000068B75DFC-053E10A1.v1 09:13:32,231 PM [awaitility-thread] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: skipping unrecognized file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/TermInfo.properties 09:13:32,231 PM [awaitility-thread] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: skipping unrecognized file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/journal-v1-1.log 09:13:32,231 PM [awaitility-thread] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: skipping unrecognized file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/metadata-v1-1.log 09:13:32,231 PM [awaitility-thread] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: picked SnapshotFileV1{lastIncluded=EntryInfo[index=2, term=1], timestamp=2025-09-02T21:13:32.087953569Z, file=/tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/snapshot-0000000068B75DFC-053E10A1.v1, size=573, entryCompress=NONE, stateCompress=NONE} as the latest file 09:13:32,234 PM [main] [INFO] TestActorFactory - Killing actor TestActor[pekko://test/user/testCaptureSnapshotOnMiddleEntryInAppendEntries] 09:13:32,245 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] EnabledRaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: terminating thread VirtualThread[#637,testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158]/waiting 09:13:32,245 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: received 1 commands after 153.5 ms 09:13:32,245 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: completed 1 commands in 14.86 μs 09:13:32,245 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-158] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: journal writer stopped 09:13:32,245 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnMiddleEntryInAppendEntries: journal closed 09:13:32,245 PM [test-pekko.actor.default-dispatcher-4] [INFO] EnabledRaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: journal closed 09:13:32,245 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: stopped executor with 0 remaining tasks 09:13:32,246 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: stopped executor with 0 remaining tasks 09:13:32,246 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] MockRaftActor - Actor created TestActor[pekko://test/user/testCaptureSnapshotOnMiddleEntryInAppendEntries] [WARN] [09/02/2025 21:13:32.246] [test-pekko.actor.default-dispatcher-11] [pekko://test/user/termination-monitor] received dead letter from TestActor[pekko://test/user/testCaptureSnapshotOnMiddleEntryInAppendEntries]: org.opendaylight.controller.cluster.common.actor.Monitor@4b29a08a 09:13:32,247 PM [test-pekko.actor.default-dispatcher-4] [INFO] RaftActor - testCaptureSnapshotOnMiddleEntryInAppendEntries: Starting recovery with journal batch size 1000 [INFO] [pekkoDeadLetter][09/02/2025 21:13:32.246] [test-pekko.actor.default-dispatcher-11] [pekko://test/user/termination-monitor] Message [org.opendaylight.controller.cluster.common.actor.Monitor] from TestActor[pekko://test/user/testCaptureSnapshotOnMiddleEntryInAppendEntries] to Actor[pekko://test/user/termination-monitor] was not delivered. [7] dead letters encountered. If this is not an expected behavior then Actor[pekko://test/user/termination-monitor] may have terminated unexpectedly. This logging can be turned off or adjusted with configuration settings 'pekko.log-dead-letters' and 'pekko.log-dead-letters-during-shutdown'. 09:13:32,247 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: started executor 09:13:32,247 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: started executor 09:13:32,247 PM [test-pekko.actor.default-dispatcher-12] [INFO] EmptyLocalActorRef - pekkoDeadLetter Message [org.opendaylight.controller.cluster.common.actor.Monitor] from TestActor[pekko://test/user/testCaptureSnapshotOnMiddleEntryInAppendEntries] to Actor[pekko://test/user/termination-monitor] was not delivered. [7] dead letters encountered. If this is not an expected behavior then Actor[pekko://test/user/termination-monitor] may have terminated unexpectedly. This logging can be turned off or adjusted with configuration settings 'pekko.log-dead-letters' and 'pekko.log-dead-letters-during-shutdown'. 09:13:32,247 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnMiddleEntryInAppendEntries: metadata journal open: replayFrom=4 applyTo=3 09:13:32,248 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnMiddleEntryInAppendEntries: journal open: firstIndex=1 lastIndex=3 replayFrom=4 fileEntries=0 09:13:32,248 PM [test-pekko.actor.default-dispatcher-4] [INFO] EnabledRaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: journal open: applyTo=3 09:13:32,248 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftActor - testCaptureSnapshotOnMiddleEntryInAppendEntries: starting journal recovery 09:13:32,248 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-159] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: journal writer started 09:13:32,248 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-159] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: waiting to receive commands 09:13:32,248 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] PropertiesTermInfoStore - testCaptureSnapshotOnMiddleEntryInAppendEntries: Set currentTerm=1, votedFor=null 09:13:32,248 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: selected SNAPSHOT_V1 to handle file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/snapshot-0000000068B75DFC-053E10A1.v1 09:13:32,249 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: skipping unrecognized file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/TermInfo.properties 09:13:32,249 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: skipping unrecognized file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/journal-v1-1.log 09:13:32,249 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: skipping unrecognized file /tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/metadata-v1-1.log 09:13:32,249 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: picked SnapshotFileV1{lastIncluded=EntryInfo[index=2, term=1], timestamp=2025-09-02T21:13:32.087953569Z, file=/tmp/junit-16784986447160221813/testCaptureSnapshotOnMiddleEntryInAppendEntries/snapshot-0000000068B75DFC-053E10A1.v1, size=573, entryCompress=NONE, stateCompress=NONE} as the latest file 09:13:32,249 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] Recovery - testCaptureSnapshotOnMiddleEntryInAppendEntries: initializing from snapshot taken at 2025-09-02T21:13:32.087953569Z 09:13:32,249 PM [test-pekko.actor.default-dispatcher-4] [INFO] MockRaftActor - testCaptureSnapshotOnMiddleEntryInAppendEntries: support() called 09:13:32,250 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] AbstractReplicatedLog - testCaptureSnapshotOnMiddleEntryInAppendEntries: Moving last applied index from -1 to 2 09:13:32,250 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] JournalRecovery - testCaptureSnapshotOnMiddleEntryInAppendEntries: applying entries up to 3 09:13:32,250 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] AbstractReplicatedLog - testCaptureSnapshotOnMiddleEntryInAppendEntries: Moving last applied index from 2 to 2 09:13:32,250 PM [test-pekko.actor.default-dispatcher-4] [INFO] Recovery - testCaptureSnapshotOnMiddleEntryInAppendEntries: Recovery completed in in 1.798 ms: last log index = 2, last log term = 1, napshot index = 2, snapshot term = 1, journal size = 0 09:13:32,250 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftActor - testCaptureSnapshotOnMiddleEntryInAppendEntries: Recovery completed and cannot restore from snapshot 09:13:32,250 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior544#774338158] 09:13:32,263 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower545#1030307872] 09:13:32,263 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader546#519430163] 09:13:32,265 PM [main] [INFO] TestActorFactory - Killing actor TestActor[pekko://test/user/testCaptureSnapshotOnMiddleEntryInAppendEntries] 09:13:32,265 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] EnabledRaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: terminating thread VirtualThread[#642,testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-159]/waiting 09:13:32,265 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-159] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: received 1 commands after 17.13 ms 09:13:32,265 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-159] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: completed 1 commands in 11.61 μs 09:13:32,265 PM [testCaptureSnapshotOnMiddleEntryInAppendEntries-writer-159] [DEBUG] JournalWriteTask - testCaptureSnapshotOnMiddleEntryInAppendEntries: journal writer stopped 09:13:32,265 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] EntryJournalV1 - testCaptureSnapshotOnMiddleEntryInAppendEntries: journal closed 09:13:32,265 PM [test-pekko.actor.default-dispatcher-4] [INFO] EnabledRaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: journal closed 09:13:32,265 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: stopped executor with 0 remaining tasks 09:13:32,265 PM [test-pekko.actor.default-dispatcher-4] [DEBUG] RaftStorage - testCaptureSnapshotOnMiddleEntryInAppendEntries: stopped executor with 0 remaining tasks 09:13:32,269 PM [main] [INFO] FollowerTest - Starting testHandleElectionTimeoutWhenLeaderMessageReceived 09:13:32,270 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:32,570 PM [main] [DEBUG] SyncStatusTracker - follower: Last sync leader does not match current leader leader, need to catch up to -1 09:13:32,700 PM [main] [DEBUG] DefaultConfigParamsImpl - No custom RaftPolicy specified. Using DefaultRaftPolicy 09:13:32,700 PM [main] [DEBUG] Follower - follower (Follower): Received ElectionTimeout but lastLeaderMessageInterval 130 < election timeout PT0.4S 09:13:32,951 PM [main] [DEBUG] SyncStatusTracker - follower: Lagging -2 entries behind leader leader and reached 1 (of expected -1) 09:13:33,151 PM [main] [DEBUG] Follower - follower (Follower): Received ElectionTimeout but lastLeaderMessageInterval 200 < election timeout PT0.4S 09:13:33,151 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior547#-1202241947] 09:13:33,162 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower548#-1963713712] 09:13:33,163 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader549#1144717255] 09:13:33,167 PM [main] [DEBUG] AbstractReplicatedLog - : Moving last applied index from -1 to 1 09:13:33,167 PM [main] [DEBUG] DefaultConfigParamsImpl - No custom RaftPolicy specified. Using DefaultRaftPolicy 09:13:33,167 PM [main] [DEBUG] Follower - follower (Follower): Received TimeoutNow - switching to Candidate 09:13:33,168 PM [main] [DEBUG] Candidate - follower (Candidate): Election: Candidate has following voting peers: [] 09:13:33,168 PM [main] [INFO] Candidate - follower (Candidate): Starting new election term 2 09:13:33,168 PM [main] [INFO] RaftActorBehavior - follower (Follower) :- Switching from behavior Follower to Candidate, election term: 2 09:13:33,168 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/behavior550#-1956526436] 09:13:33,179 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/follower551#-42525884] 09:13:33,179 PM [main] [INFO] TestActorFactory - Killing actor Actor[pekko://test/user/leader552#-56068346] [INFO] [09/02/2025 21:13:33.181] [main] [CoordinatedShutdown(pekko://test)] Running CoordinatedShutdown with reason [ActorSystemTerminateReason] 09:13:33,181 PM [test-pekko.actor.default-dispatcher-4] [INFO] CoordinatedShutdown - Running CoordinatedShutdown with reason [ActorSystemTerminateReason] [WARN] [09/02/2025 21:13:33.182] [test-pekko.actor.default-dispatcher-4] [pekko://test/system/cluster/core/daemon] unhandled message from Actor[pekko://test/deadLetters]: Leave(pekko://test@10.30.170.48:17355) [INFO] [pekkoDeadLetter][09/02/2025 21:13:33.182] [test-pekko.actor.default-dispatcher-4] [pekko://test/system/cluster/core/daemon] Message [org.apache.pekko.cluster.ClusterUserAction$Leave] to Actor[pekko://test/system/cluster/core/daemon#1790833087] was unhandled. [8] dead letters encountered. This logging can be turned off or adjusted with configuration settings 'pekko.log-dead-letters' and 'pekko.log-dead-letters-during-shutdown'. 09:13:33,182 PM [test-pekko.actor.default-dispatcher-4] [INFO] LocalActorRef - pekkoDeadLetter Message [org.apache.pekko.cluster.ClusterUserAction$Leave] to Actor[pekko://test/system/cluster/core/daemon#1790833087] was unhandled. [8] dead letters encountered. This logging can be turned off or adjusted with configuration settings 'pekko.log-dead-letters' and 'pekko.log-dead-letters-during-shutdown'. [INFO] [09/02/2025 21:13:33.183] [test-pekko.actor.internal-dispatcher-7] [Cluster(pekko://test)] Cluster Node [pekko://test@10.30.170.48:17355] - Exiting completed [INFO] [09/02/2025 21:13:33.183] [test-pekko.actor.internal-dispatcher-7] [Cluster(pekko://test)] Cluster Node [pekko://test@10.30.170.48:17355] - Shutting down... [INFO] [09/02/2025 21:13:33.183] [test-pekko.actor.internal-dispatcher-7] [Cluster(pekko://test)] Cluster Node [pekko://test@10.30.170.48:17355] - Successfully shut down 09:13:33,184 PM [test-pekko.actor.default-dispatcher-12] [INFO] Cluster - Cluster Node [pekko://test@10.30.170.48:17355] - Exiting completed 09:13:33,184 PM [test-pekko.actor.default-dispatcher-12] [INFO] Cluster - Cluster Node [pekko://test@10.30.170.48:17355] - Shutting down... 09:13:33,184 PM [test-pekko.actor.default-dispatcher-12] [INFO] Cluster - Cluster Node [pekko://test@10.30.170.48:17355] - Successfully shut down [INFO] [09/02/2025 21:13:33.186] [test-pekko.remote.default-remote-dispatcher-8] [pekko://test@10.30.170.48:17355/system/remoting-terminator] Shutting down remote daemon. 09:13:33,186 PM [test-pekko.actor.default-dispatcher-4] [INFO] RemoteActorRefProvider$RemotingTerminator - Shutting down remote daemon. [INFO] [09/02/2025 21:13:33.186] [test-pekko.remote.default-remote-dispatcher-8] [pekko://test@10.30.170.48:17355/system/remoting-terminator] Remote daemon shut down; proceeding with flushing remote transports. 09:13:33,186 PM [test-pekko.actor.default-dispatcher-12] [INFO] RemoteActorRefProvider$RemotingTerminator - Remote daemon shut down; proceeding with flushing remote transports. [INFO] [09/02/2025 21:13:33.188] [test-pekko.remote.default-remote-dispatcher-6] [pekko://test@10.30.170.48:17355/system/remoting-terminator] Remoting shut down. 09:13:33,188 PM [test-pekko.actor.default-dispatcher-4] [INFO] RemoteActorRefProvider$RemotingTerminator - Remoting shut down. [DEBUG] [09/02/2025 21:13:33.188] [test-pekko.actor.internal-dispatcher-7] [EventStream] shutting down: StandardOutLogger