[
https://issues.apache.org/jira/browse/CURATOR-540?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16931884#comment-16931884
]
Jordan Zimmerman commented on CURATOR-540:
------------------------------------------
In my view that's not a race. CONNECTED/RECONNECTED are essentially the same.
They mean that the connection was not completed and now is. PathChildrenCache
must reset the cache in this case. So, yes additional events will be sent. The
unspoken desire is to get PathChildrenCache into some initial state before
using. In a dynamic system this isn't really possible. I took a look at
TreeCache. It handles CONNECTED/RECONNECTED slightly differently - however
there's no way to prep a TreeCache without getting all the events.
> BUILD_INITIAL_CACHE mode will post history child on start
> ---------------------------------------------------------
>
> Key: CURATOR-540
> URL: https://issues.apache.org/jira/browse/CURATOR-540
> Project: Apache Curator
> Issue Type: Bug
> Components: Recipes
> Affects Versions: 2.12.0, 2.13.0
> Reporter: HonglunChen
> Priority: Major
> Attachments: image-2019-09-16-12-43-01-588.png
>
>
> I debugged and found the root cause : In PathChildrenCache, CONNECTED state
> is triggered before currentData initializes.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)