From 7e6fe5895e6b4bbd7ca8c4d8cb0397ea7207150d Mon Sep 17 00:00:00 2001 From: Duarte Nunes Date: Sun, 9 Jul 2017 17:51:52 +0200 Subject: [PATCH] column_family: Don't bother closing the flush_queue on stop() When stopping a column family we issue a flush(), for which we wait. Since writes are supposed to have stopped coming in, and also new flush requests, there's no need to call and wait for the flush_queue to be closed. Signed-off-by: Duarte Nunes --- database.cc | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/database.cc b/database.cc index bc198e9fd8..59a1400587 100644 --- a/database.cc +++ b/database.cc @@ -1073,9 +1073,7 @@ column_family::stop() { return when_all(_memtables->request_flush(), _streaming_memtables->request_flush()).discard_result().finally([this] { return _compaction_manager.remove(this).then([this] { // Nest, instead of using when_all, so we don't lose any exceptions. - return _flush_queue->close().then([this] { - return _streaming_flush_gate.close(); - }); + return _streaming_flush_gate.close(); }).then([this] { return _sstable_deletion_gate.close(); });