]>
Commit | Line | Data |
---|---|---|
1e59de90 TL |
1 | // Copyright (c) Meta Platforms, Inc. and affiliates. All rights reserved. |
2 | // This source code is licensed under both the GPLv2 (found in the | |
3 | // COPYING file in the root directory) and Apache 2.0 License | |
4 | // (found in the LICENSE.Apache file in the root directory). | |
5 | ||
6 | #pragma once | |
7 | ||
8 | #include "rocksdb/status.h" | |
9 | #include "rocksdb/types.h" | |
10 | ||
11 | namespace ROCKSDB_NAMESPACE { | |
12 | ||
13 | // Callback invoked after finishing writing to the memtable but before | |
14 | // publishing the sequence number to readers. | |
15 | // Note that with write-prepared/write-unprepared transactions with | |
16 | // two-write-queues, PreReleaseCallback is called before publishing the | |
17 | // sequence numbers to readers. | |
18 | class PostMemTableCallback { | |
19 | public: | |
20 | virtual ~PostMemTableCallback() {} | |
21 | ||
22 | virtual Status operator()(SequenceNumber seq, bool disable_memtable) = 0; | |
23 | }; | |
24 | ||
25 | } // namespace ROCKSDB_NAMESPACE |