[ 
https://issues.apache.org/jira/browse/SOLR-13239?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16764475#comment-16764475
 ] 

Erick Erickson commented on SOLR-13239:
---------------------------------------

I wonder if some of the test failures are related?

> CollectionStateWatcher reports new collections before they really exist
> -----------------------------------------------------------------------
>
>                 Key: SOLR-13239
>                 URL: https://issues.apache.org/jira/browse/SOLR-13239
>             Project: Solr
>          Issue Type: Bug
>      Security Level: Public(Default Security Level. Issues are Public) 
>          Components: clients - java
>    Affects Versions: 7.6
>            Reporter: Hendrik Haddorp
>            Priority: Major
>
> A CollectionStateWatcher registered via 
> org.apache.solr.common.cloud.ZkStateReader.registerCloudCollectionsListener 
> gets invoked as soon as the CloudSolrClient detects a new collection. This is 
> based on having a watch on the /collections znode. When the 
> CollectionStateWatcher tries to read out information about the new collection 
> via zkStateReader.getClusterState() there is a good chance that no 
> DocCollection can be found. The reason for that is that a DocCollection is 
> based on the state.json below the collection. As this znode is below the 
> collection znode it does need to be created a bit later. So there is a race 
> condition.
> One can run into the same problem if one tries to register a 
> CollectionStateWatcher via ZkStateReader.registerCollectionStateWatcher 
> straight after a new collection is found. The watcher is then being invoked 
> with the DocCollection set to null as it also can not find the DocCollection 
> object. Null does however indicate that the collection was being deleted.
> see also the mail thread about this:
> https://www.mail-archive.com/[email protected]&q=subject:%22Re%5C%3A+CloudSolrClient+getDocCollection%22&o=newest&f=1



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

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

Reply via email to