File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -2146,6 +2146,10 @@ impl<T: Storage> Raft<T> {
21462146 if !self . commit_to_current_term ( ) {
21472147 // Reject read only request when this leader has not committed any log entry
21482148 // in its term.
2149+ info ! (
2150+ self . logger,
2151+ "leader has not yet committed in its term; dropping read index msg" ,
2152+ ) ;
21492153 return Ok ( ( ) ) ;
21502154 }
21512155
@@ -2331,6 +2335,11 @@ impl<T: Storage> Raft<T> {
23312335 from = m. from;
23322336 "state" => ?self . state,
23332337 ) ,
2338+ MessageType :: MsgReadIndex => info ! (
2339+ self . logger,
2340+ "no leader at term {term}; dropping read index msg" ,
2341+ term = self . term;
2342+ ) ,
23342343 _ => { }
23352344 }
23362345 Ok ( ( ) )
@@ -2411,7 +2420,7 @@ impl<T: Storage> Raft<T> {
24112420 if self . leader_id == INVALID_ID {
24122421 info ! (
24132422 self . logger,
2414- "no leader at term {term}; dropping index reading msg" ,
2423+ "no leader at term {term}; dropping read index msg" ,
24152424 term = self . term;
24162425 ) ;
24172426 return Ok ( ( ) ) ;
You can’t perform that action at this time.
0 commit comments