mirror of https://github.com/apache/cassandra
Fix CommitLogStressTest timeout
Patch by jmckenzie; reviewed by blambov for CASSANDRA-12207
This commit is contained in:
parent
5e111e64d0
commit
ed9014818c
|
|
@ -130,12 +130,12 @@ public class CommitLogStressTest
|
|||
|
||||
SchemaLoader.loadSchema();
|
||||
SchemaLoader.schemaDefinition(""); // leave def. blank to maintain old behaviour
|
||||
CommitLog.instance.stopUnsafe(true);
|
||||
}
|
||||
|
||||
@Before
|
||||
public void cleanDir() throws IOException
|
||||
{
|
||||
CommitLog.instance.stopUnsafe(true);
|
||||
File dir = new File(location);
|
||||
if (dir.isDirectory())
|
||||
{
|
||||
|
|
@ -208,9 +208,9 @@ public class CommitLogStressTest
|
|||
for (CommitLogSync sync : CommitLogSync.values())
|
||||
{
|
||||
DatabaseDescriptor.setCommitLogSync(sync);
|
||||
CommitLog commitLog = new CommitLog(CommitLogArchiver.disabled()).start();
|
||||
// Need to enable reserve segment creation as close to test start as possible to minimize race
|
||||
CommitLog commitLog = new CommitLog(CommitLogArchiver.disabled());
|
||||
commitLog.segmentManager.enableReserveSegmentCreation();
|
||||
commitLog.start();
|
||||
testLog(commitLog);
|
||||
assert !failed;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue