You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by mm...@apache.org on 2022/03/30 03:27:41 UTC
[pulsar] branch branch-2.7 updated: [ServerCnx] Improve error logging for topic not found (#13950) (#14893)
This is an automated email from the ASF dual-hosted git repository.
mmarshall pushed a commit to branch branch-2.7
in repository https://gitbox.apache.org/repos/asf/pulsar.git
The following commit(s) were added to refs/heads/branch-2.7 by this push:
new d1aa759 [ServerCnx] Improve error logging for topic not found (#13950) (#14893)
d1aa759 is described below
commit d1aa759ede4a4d0373be1a5d0d5c1df93bdeac0e
Author: gaozhangmin <ga...@gmail.com>
AuthorDate: Wed Mar 30 11:25:55 2022 +0800
[ServerCnx] Improve error logging for topic not found (#13950) (#14893)
* [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 <mm...@apache.org>
Fixes #14877
### Motivation
Fixes #14877
### Modifications
cherry pick from #13950
### Documentation
Check the box below or label this PR directly (if you have committer privilege).
Need to update docs?
- [ ] `doc-required`
(If you need help on updating docs, create a doc issue)
- [x] `no-need-doc`
(Please explain why)
- [ ] `doc`
(If this PR contains doc changes)
---
.../src/main/java/org/apache/pulsar/broker/service/ServerCnx.java | 6 +++---
1 file changed, 3 insertions(+), 3 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 3ba6fbd..792cc91 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
@@ -1173,9 +1173,9 @@ public class ServerCnx extends PulsarHandler implements TransportCnx {
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={}",