This is an automated email from the ASF dual-hosted git repository.
mmerli pushed a commit to branch branch-2.9
in repository https://gitbox.apache.org/repos/asf/pulsar.git
The following commit(s) were added to refs/heads/branch-2.9 by this push:
new 105885c [ServerCnx] Improve error logging for topic not found
(#13950) (#14891)
105885c is described below
commit 105885c9cde045e2fc74b90eeab8f99aa1ae4a7a
Author: gaozhangmin <[email protected]>
AuthorDate: Wed Mar 30 12:27:48 2022 +0800
[ServerCnx] Improve error logging for topic not found (#13950) (#14891)
* [ServerCnx] Improve error logging for topic not found
* Log topic not found at INFO level
(cherry picked from commit 54c898f18bf8c53d64c7f87049bb63764137acb0)
Co-authored-by: Michael Marshall <[email protected]>
---
.../src/main/java/org/apache/pulsar/broker/service/ServerCnx.java | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git
a/pulsar-broker/src/main/java/org/apache/pulsar/broker/service/ServerCnx.java
b/pulsar-broker/src/main/java/org/apache/pulsar/broker/service/ServerCnx.java
index c18d525..89541a4 100644
---
a/pulsar-broker/src/main/java/org/apache/pulsar/broker/service/ServerCnx.java
+++
b/pulsar-broker/src/main/java/org/apache/pulsar/broker/service/ServerCnx.java
@@ -1266,8 +1266,9 @@ public class ServerCnx extends PulsarHandler implements
TransportCnx {
Throwable cause = exception.getCause();
if (cause instanceof NoSuchElementException) {
cause = new TopicNotFoundException("Topic Not
Found.");
- }
- if (!Exceptions.areExceptionsPresentInChain(cause,
+ log.info("[{}] Failed to load topic {},
producerId={}: Topic not found",
+ remoteAddress, topicName, producerId);
+ } else if
(!Exceptions.areExceptionsPresentInChain(cause,
ServiceUnitNotReadyException.class,
ManagedLedgerException.class)) {
// Do not print stack traces for expected
exceptions
log.error("[{}] Failed to create topic {},
producerId={}",