Skip to content

Commit

Permalink
Export GetFlushReasonString/GetCompactionReasonString in listener.h
Browse files Browse the repository at this point in the history
  • Loading branch information
git-hulk committed Dec 23, 2023
1 parent 87d2f42 commit 5ce6923
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions include/rocksdb/listener.h
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,8 @@ enum class CompactionReason : int {
kNumOfReasons,
};

const char* GetCompactionReasonString(CompactionReason compaction_reason);

enum class FlushReason : int {
kOthers = 0x00,
kGetLiveFiles = 0x01,
Expand All @@ -195,6 +197,8 @@ enum class FlushReason : int {
kWriteBufferManagerInitiated = 0xe,
};

const char* GetFlushReasonString(FlushReason flush_reason);

// TODO: In the future, BackgroundErrorReason will only be used to indicate
// why the BG Error is happening (e.g., flush, compaction). We may introduce
// other data structure to indicate other essential information such as
Expand Down

0 comments on commit 5ce6923

Please sign in to comment.