This is an automated email from the ASF dual-hosted git repository.
davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/main by this push:
new 8d7f37695a8 CAMEL-22021: camel-google-pubsub: when stopping then
super.doStop should be last
8d7f37695a8 is described below
commit 8d7f37695a8f5fd77e4081330ac638330b349e36
Author: Claus Ibsen <[email protected]>
AuthorDate: Sun May 4 10:32:51 2025 +0200
CAMEL-22021: camel-google-pubsub: when stopping then super.doStop should be
last
---
.../apache/camel/component/google/pubsub/GooglePubsubConsumer.java | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git
a/components/camel-google/camel-google-pubsub/src/main/java/org/apache/camel/component/google/pubsub/GooglePubsubConsumer.java
b/components/camel-google/camel-google-pubsub/src/main/java/org/apache/camel/component/google/pubsub/GooglePubsubConsumer.java
index 92840d53907..235bd536cc5 100644
---
a/components/camel-google/camel-google-pubsub/src/main/java/org/apache/camel/component/google/pubsub/GooglePubsubConsumer.java
+++
b/components/camel-google/camel-google-pubsub/src/main/java/org/apache/camel/component/google/pubsub/GooglePubsubConsumer.java
@@ -76,6 +76,7 @@ public class GooglePubsubConsumer extends DefaultConsumer {
@Override
protected void doStart() throws Exception {
super.doStart();
+
localLog.info("Starting Google PubSub consumer for {}/{}",
endpoint.getProjectId(), endpoint.getDestinationName());
executor = endpoint.createExecutor();
for (int i = 0; i < endpoint.getConcurrentConsumers(); i++) {
@@ -85,7 +86,6 @@ public class GooglePubsubConsumer extends DefaultConsumer {
@Override
protected void doStop() throws Exception {
- super.doStop();
localLog.info("Stopping Google PubSub consumer for {}/{}",
endpoint.getProjectId(), endpoint.getDestinationName());
synchronized (subscribers) {
@@ -105,6 +105,8 @@ public class GooglePubsubConsumer extends DefaultConsumer {
}
}
executor = null;
+
+ super.doStop();
}
private void safeCancelSynchronousPullResponses() {