Skip to content

Commit

Permalink
k/group_manager: capture group in first stage finally
Browse files Browse the repository at this point in the history
Extend group lifecycle in both the first and second stage of join and
sync request processing.

Signed-off-by: Michal Maslanka <michal@vectorized.io>
  • Loading branch information
mmaslankaprv committed May 17, 2022
1 parent 1b47f7e commit 0b987b6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/v/kafka/server/group_manager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -555,7 +555,7 @@ group::join_group_stages group_manager::join_group(join_group_request&& r) {

auto ret = group->handle_join_group(std::move(r), is_new_group);
return group::join_group_stages(
std::move(ret.dispatched), ret.result.finally([group] {}));
ret.dispatched.finally([group] {}), ret.result.finally([group] {}));
}

group::sync_group_stages group_manager::sync_group(sync_group_request&& r) {
Expand Down Expand Up @@ -586,7 +586,8 @@ group::sync_group_stages group_manager::sync_group(sync_group_request&& r) {
if (group) {
auto stages = group->handle_sync_group(std::move(r));
return group::sync_group_stages(
std::move(stages.dispatched), stages.result.finally([group] {}));
stages.dispatched.finally([group] {}),
stages.result.finally([group] {}));
} else {
vlog(
klog.trace,
Expand Down

0 comments on commit 0b987b6

Please sign in to comment.