You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@oozie.apache.org by "Robert Kanter (JIRA)" <ji...@apache.org> on 2013/10/22 00:48:43 UTC

[jira] [Updated] (OOZIE-1589) TestZKLocksService is flakey

     [ https://issues.apache.org/jira/browse/OOZIE-1589?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Robert Kanter updated OOZIE-1589:
---------------------------------

    Attachment: OOZIE-1589.patch

> TestZKLocksService is flakey
> ----------------------------
>
>                 Key: OOZIE-1589
>                 URL: https://issues.apache.org/jira/browse/OOZIE-1589
>             Project: Oozie
>          Issue Type: Bug
>          Components: tests
>    Affects Versions: trunk
>            Reporter: Robert Kanter
>            Assignee: Robert Kanter
>         Attachments: OOZIE-1589.patch
>
>
> TestZKLocksService is highly dependent on the order of things happening because its testing locks.  I've seen tests in this class fail a number of times with messages like this:
> {noformat}
> expected:<a:[1-L a:2-L a:1-U] a:2-U> but was:<a:[2-L a:1-L] a:2-U>
> {noformat}
> which is because things happened in a slightly different order than it was expecting (though everything is happening correctly)
> When I created these tests, I just took the TestLockService and made it use ZKLocks instead of MemoryLocks.  The ZKLocks take longer to lock than the MemoryLocks, so the timings are sometimes too fast.  I think we just need to increase the sleep calls, and use the {{sleep()}} method instead of {{Thread.sleep()}} so it will scale with the "waitfor ratio" on slower machines.



--
This message was sent by Atlassian JIRA
(v6.1#6144)