You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@geode.apache.org by GitBox <gi...@apache.org> on 2021/12/15 19:25:42 UTC
[GitHub] [geode] gesterzhou commented on a change in pull request #7199: GEODE-9770: Retry creating region when cache is closed
gesterzhou commented on a change in pull request #7199:
URL: https://github.com/apache/geode/pull/7199#discussion_r769952943
##########
File path: geode-core/src/distributedTest/java/org/apache/geode/internal/cache/persistence/PersistentRecoveryOrderDUnitTest.java
##########
@@ -1326,6 +1326,10 @@ public void testRecoverAfterConflict() {
vm1.invoke(() -> getCache().close());
vm0.invoke(() -> {
+ await().untilAsserted(
+ () -> assertThat(
+ InternalDistributedSystem.getAnyInstance().getCancelCriterion().cancelInProgress())
Review comment:
I think the purpose of the fix is to introduce some wait until vm0 completely closed the cache. Using cancelInProgress() is not easy to understand.
I suggest to use:
await().untilAsserted(()->assertThat(cache == null || cache.isClosed()));
--
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: notifications-unsubscribe@geode.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org