You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@gobblin.apache.org by GitBox <gi...@apache.org> on 2021/06/15 21:55:08 UTC

[GitHub] [gobblin] jack-moseley commented on a change in pull request #3312: [GOBBLIN-1473] Fix ConcurrentModificationException when handling leadership change

jack-moseley commented on a change in pull request #3312:
URL: https://github.com/apache/gobblin/pull/3312#discussion_r652180811



##########
File path: gobblin-service/src/main/java/org/apache/gobblin/service/modules/scheduler/GobblinServiceJobScheduler.java
##########
@@ -165,8 +165,9 @@ public void run() {
     } else {
       // Since we are going to change status to isActive=false, unschedule all flows
       for (Spec spec : this.scheduledFlowSpecs.values()) {
-        onDeleteSpec(spec.getUri(), spec.getVersion());
+        onDeleteSpec(spec.getUri(), spec.getVersion(), new Properties(), false);

Review comment:
       Yeah that's true, that is much simpler. I was thinking that it may be expensive to clone all the specs, but we actually only need to clone the list, and it is okay if they are referencing the same Spec objects since we are not modifying those.




-- 
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