cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Benedict (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CASSANDRA-9561) Lifecycle unit tests fail when run in parallel
Date Sat, 06 Jun 2015 08:43:00 GMT

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

Benedict commented on CASSANDRA-9561:
-------------------------------------

I suspect explicitly passing in a unique UUID (that is not a TimeUUID) into the CFMetaData
would do the job: the fact we're creating them both near to each other in time may be the
cause.

> Lifecycle unit tests fail when run in parallel
> ----------------------------------------------
>
>                 Key: CASSANDRA-9561
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-9561
>             Project: Cassandra
>          Issue Type: Test
>            Reporter: Stefania
>            Assignee: Stefania
>
> We had a new failure in TrackerTest:
> http://cassci.datastax.com/view/trunk/job/trunk_testall/139/testReport/junit/org.apache.cassandra.db.lifecycle/TrackerTest/testDropSSTables/
> {code}
> 14:02:05     [junit] Testcase: testSSTablesInBounds(org.apache.cassandra.db.lifecycle.ViewTest):
FAILED
> 14:02:05     [junit] 0(true) 1(false) expected:<1> but was:<2>
> 14:02:05     [junit] junit.framework.AssertionFailedError: 0(true) 1(false) expected:<1>
but was:<2>
> 14:02:05     [junit] 	at org.apache.cassandra.db.lifecycle.ViewTest.testSSTablesInBounds(ViewTest.java:65)
> 14:02:05     [junit] 
> 14:02:05     [junit] 
> 14:02:05     [junit] Tests run: 7, Failures: 1, Errors: 0, Skipped: 0, Time elapsed:
5.58 sec
> 14:02:05     [junit] 
> 14:02:05     [junit] ------------- Standard Output ---------------
> 14:02:05     [junit] ERROR 13:57:36 Unable to delete /tmp/la-1-big-Data.db (it will be
removed on server restart; we'll also retry after GC)
> 14:02:05     [junit] ERROR 13:57:36 Unable to delete /tmp/la-1-big-Data.db (it will be
removed on server restart; we'll also retry after GC)
> 14:02:05     [junit] ERROR 13:57:36 Unable to delete /tmp/la-2-big-Data.db (it will be
removed on server restart; we'll also retry after GC)
> 14:02:05     [junit] ERROR 13:57:36 Unable to delete /tmp/la-2-big-Data.db (it will be
removed on server restart; we'll also retry after GC)
> 14:02:05     [junit] ERROR 13:57:36 Unable to delete /tmp/la-0-big-Data.db (it will be
removed on server restart; we'll also retry after GC)
> 14:02:05     [junit] ERROR 13:57:36 Unable to delete /tmp/la-0-big-Data.db (it will be
removed on server restart; we'll also retry after GC)
> 14:02:05     [junit] ------------- ---------------- ---------------
> 14:02:05     [junit] Testcase: testDropSSTables(org.apache.cassandra.db.lifecycle.TrackerTest):
FAILED
> 14:02:05     [junit] expected:<9> but was:<95>
> 14:02:05     [junit] junit.framework.AssertionFailedError: expected:<9> but was:<95>
> 14:02:05     [junit] 	at org.apache.cassandra.db.lifecycle.TrackerTest.testDropSSTables(TrackerTest.java:217)
> 14:02:05     [junit] 	at org.apache.cassandra.db.lifecycle.TrackerTest.testDropSSTables(TrackerTest.java:192)
> {code}
> I could reproduce it easily but *only if running the tests in parallel*:
> {code}
> ant test -Dtest.runners=4 -Dtest.name=lifecycle/*Test
> {code}
> If running with a single JVM then no failures can be detected, not even after 50 runs
in a loop.
> I think the problem is a collision of file names for the sstables created by MockSchema.
When a JVM exits files are deleted due to File.deleteOnExit(), and a test running in a different
JVM and using the same file names may fail. This is the only explanation I could think of.
> I propose to place sstable files created by MockSchema in folders unique to each test
by passing a namespace to MockSchema, equal to the test name.
> cc [~benedict]



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

Mime
View raw message