Unit Test Results.

Designed for use with JUnit and Ant.

Class dtest-latest_jdk17_python3.8_cythonno_x86_64_31_64

NameTestsErrorsFailuresSkippedTime(s)Time StampHost
8_cythonno_x86_64_31_6417013740.6292024-12-04T12:16:46.742971fd5a9c53cab7

Tests

NameStatusTypeTime(s)
test_materialized_views_authSuccess35.367
test_authorization_from_cache_while_unavailableSuccess54.128
test_write_and_readSuccess50.576
test_change_durable_writesFailureAssertionError: Commitlog was written with durable writes disabled assert 163840 == 90112 +163840 -90112

self = <configuration_test.TestConfiguration object at 0x7f9837cfe4f0>

@pytest.mark.timeout(60*30)
def test_change_durable_writes(self):
"""
@jira_ticket CASSANDRA-9560

Test that changes to the DURABLE_WRITES option on keyspaces is
respected in subsequent writes.

This test starts by writing a dataset to a cluster and asserting that
the commitlogs have been written to. The subsequent test depends on
the assumption that this dataset triggers an fsync.

After checking this assumption, the test destroys the cluster and
creates a fresh one. Then it tests that DURABLE_WRITES is respected by:

- creating a keyspace with DURABLE_WRITES set to false,
- using ALTER KEYSPACE to set its DURABLE_WRITES option to true,
- writing a dataset to this keyspace that is known to trigger a commitlog fsync,
- asserting that the commitlog has grown in size since the data was written.
"""
cluster = self.cluster
cluster.set_batch_commitlog(enabled=True, use_batch_window = cluster.version() < '5.0')
cluster.set_configuration_options(values={'commitlog_segment_size_in_mb': 1})

cluster.populate(1).start()
durable_node = cluster.nodelist()[0]

durable_init_size = commitlog_size(durable_node)
durable_session = self.patient_exclusive_cql_connection(durable_node)

# test assumption that write_to_trigger_fsync actually triggers a commitlog fsync
durable_session.execute("CREATE KEYSPACE ks WITH REPLICATION = {'class': 'SimpleStrategy', 'replication_factor': 1} "
"AND DURABLE_WRITES = true")
durable_session.execute('CREATE TABLE ks.tab (key int PRIMARY KEY, a int, b int, c int)')
logger.debug('commitlog size diff = ' + str(commitlog_size(durable_node) - durable_init_size))
write_to_trigger_fsync(durable_session, 'ks', 'tab')
logger.debug('commitlog size diff = ' + str(commitlog_size(durable_node) - durable_init_size))

assert commitlog_size(durable_node) > durable_init_size, \
"This test will not work in this environment; write_to_trigger_fsync does not trigger fsync."

durable_session.shutdown()
cluster.stop()
cluster.clear()

cluster.set_batch_commitlog(enabled=True, use_batch_window = cluster.version() < '5.0')
cluster.set_configuration_options(values={'commitlog_segment_size_in_mb': 1})
cluster.start()
node = cluster.nodelist()[0]
session = self.patient_exclusive_cql_connection(node)

# set up a keyspace without durable writes, then alter it to use them
session.execute("CREATE KEYSPACE ks WITH REPLICATION = {'class': 'SimpleStrategy', 'replication_factor': 1} "
"AND DURABLE_WRITES = false")
session.execute('CREATE TABLE ks.tab (key int PRIMARY KEY, a int, b int, c int)')
init_size = commitlog_size(node)
write_to_trigger_fsync(session, 'ks', 'tab')
> assert commitlog_size(node) == init_size, "Commitlog was written with durable writes disabled"
E AssertionError: Commitlog was written with durable writes disabled
E assert 163840 == 90112
E +163840
E -90112

configuration_test.py:104: AssertionError
106.359
test_delete_insert_searchSuccess70.804
test_populate_mv_after_insertSuccess51.423
test_set_get_concurrent_view_buildersSuccess40.293
test_multiple_cell_deletionsSuccess47.205
test_complementary_update_with_limit_on_static_column_with_empty_partitionsSuccess80.315
test_compact_storage_compositeSkipped5.1 > 3.X

/home/cassandra/cassandra-dtest/conftest.py:468: 5.1 > 3.X
0.284
test_ssl_client_auth_required_succeedSuccess77.973
test_batch_mutate_remove_super_columns_entire_rowSkipped5.1 > 4

/home/cassandra/cassandra-dtest/conftest.py:468: 5.1 > 4
0.282
test_incr_standard_removeSkipped5.1 > 4

/home/cassandra/cassandra-dtest/conftest.py:468: 5.1 > 4
0.482
test_default_aggregateSuccess24.979
test_describe_round_tripSuccess25.580
test_reading_with_multiple_filesSuccess28.708
test_force_with_none_downSuccess45.243
Properties »