mirror of
https://github.com/scylladb/scylladb.git
synced 2026-05-01 13:45:53 +00:00
In https://github.com/scylladb/scylla/issues/8609, table::stop() that is called from database::drop_column_family is expected to wait on outstanding flushes by calling _memtable->request_flush(), but the memtable_list is considered empty() at this point as it has a single empty memtable, so request_flush() returns a ready future, without waiting on outstanding flushes. This change replaces the call to request_flush with flush(). Fix that by either returning _flush_coalescing future that resolves when the memtable is sealed, if available, or go through the get_flush_permit and _dirty_memory_manager->flush_one song and dance, even though the memtable is empty(), as the latter waits on pending flushes. Fixes #8609 Test: unit(dev) DTest: alternator_tests.py:AlternatorTest.test_batch_with_auto_snapshot_false(debug) Signed-off-by: Benny Halevy <bhalevy@scylladb.com> Message-Id: <20210524143438.1056014-1-bhalevy@scylladb.com>
110 KiB
110 KiB