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

Ivan Kelly edited comment on BOOKKEEPER-580 at 7/4/13 3:29 PM:
---------------------------------------------------------------

We should only inform the user of the exception if the user can take useful 
action as a result, (i.e. do something different with regard to that ledger).

The user should only do something different it's view of the ledger is 
different after the close call, to what it was before the close call, 
specifically that the LAC is different. I _think_ that fencing prevents this, 
but I need to think about it some more. If I can find a case that this is not 
true, then definitely we should have an exception (or maybe a read to check the 
last add confirmed of the closed metadata matches what the local handle has).

I think the async and sync behaviour should be consistent though. Feels wrong 
to have the same api return a different result depending on how you call it.
                
      was (Author: ikelly):
    We should only inform the user of the exception if the user can take useful 
action as a result, (i.e. do something different with regard to that ledger).

The user should only do something different it's view of the ledger is 
different after the close call, to what it was before the close call, 
specifically that the LAC is different. I _think_ that fencing prevents this, 
but I need to think about it some more. If I can find a case that this is not 
true, then definitely we should have an exception (or maybe a read to check the 
last add confirmed of the closed metadata matches when the local handle has).

I think the async and sync behaviour should be consistent though. Feels wrong 
to have the same api return a different result depending on how you call it.
                  
> improve close logic
> -------------------
>
>                 Key: BOOKKEEPER-580
>                 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-580
>             Project: Bookkeeper
>          Issue Type: Bug
>          Components: bookkeeper-client
>            Reporter: Sijie Guo
>            Assignee: Sijie Guo
>             Fix For: 4.2.2, 4.3.0
>
>         Attachments: 0001-BOOKKEEPER-580-improve-close-logic.patch, 
> BOOKKEEPER-580.diff, BOOKKEEPER-580.diff
>
>
> currently, bookkeeper client still write ledger metadata to metadata storage 
> even the metadata is already closed or undergoing closing. which would cause 
> lots of bad version metadata update encountering unrecoverable errors in 
> ledger handle. e.g. NotEnoughtBookiesException.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to