go-zookeeper / zk

Native ZooKeeper client for Go
BSD 3-Clause "New" or "Revised" License
512 stars 130 forks source link

zk event state not support SyncConnected #98

Closed KaithyRookie closed 6 months ago

KaithyRookie commented 1 year ago

zk event state not support SyncConnected, so it use Unknown replaced, but I don't think it's appropriate because the official documentation has clearly defined this state

this is the log printed by zk

{"message":"NodeWatch::watchFlow receive zk events","state":"Unknown","type":"EventNodeChildrenChanged","path":"/colla/cpf/configs/flow"}

this is the watcher response from zkCli

[zk: localhost:2181(CONNECTED) 31] ls -w /colla/cpf/configs/flow
ls -w /colla/cpf/configs/flow
[zk: localhost:2181(CONNECTED) 32] 
WATCHER::

WatchedEvent state:SyncConnected type:NodeChildrenChanged path:/colla/cpf/configs/flow