Skip to content

Commit 8b6b127

Browse files
committed
GH-3024: Add logging for exceptions in KafkaTopicProvisioner
Related to #3024
1 parent 12468dc commit 8b6b127

File tree

1 file changed

+2
-1
lines changed
  • binders/kafka-binder/spring-cloud-stream-binder-kafka-core/src/main/java/org/springframework/cloud/stream/binder/kafka/provisioning

1 file changed

+2
-1
lines changed

binders/kafka-binder/spring-cloud-stream-binder-kafka-core/src/main/java/org/springframework/cloud/stream/binder/kafka/provisioning/KafkaTopicProvisioner.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2014-2023 the original author or authors.
2+
* Copyright 2014-2024 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -668,6 +668,7 @@ public Collection<PartitionInfo> getPartitionsForTopic(final int partitionCount,
668668
partitions = callable.call();
669669
}
670670
catch (Exception ex) {
671+
logger.warn("Error occurred while calculating partitions for topic: " + topicName, ex);
671672
// The above call can potentially throw exceptions such as timeout. If
672673
// we can determine
673674
// that the exception was due to an unknown topic on the broker, just

0 commit comments

Comments
 (0)