mirror of https://github.com/apache/cassandra
Use default commitlog settings in test YAMLs
patch by Caleb Rackliffe; reviewed by David Capwell for CASSANDRA-19830
This commit is contained in:
parent
b8e08840ee
commit
93415c91af
|
|
@ -1,4 +1,5 @@
|
|||
4.0.14
|
||||
* Use default commitlog settings in test YAMLs (CASSANDRA-19830)
|
||||
* Do not spam log with SSLExceptions (CASSANDRA-18839)
|
||||
* Fix schema.cql created by a snapshot after dropping more than one column (CASSANDRA-19747)
|
||||
* UnsupportedOperationException when reducing scope for LCS compactions (CASSANDRA-19704)
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@
|
|||
#
|
||||
cluster_name: Test Cluster
|
||||
memtable_allocation_type: heap_buffers
|
||||
commitlog_sync: batch
|
||||
commitlog_sync_batch_window_in_ms: 1.0
|
||||
commitlog_sync: periodic
|
||||
commitlog_sync_period_in_ms: 10000
|
||||
commitlog_segment_size_in_mb: 5
|
||||
commitlog_directory: build/test/cassandra/commitlog
|
||||
cdc_raw_directory: build/test/cassandra/cdc_raw
|
||||
|
|
|
|||
|
|
@ -5,8 +5,8 @@
|
|||
cluster_name: Test Cluster
|
||||
# memtable_allocation_type: heap_buffers
|
||||
memtable_allocation_type: offheap_objects
|
||||
commitlog_sync: batch
|
||||
commitlog_sync_batch_window_in_ms: 1.0
|
||||
commitlog_sync: periodic
|
||||
commitlog_sync_period_in_ms: 10000
|
||||
commitlog_segment_size_in_mb: 5
|
||||
commitlog_directory: build/test/cassandra/commitlog
|
||||
cdc_raw_directory: build/test/cassandra/cdc_raw
|
||||
|
|
|
|||
|
|
@ -5,8 +5,8 @@
|
|||
cluster_name: Test Cluster
|
||||
memtable_allocation_type: heap_buffers
|
||||
# memtable_allocation_type: offheap_objects
|
||||
commitlog_sync: batch
|
||||
commitlog_sync_batch_window_in_ms: 1.0
|
||||
commitlog_sync: periodic
|
||||
commitlog_sync_period_in_ms: 10000
|
||||
commitlog_segment_size_in_mb: 5
|
||||
commitlog_directory: build/test/cassandra/commitlog
|
||||
# commitlog_compression:
|
||||
|
|
|
|||
|
|
@ -5,8 +5,8 @@
|
|||
cluster_name: Test Cluster
|
||||
# memtable_allocation_type: heap_buffers
|
||||
memtable_allocation_type: offheap_objects
|
||||
commitlog_sync: batch
|
||||
commitlog_sync_batch_window_in_ms: 1.0
|
||||
commitlog_sync: periodic
|
||||
commitlog_sync_period_in_ms: 10000
|
||||
commitlog_segment_size_in_mb: 5
|
||||
commitlog_directory: build/test/cassandra/commitlog
|
||||
# commitlog_compression:
|
||||
|
|
|
|||
|
|
@ -105,7 +105,8 @@ public class InstanceConfig implements IInstanceConfig
|
|||
.set("memtable_flush_writers", 1)
|
||||
.set("concurrent_compactors", 1)
|
||||
.set("memtable_heap_space_in_mb", 10)
|
||||
.set("commitlog_sync", "batch")
|
||||
.set("commitlog_sync", "periodic")
|
||||
.set("commitlog_sync_period_in_ms", 10000)
|
||||
.set("storage_port", storage_port)
|
||||
.set("native_transport_port", native_transport_port)
|
||||
.set("endpoint_snitch", DistributedTestSnitch.class.getName())
|
||||
|
|
@ -117,9 +118,7 @@ public class InstanceConfig implements IInstanceConfig
|
|||
// capacities that are based on `totalMemory` that should be fixed size
|
||||
.set("index_summary_capacity_in_mb", 50l)
|
||||
.set("counter_cache_size_in_mb", 50l)
|
||||
.set("key_cache_size_in_mb", 50l)
|
||||
// legacy parameters
|
||||
.forceSet("commitlog_sync_batch_window_in_ms", 1.0);
|
||||
.set("key_cache_size_in_mb", 50l);
|
||||
this.featureFlags = EnumSet.noneOf(Feature.class);
|
||||
this.jmxPort = jmx_port;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -163,7 +163,6 @@ public class RepairBoundaryTest extends TestBaseImpl
|
|||
{
|
||||
cluster = Cluster.build(3)
|
||||
.withConfig(config -> config.set("hinted_handoff_enabled", false)
|
||||
.set("commitlog_sync_batch_window_in_ms", 5)
|
||||
.set("num_tokens", 1)
|
||||
.set("initial_token", Long.toString(config.num() * 1000))
|
||||
.with(NETWORK)
|
||||
|
|
|
|||
|
|
@ -84,7 +84,6 @@ public class RepairTest extends TestBaseImpl
|
|||
{
|
||||
configModifier = configModifier.andThen(
|
||||
config -> config.set("hinted_handoff_enabled", false)
|
||||
.set("commitlog_sync_batch_window_in_ms", 5)
|
||||
.with(NETWORK)
|
||||
.with(GOSSIP)
|
||||
);
|
||||
|
|
|
|||
|
|
@ -57,7 +57,6 @@ public class ReplicaFilteringProtectionTest extends TestBaseImpl
|
|||
cluster = init(Cluster.build()
|
||||
.withNodes(REPLICAS)
|
||||
.withConfig(config -> config.set("hinted_handoff_enabled", false)
|
||||
.set("commitlog_sync", "batch")
|
||||
.set("num_tokens", 1)).start());
|
||||
|
||||
// Make sure we start w/ the correct defaults:
|
||||
|
|
@ -68,7 +67,8 @@ public class ReplicaFilteringProtectionTest extends TestBaseImpl
|
|||
@AfterClass
|
||||
public static void teardown()
|
||||
{
|
||||
cluster.close();
|
||||
if (cluster != null)
|
||||
cluster.close();
|
||||
}
|
||||
|
||||
@Test
|
||||
|
|
|
|||
|
|
@ -268,14 +268,21 @@ public abstract class CQLTester
|
|||
@BeforeClass
|
||||
public static void setUpClass()
|
||||
{
|
||||
if (ROW_CACHE_SIZE_IN_MB > 0)
|
||||
DatabaseDescriptor.setRowCacheSizeInMB(ROW_CACHE_SIZE_IN_MB);
|
||||
StorageService.instance.setPartitionerUnsafe(Murmur3Partitioner.instance);
|
||||
prePrepareServer();
|
||||
|
||||
// Once per-JVM is enough
|
||||
prepareServer();
|
||||
}
|
||||
|
||||
protected static void prePrepareServer()
|
||||
{
|
||||
System.setProperty("cassandra.superuser_setup_delay_ms", "0");
|
||||
|
||||
if (ROW_CACHE_SIZE_IN_MB > 0)
|
||||
DatabaseDescriptor.setRowCacheSizeInMB(ROW_CACHE_SIZE_IN_MB);
|
||||
StorageService.instance.setPartitionerUnsafe(Murmur3Partitioner.instance);
|
||||
}
|
||||
|
||||
@AfterClass
|
||||
public static void tearDownClass()
|
||||
{
|
||||
|
|
|
|||
|
|
@ -43,10 +43,17 @@ import org.apache.cassandra.utils.KillerForTests;
|
|||
public class CommitLogReaderTest extends CQLTester
|
||||
{
|
||||
@BeforeClass
|
||||
public static void beforeClass()
|
||||
public static void setUpClass()
|
||||
{
|
||||
prePrepareServer();
|
||||
|
||||
DatabaseDescriptor.setCommitFailurePolicy(Config.CommitFailurePolicy.ignore);
|
||||
JVMStabilityInspector.replaceKiller(new KillerForTests(false));
|
||||
|
||||
DatabaseDescriptor.setCommitLogSync(Config.CommitLogSync.batch);
|
||||
|
||||
// Once per-JVM is enough
|
||||
prepareServer();
|
||||
}
|
||||
|
||||
@Before
|
||||
|
|
|
|||
Loading…
Reference in New Issue