Mmuzaf commented on code in PR #10140:
URL: https://github.com/apache/ignite/pull/10140#discussion_r923249506


##########
modules/core/src/main/java/org/apache/ignite/internal/processors/platform/client/cache/ClientCachePartitionsRequest.java:
##########
@@ -77,97 +78,68 @@ public ClientCachePartitionsRequest(BinaryRawReader reader) 
{
             if (cacheDesc == null)
                 continue;
 
-            ClientCachePartitionAwarenessGroup grp = processCache(ctx, groups, 
cacheGroupIds, affinityVer, cacheDesc);
+            ClientCachePartitionAwarenessGroup grp = processCache(ctx, 
affinityVer, cacheDesc);
 
-            // Cache already processed.
             if (grp == null)
                 continue;
 
-            groups.add(grp);
-            cacheGroupIds.put(cacheDesc.groupId(), grp);
+            ClientCachePartitionAwarenessGroup grp0 = grps.putIfAbsent(grp, 
grp);
+
+            if (grp0 != null)
+                grp0.addAll(Collections.singletonList(cacheDesc));
         }
 
-        Map<String, DynamicCacheDescriptor> allCaches = 
ctx.kernalContext().cache().cacheDescriptors();
+        Map<Integer, List<DynamicCacheDescriptor>> allCaches = 
ctx.kernalContext().cache().cacheDescriptors().values()

Review Comment:
   Discussed privately. Fixed some crutial points.



##########
modules/core/src/main/java/org/apache/ignite/internal/processors/platform/client/cache/ClientCachePartitionsRequest.java:
##########
@@ -77,97 +78,68 @@ public ClientCachePartitionsRequest(BinaryRawReader reader) 
{
             if (cacheDesc == null)
                 continue;
 
-            ClientCachePartitionAwarenessGroup grp = processCache(ctx, groups, 
cacheGroupIds, affinityVer, cacheDesc);
+            ClientCachePartitionAwarenessGroup grp = processCache(ctx, 
affinityVer, cacheDesc);
 
-            // Cache already processed.
             if (grp == null)
                 continue;
 
-            groups.add(grp);
-            cacheGroupIds.put(cacheDesc.groupId(), grp);

Review Comment:
   Discussed privately. Fixed some crutial points.



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to