You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ignite.apache.org by "alievmirza (via GitHub)" <gi...@apache.org> on 2023/05/17 12:51:07 UTC

[GitHub] [ignite-3] alievmirza commented on a diff in pull request #1958: IGNITE-18955 Add the ability to use filters when data nodes are calculated

alievmirza commented on code in PR #1958:
URL: https://github.com/apache/ignite-3/pull/1958#discussion_r1196466543


##########
modules/distribution-zones/src/main/java/org/apache/ignite/internal/distributionzones/DistributionZoneManager.java:
##########
@@ -1355,7 +1373,16 @@ public CompletableFuture<Void> onUpdate(WatchEvent evt) {
 
                     assert newDataNodes != null : "Data nodes was not initialized.";
 
-                    zoneState.nodes(newDataNodes);
+                    String filter;
+
+                    try {
+                        filter = getZoneById(zonesConfiguration, zoneId).filter().value();
+                    } catch (DistributionZoneNotFoundException ignored) {

Review Comment:
   `DistributionZonesUtil#getZoneById` throws  `DistributionZoneNotFoundException` if there is no such zone with `zoneId` in `zonesConfiguration`.
   We could receive event about dataNodes changes for `zoneId`, and while we was handling this watch event, zone could be deleted



-- 
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@ignite.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org