Skip to content

Commit

Permalink
r/stm_manager: do not warn when some of the stms did not make progress
Browse files Browse the repository at this point in the history
When a partition is created without the batch cache, the write may not
be immediately visible for the reader. In this case the
`raft::state_machine_manager` identifies it as an issue with the state
machine not being able to make progress. Added a differentiation of the
log level based on the cache configuration of the partition. For the
partitions that uses the cache the `WARN` log level is kept to make it
easy to recognize possibly stuck state machines.

Signed-off-by: Michał Maślanka <michal@redpanda.com>
(cherry picked from commit 53e9fb4)
  • Loading branch information
mmaslankaprv authored and vbotbuildovich committed Aug 7, 2024
1 parent 4744352 commit 17e2150
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/v/raft/state_machine_manager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -371,8 +371,10 @@ ss::future<> state_machine_manager::try_apply_in_foreground() {
model::no_timeout);

if (max_last_applied == model::offset{}) {
vlog(
_log.warn,
vlogl(
_log,
_raft->log_config().cache_enabled() ? ss::log_level::warn
: ss::log_level::debug,
"no progress has been made during state machine apply. Current "
"next offset: {}",
_next);
Expand Down

0 comments on commit 17e2150

Please sign in to comment.