You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zookeeper.apache.org by "Patrick Hunt (JIRA)" <ji...@apache.org> on 2008/06/11 00:45:45 UTC

[jira] Created: (ZOOKEEPER-39) Use Watcher objects rather than boolean on read operations

Use Watcher objects rather than boolean on read operations
----------------------------------------------------------

                 Key: ZOOKEEPER-39
                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-39
             Project: Zookeeper
          Issue Type: New Feature
          Components: c client, java client
            Reporter: Patrick Hunt
            Assignee: Patrick Hunt
             Fix For: 3.0.0


Moved from SourceForge to Apache.
http://sourceforge.net/tracker/index.php?func=detail&aid=1962501&group_id=209147&atid=1008547

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (ZOOKEEPER-39) Use Watcher objects rather than boolean on read operations

Posted by "Hudson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ZOOKEEPER-39?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12616844#action_12616844 ] 

Hudson commented on ZOOKEEPER-39:
---------------------------------

Integrated in ZooKeeper-trunk #33 (See [http://hudson.zones.apache.org/hudson/job/ZooKeeper-trunk/33/])

> Use Watcher objects rather than boolean on read operations
> ----------------------------------------------------------
>
>                 Key: ZOOKEEPER-39
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-39
>             Project: Zookeeper
>          Issue Type: New Feature
>          Components: c client, java client
>            Reporter: Patrick Hunt
>            Assignee: Andrew Kornev
>             Fix For: 3.0.0
>
>         Attachments: ZOOKEEPER-39.patch, ZOOKEEPER-39_license.patch
>
>
> Moved from SourceForge to Apache.
> http://sourceforge.net/tracker/index.php?func=detail&aid=1962501&group_id=209147&atid=1008547

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-39) Use Watcher objects rather than boolean on read operations

Posted by "Andrew Kornev (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-39?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrew Kornev updated ZOOKEEPER-39:
-----------------------------------

    Status: Patch Available  (was: Open)

> Use Watcher objects rather than boolean on read operations
> ----------------------------------------------------------
>
>                 Key: ZOOKEEPER-39
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-39
>             Project: Zookeeper
>          Issue Type: New Feature
>          Components: c client, java client
>            Reporter: Patrick Hunt
>            Assignee: Andrew Kornev
>             Fix For: 3.0.0
>
>         Attachments: ZOOKEEPER-39.patch
>
>
> Moved from SourceForge to Apache.
> http://sourceforge.net/tracker/index.php?func=detail&aid=1962501&group_id=209147&atid=1008547

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (ZOOKEEPER-39) Use Watcher objects rather than boolean on read operations

Posted by "Andrew Kornev (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ZOOKEEPER-39?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12614121#action_12614121 ] 

Andrew Kornev commented on ZOOKEEPER-39:
----------------------------------------

The watcher processing is now done in multiple steps: 
1) when application issues a zokeeper query with watcher enabled, a temporary watcher registration is created and stored along with the completion entry in the completion queue.
2) upon succesful response from the server, the watcher registration is moved from the completion queue to the watcher object map. If the server returns an error the watcher registration is discarded.
3) when a watch event arrives, the client uses the watcher map to determine if there are watchers set on the znode (using the znode path as the key). It then calles the watcher callback passing in the watcher context along with the znode path and the event type info.
4) the watcher object is deleted from the map prior to calling the application watcher in the step 3)

> Use Watcher objects rather than boolean on read operations
> ----------------------------------------------------------
>
>                 Key: ZOOKEEPER-39
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-39
>             Project: Zookeeper
>          Issue Type: New Feature
>          Components: c client, java client
>            Reporter: Patrick Hunt
>            Assignee: Andrew Kornev
>             Fix For: 3.0.0
>
>         Attachments: ZOOKEEPER-39.patch
>
>
> Moved from SourceForge to Apache.
> http://sourceforge.net/tracker/index.php?func=detail&aid=1962501&group_id=209147&atid=1008547

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (ZOOKEEPER-39) Use Watcher objects rather than boolean on read operations

Posted by "Andrew Kornev (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ZOOKEEPER-39?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12616599#action_12616599 ] 

Andrew Kornev commented on ZOOKEEPER-39:
----------------------------------------

No, this patch doesn't take care of ZOOKEEPER-50, which is a bug in the Java client code. This patch is for the C client only.

> Use Watcher objects rather than boolean on read operations
> ----------------------------------------------------------
>
>                 Key: ZOOKEEPER-39
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-39
>             Project: Zookeeper
>          Issue Type: New Feature
>          Components: c client, java client
>            Reporter: Patrick Hunt
>            Assignee: Andrew Kornev
>             Fix For: 3.0.0
>
>         Attachments: ZOOKEEPER-39.patch
>
>
> Moved from SourceForge to Apache.
> http://sourceforge.net/tracker/index.php?func=detail&aid=1962501&group_id=209147&atid=1008547

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (ZOOKEEPER-39) Use Watcher objects rather than boolean on read operations

Posted by "Andrew Kornev (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ZOOKEEPER-39?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12616664#action_12616664 ] 

Andrew Kornev commented on ZOOKEEPER-39:
----------------------------------------

Verified the patch builds and the unit tests run successfully.

> Use Watcher objects rather than boolean on read operations
> ----------------------------------------------------------
>
>                 Key: ZOOKEEPER-39
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-39
>             Project: Zookeeper
>          Issue Type: New Feature
>          Components: c client, java client
>            Reporter: Patrick Hunt
>            Assignee: Andrew Kornev
>             Fix For: 3.0.0
>
>         Attachments: ZOOKEEPER-39.patch, ZOOKEEPER-39_license.patch
>
>
> Moved from SourceForge to Apache.
> http://sourceforge.net/tracker/index.php?func=detail&aid=1962501&group_id=209147&atid=1008547

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (ZOOKEEPER-39) Use Watcher objects rather than boolean on read operations

Posted by "Patrick Hunt (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-39?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Patrick Hunt reassigned ZOOKEEPER-39:
-------------------------------------

    Assignee: Andrew Kornev  (was: Patrick Hunt)

The java client code is complete, the c client has yet to be implemented. Reassigning to Andrew for c client implementation.


> Use Watcher objects rather than boolean on read operations
> ----------------------------------------------------------
>
>                 Key: ZOOKEEPER-39
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-39
>             Project: Zookeeper
>          Issue Type: New Feature
>          Components: c client, java client
>            Reporter: Patrick Hunt
>            Assignee: Andrew Kornev
>             Fix For: 3.0.0
>
>
> Moved from SourceForge to Apache.
> http://sourceforge.net/tracker/index.php?func=detail&aid=1962501&group_id=209147&atid=1008547

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-39) Use Watcher objects rather than boolean on read operations

Posted by "Andrew Kornev (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-39?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrew Kornev updated ZOOKEEPER-39:
-----------------------------------

    Attachment: ZOOKEEPER-39.patch

This patch implements the new watcher "object" API. Internally, it uses a map to maintain the mapping between the znode path and watcher function/context. Every time a watch event arrives the client delegates event processing to an associated watcher object if one exists.

The patch also includes a suite of unit tests for both single- and multithreaded libraries as well as for the Sync and Async APIs.

> Use Watcher objects rather than boolean on read operations
> ----------------------------------------------------------
>
>                 Key: ZOOKEEPER-39
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-39
>             Project: Zookeeper
>          Issue Type: New Feature
>          Components: c client, java client
>            Reporter: Patrick Hunt
>            Assignee: Andrew Kornev
>             Fix For: 3.0.0
>
>         Attachments: ZOOKEEPER-39.patch
>
>
> Moved from SourceForge to Apache.
> http://sourceforge.net/tracker/index.php?func=detail&aid=1962501&group_id=209147&atid=1008547

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (ZOOKEEPER-39) Use Watcher objects rather than boolean on read operations

Posted by "Andrew Kornev (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-39?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrew Kornev closed ZOOKEEPER-39.
----------------------------------


> Use Watcher objects rather than boolean on read operations
> ----------------------------------------------------------
>
>                 Key: ZOOKEEPER-39
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-39
>             Project: Zookeeper
>          Issue Type: New Feature
>          Components: c client, java client
>            Reporter: Patrick Hunt
>            Assignee: Andrew Kornev
>             Fix For: 3.0.0
>
>         Attachments: ZOOKEEPER-39.patch, ZOOKEEPER-39_license.patch
>
>
> Moved from SourceForge to Apache.
> http://sourceforge.net/tracker/index.php?func=detail&aid=1962501&group_id=209147&atid=1008547

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-39) Use Watcher objects rather than boolean on read operations

Posted by "Mahadev konar (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-39?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mahadev konar updated ZOOKEEPER-39:
-----------------------------------

    Attachment: ZOOKEEPER-39_license.patch

here is a patch that adds the license file to the hashtable implementation. 
+1 for the patch from my side.

> Use Watcher objects rather than boolean on read operations
> ----------------------------------------------------------
>
>                 Key: ZOOKEEPER-39
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-39
>             Project: Zookeeper
>          Issue Type: New Feature
>          Components: c client, java client
>            Reporter: Patrick Hunt
>            Assignee: Andrew Kornev
>             Fix For: 3.0.0
>
>         Attachments: ZOOKEEPER-39.patch, ZOOKEEPER-39_license.patch
>
>
> Moved from SourceForge to Apache.
> http://sourceforge.net/tracker/index.php?func=detail&aid=1962501&group_id=209147&atid=1008547

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (ZOOKEEPER-39) Use Watcher objects rather than boolean on read operations

Posted by "Mahadev konar (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ZOOKEEPER-39?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12616581#action_12616581 ] 

Mahadev konar commented on ZOOKEEPER-39:
----------------------------------------

the patch looks good ... andrew is zookeeper-50 taken care of in this patch?

> Use Watcher objects rather than boolean on read operations
> ----------------------------------------------------------
>
>                 Key: ZOOKEEPER-39
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-39
>             Project: Zookeeper
>          Issue Type: New Feature
>          Components: c client, java client
>            Reporter: Patrick Hunt
>            Assignee: Andrew Kornev
>             Fix For: 3.0.0
>
>         Attachments: ZOOKEEPER-39.patch
>
>
> Moved from SourceForge to Apache.
> http://sourceforge.net/tracker/index.php?func=detail&aid=1962501&group_id=209147&atid=1008547

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (ZOOKEEPER-39) Use Watcher objects rather than boolean on read operations

Posted by "Andrew Kornev (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ZOOKEEPER-39?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrew Kornev updated ZOOKEEPER-39:
-----------------------------------

    Resolution: Fixed
        Status: Resolved  (was: Patch Available)

Patch committed

> Use Watcher objects rather than boolean on read operations
> ----------------------------------------------------------
>
>                 Key: ZOOKEEPER-39
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-39
>             Project: Zookeeper
>          Issue Type: New Feature
>          Components: c client, java client
>            Reporter: Patrick Hunt
>            Assignee: Andrew Kornev
>             Fix For: 3.0.0
>
>         Attachments: ZOOKEEPER-39.patch, ZOOKEEPER-39_license.patch
>
>
> Moved from SourceForge to Apache.
> http://sourceforge.net/tracker/index.php?func=detail&aid=1962501&group_id=209147&atid=1008547

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.