You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zookeeper.apache.org by "Edward Ribeiro (JIRA)" <ji...@apache.org> on 2016/09/21 19:44:20 UTC

[jira] [Comment Edited] (ZOOKEEPER-2496) When inside a transaction, some exceptions do not have path information set.

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

Edward Ribeiro edited comment on ZOOKEEPER-2496 at 9/21/16 7:43 PM:
--------------------------------------------------------------------

Hey [~kazuakibanzai], could you please confirm if this issue is not a duplicate of https://issues.apache.org/jira/browse/ZOOKEEPER-2276 ?

Thanks

update: /cc [~arshad.mohammad]


was (Author: eribeiro):
Hey [~kazuakibanzai], could you please confirm if this issue is not a duplicate of https://issues.apache.org/jira/browse/ZOOKEEPER-2276 ?

Thanks

> When inside a transaction, some exceptions do not have path information set.
> ----------------------------------------------------------------------------
>
>                 Key: ZOOKEEPER-2496
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2496
>             Project: ZooKeeper
>          Issue Type: Bug
>    Affects Versions: 3.4.8, 3.5.1
>            Reporter: Kazuaki Banzai
>         Attachments: transactionException.patch
>
>
> If a client tries to execute some illegal operations inside a transaction, ZooKeeper throws an exception.
> Some exceptions such as NodeExistsException should have a path to indicate where the exception occurred.
> ZooKeeper clients can get the path by calling method getPath.
> However, this method returns null if the exception occurs inside a transaction.
> For example, when a client calls create /a and create /a in a transaction,
> ZooKeeper throws NodeExistsException but getPath returns null.
> In normal operation (outside transactions), the path information is set correctly.
> The patch only shows this bug occurs with NoNode exception and NodeExists exception,
> but this bug seems to occur with any exception which needs a path information:
> When an error occurred in a transaction, ZooKeeper creates an ErrorResult instance to represent error result.
> However, the ErrorResult class doesn't have a field for a path where an error occurred(See src/java/main/org/apache/zookeeper/OpResult.java for more details).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)