Github user dragonsinth commented on a diff in the pull request:

    https://github.com/apache/lucene-solr/pull/32#discussion_r62770082
  
    --- Diff: 
solr/solrj/src/java/org/apache/solr/common/cloud/ZkStateReader.java ---
    @@ -485,6 +506,20 @@ private void refreshLegacyClusterState(Watcher watcher)
               // Nothing to do, someone else updated same or newer.
               return;
             }
    +        Set<String> liveNodes = this.liveNodes; // volatile read
    +        for (Map.Entry<String, CollectionWatch> watchEntry : 
this.collectionWatches.entrySet()) {
    +          String coll = watchEntry.getKey();
    +          CollectionWatch collWatch = watchEntry.getValue();
    +          ClusterState.CollectionRef ref = 
this.legacyCollectionStates.get(coll);
    +          if (ref == null)
    +            continue;
    --- End diff --
    
    Q: what happens if you try to set a watcher on a collection that doesn't 
exist yet?  Mostly curious.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to