zookeeper-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "maoling (JIRA)" <j...@apache.org>
Subject [jira] [Created] (ZOOKEEPER-3281) Add a new CLI:watch
Date Mon, 18 Feb 2019 01:52:00 GMT
maoling created ZOOKEEPER-3281:
----------------------------------

             Summary: Add a new CLI:watch
                 Key: ZOOKEEPER-3281
                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-3281
             Project: ZooKeeper
          Issue Type: New Feature
            Reporter: maoling
            Assignee: maoling


Terminal1:t1;
Terminal2:t2;

PART1:
--------------[-d] test for data change------------------------
[t1]:
 watch -d /testwatch
[t2]:
 set /testwatch mydata
[t1]: result:
 WatchedEvent state:SyncConnected
 type:NodeDataChanged
 path:/testwatch
 new data:mydata
----------------------------------------------------------------
[t1]:
 watch -d /testwatch
[t2]:
 delete /testwatch
[t1] result:
 WatchedEvent state:SyncConnected
 type:NodeDeleted
 path:/testwatch

PART2:
--------------[-c] test for child change------------------------
[t1]:
 watch -c /testwatch
[t2]
 create /testwatch/child_1 mydata
[t1] reslut:
 WatchedEvent state:SyncConnected
 type:NodeChildrenChanged
 path:/testwatch
 new child list:[child_1]
----------------------------------------------------------------
[t1]:
 watch -c /testwatch
[t2]:
 delete /testwatch/child_1
[t1]:
 WatchedEvent state:SyncConnected
 type:NodeChildrenChanged
 path:/testwatch
 new child list:[]

PART3:
----------------[-e]test for exist watch----------------------
[t2]:
 delete /testwatch
[t1]:
 watch -e /testwatch
[t2]:
 create /testwatch mydata
[t1] result:
 WatchedEvent state:SyncConnected
 type:NodeCreated
 path:/testwatch
----------------------------------------------------------------
[t1]:
 watch -e /testwatch
[t2]:
 delete /testwatch
 WatchedEvent state:SyncConnected
 type:NodeDeleted
 path:/testwatch
----------------------------------------------------------------
[t1]:
 watch -e /testwatch
[t2]:
 set /testwatch mydata666666666
[t1]:
 WatchedEvent state:SyncConnected
 type:NodeDataChanged
 path:/testwatch



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

Mime
View raw message