Skip to content

Commit 5dfd10c

Browse files
authored
fix(consumer): update_topics should only log if topics are recreated (#390)
1 parent 771b6ef commit 5dfd10c

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

src/consumer/multi.rs

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,14 @@ impl<T: DeserializeMessage, Exe: Executor> MultiTopicConsumer<T, Exe> {
194194
}),
195195
)
196196
.await?;
197-
info!("created {} consumers", consumers.len());
197+
if !consumers.is_empty() {
198+
let topics: Vec<String> = consumers.iter().map(|c| c.topic()).collect();
199+
info!(
200+
"recreated {} consumers for topics: {:?}",
201+
consumers.len(),
202+
topics
203+
);
204+
}
198205
Ok(consumers)
199206
}));
200207
}

0 commit comments

Comments
 (0)