You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2023/01/06 07:47:49 UTC
[GitHub] [pulsar] BewareMyPower commented on a diff in pull request #19147: [fix][broker] catch exception for brokerInterceptor
BewareMyPower commented on code in PR #19147:
URL: https://github.com/apache/pulsar/pull/19147#discussion_r1063211689
##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/service/ServerCnx.java:
##########
@@ -1157,7 +1157,11 @@ protected void handleSubscribe(final CommandSubscribe subscribe) {
remoteAddress, topicName, subscriptionName);
commandSender.sendSuccessResponse(requestId);
if (brokerInterceptor != null) {
- brokerInterceptor.consumerCreated(this, consumer, metadata);
+ try {
+ brokerInterceptor.consumerCreated(this, consumer, metadata);
Review Comment:
The exception thrown by an interceptor does not mean an error from broker, it's an error from 3rd party extensions. A similar case is that you can see `ConsumerInterceptors` , which catches all `Throwable`s from the user-configured interceptor.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org