yugabyte/yugabyte-db

[DocDB] Enable printing out why each RocksDB flush is being done

Closed

#25,615 opened on 2025年1月14日

GitHub で見る
 (3 comments) (0 reactions) (1 assignee)C (8,229 stars) (1,003 forks)batch import
area/docdbgood first issuekind/enhancementpriority/medium

説明

Jira Link: DB-14868

Description

We have had two incidents now where inability to figure out why RocksDB flushes were occurring was key and extremely hard to figure out.

This task is to build instrumentation to make this easier in the future.

That is, create a runtime-settable gflag that turns on logging messages that for each flush describe why it is being done.

Reasons might include:

  • to stay under the global MemTable limit
  • to stay under the local MemTable limit
  • by request of a flush table RPC call
  • flush requested by DoCleanupIntentFiles

The above is almost certainly not a complete list. Ideally this task instruments all the calls to flush.

Although not ideal, it's probably acceptable for the reason log message to be given earlier than the log message announcing the flush itself as long as they can be correlated.

Ideally backport this to all versions in use.

Issue Type

kind/enhancement

Warning: Please confirm that this issue does not contain any sensitive information

  • I confirm this issue does not contain any sensitive information.

コントリビューターガイド