[sheepdog] [PATCH 1/3] zookeeper: retry zk_create_seq_node on retryable error

Kai Zhang kyle at zelin.io
Thu May 30 17:09:35 CEST 2013


On May 30, 2013, at 11:04 PM, Liu Yuan <namei.unix at gmail.com> wrote:

> On 05/30/2013 10:58 PM, MORITA Kazutaka wrote:
>> How do you think we handle ZINVALIDSTATE?
>> 
>> I've also experienced ZINVALIDSTATE and ZSESSIONEXPIRED, but, IIUC,
>> those errors are caused by a timeout.  Am I wrong?
>> 
>> Either way, I think the error should be handled in the different patch
>> unless it is a retryable one.
> 
> I have no idea what ZINVALIDSTATE is nor if it is retryable. But with
> zookeeper v1.4.5, zk only return ZINVALIDSTATE for timeout as documented.
> 

This is not retryable. Because zhandle is not valid anymore.
In this case, we have to use zookeeper_init() to recreate a zhandle and also recreate EPHEMERAL node.

Thanks,
Kyle


More information about the sheepdog mailing list