[
https://issues.apache.org/jira/browse/GEODE-7591?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17093726#comment-17093726
]
Bill Burcham commented on GEODE-7591:
-------------------------------------
[~jvarenina] how is it going with this bug?
> potential hang
> --------------
>
> Key: GEODE-7591
> URL: https://issues.apache.org/jira/browse/GEODE-7591
> Project: Geode
> Issue Type: Improvement
> Components: membership
> Reporter: Bruce J Schuchardt
> Assignee: Jakov Varenina
> Priority: Major
>
> This method in ClusterDistributionManager waits for a new membership view to
> be installed, but if the cache is being closed while waiting the method could
> hang because it only checks for cache closure if the object it's waiting on
> is notified. We should change the wait() to have a timeout so that the
> `stopper` is polled periodically
> {code:java}
> void waitForViewInstallation(long id) throws InterruptedException {
> if (id <= membershipViewIdAcknowledged) {
> return;
> }
> synchronized (membershipViewIdGuard) {
> while (membershipViewIdAcknowledged < id &&
> !stopper.isCancelInProgress()) {
> if (logger.isDebugEnabled()) {
> logger.debug("waiting for view {}. Current DM view processed by all
> listeners is {}", id,
> membershipViewIdAcknowledged);
> }
> membershipViewIdGuard.wait();
> }
> }
> }
> {code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)