ignite-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [ignite] anton-vinogradov commented on a change in pull request #6942: IGNITE-9913
Date Thu, 10 Oct 2019 08:54:47 GMT
anton-vinogradov commented on a change in pull request #6942: IGNITE-9913
URL: https://github.com/apache/ignite/pull/6942#discussion_r333402311
 
 

 ##########
 File path: modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheAffinitySharedManager.java
 ##########
 @@ -1982,7 +1982,37 @@ public boolean onCentralizedAffinityChange(final GridDhtPartitionsExchangeFuture
         });
 
         synchronized (mux) {
-            this.waitInfo = null;
+            waitInfo = null;
+        }
+
+        return true;
+    }
+
+    /**
+     * Called on exchange initiated by baseline server node leave.
+     *
+     * @param fut Exchange future.
+     * @param crd Coordinator flag.
+     * @return {@code True} if affinity should be assigned by coordinator.
+     */
+    public boolean onBaselineNodeLeft(final GridDhtPartitionsExchangeFuture fut, boolean
crd) {
+        assert (fut.events().hasServerLeft() && !fut.firstEvent().eventNode().isClient())
: fut.firstEvent();
+
+        forAllRegisteredCacheGroups(new IgniteInClosureX<CacheGroupDescriptor>() {
+            @Override public void applyx(CacheGroupDescriptor desc) throws IgniteCheckedException
{
+                CacheGroupHolder cache = getOrCreateGroupHolder(fut.initialVersion(), desc);
+
+                cache.aff.reinitializeWithoutOfflineNodes(fut.initialVersion());
 
 Review comment:
   Since I'm using assignment (not idealAssignment), which took moving into account (correct?)
this should be еру correct initialization?

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message