Skip to content

Commit

Permalink
kafka/server: run activate_feature in background
Browse files Browse the repository at this point in the history
Ufter upgrading node in cluster to 22.1.x version from 22.11.x
upgraded node isn't controller leade, it enters group_metadata_migration::start
and hits the "kafka_internal/group topic does not exists, activating" path
this call waits for activate_feature,activate_feature loops until the feature is active,
but it cannot be activated because only the controller leader runs the feature_manager
logic for activating features, and the controller leader is a 21.11.x node
that doesn't have the code. The node remains in 'booting' state indefinitely

Fixes: redpanda-data#4469
  • Loading branch information
VadimPlh committed Apr 29, 2022
1 parent 34b8e39 commit 62e4356
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions src/v/kafka/server/group_metadata_migration.cc
Original file line number Diff line number Diff line change
Expand Up @@ -687,11 +687,10 @@ ss::future<> group_metadata_migration::start(ss::abort_source& as) {
mlog.info,
"kafka_internal/group topic does not exists, activating "
"consumer_offsets feature");
try {
co_await activate_feature(as);
} catch (const ss::abort_requested_exception&) {
// ignore abort requested exception, we are shutting down
}

ssx::spawn_with_gate(_background_gate, [this, &as]() -> ss::future<> {
return activate_feature(as);
});
co_return;
}
// otherwise wait for feature to be preparing and execute migration
Expand Down

0 comments on commit 62e4356

Please sign in to comment.