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

stack commented on HBASE-6354:
------------------------------

{code}
+    final boolean[] isClosed = new boolean[] { false };
{code}

isClosed is name of a method that would check the closed boolean.  Suggest 
changing name of variable above to closed.

Are you using above because you want to change setting of a a final?  Use 
AtomicBoolean instead?

Maybe change this to be 100ms rather than 1000ms:

{code}
+        isClosed.wait(1000);
{code}

...because of the recommendation in "15.5.2.5.2. Sleeps in tests" in the 
reference guide.

I'd be game for trying this approach Himanshu.  Would be good to know "root 
cause" why current approach does not work.



                
> Wait till hard fail in case of erratic zookeeper session expiry
> ---------------------------------------------------------------
>
>                 Key: HBASE-6354
>                 URL: https://issues.apache.org/jira/browse/HBASE-6354
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Himanshu Vashishtha
>         Attachments: HBase6354-v1.patch
>
>
> There are number of tests that depends on zookeeper expire session 
> (HBaseTestingUtility#expireSession). The current approach is to create 
> handles on the existing sessions and call a close() on one of the handle. It 
> closes all the handles associated with this session. This should work in 
> theory but sometimes, it just doesn't work (don't know the root cause yet).
> We need to do some hacks ( such as in TestZookeeper#testClientSessionExpired).

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to