Skip to content

Commit

Permalink
Bug 37512822 - [37512368->25.03] Topics: Subscribers are not properly…
Browse files Browse the repository at this point in the history
… unsubscribed when the service senior dies

(merge main -> ce/main 113728)

[git-p4: depot-paths = "//dev/coherence-ce/main/": change = 113731]
  • Loading branch information
thegridman committed Jan 23, 2025
1 parent 5b396e4 commit 5e193f3
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -266,8 +266,10 @@ public void closeSubscription(ConnectedSubscriber<V> subscriber, boolean fDestro
// We need to ensure that the subscription has really gone.
// During a fail-over situation the subscriber may still exist in the configmap
// so we need to repeat the closure notification
TopicSubscription subscription = getSubscription(subscriber, m_subscriptionId);
while (subscription != null && subscription.getSubscriberTimestamp(f_subscriberId) != Long.MAX_VALUE)
String sTopic = f_caches.getTopicName();
PagedTopicService service = f_caches.getService();
Set<SubscriberId> setSubscriber = service.getSubscribers(sTopic, f_subscriberGroupId);
while (setSubscriber.contains(f_subscriberId))
{
try
{
Expand All @@ -279,7 +281,7 @@ public void closeSubscription(ConnectedSubscriber<V> subscriber, boolean fDestro
}
Logger.fine("Repeating subscriber closed notification for topic subscriber: " + subscriber);
PagedTopicSubscription.notifyClosed(f_caches.Subscriptions, f_subscriberGroupId, m_subscriptionId, f_subscriberId);
subscription = getSubscription(subscriber, m_subscriptionId);
setSubscriber = service.getSubscribers(sTopic, f_subscriberGroupId);
}
}

Expand Down

0 comments on commit 5e193f3

Please sign in to comment.