yugabyte / yugabyte-db

YugabyteDB - the cloud native distributed SQL database for mission-critical applications.
https://www.yugabyte.com
Other
8.95k stars 1.07k forks source link

[DocDB] Add flag for configuring rocksdb bytes_per_sync option #10822

Open ttyusupov opened 2 years ago

ttyusupov commented 2 years ago

Jira Link: DB-590

Description

  // Allows OS to incrementally sync files to disk while they are being
  // written, in the background. Issue one request for every bytes_per_sync
  // written. 0 turns it off.
  // Default: 0
  uint64_t bytes_per_sync = 0;
DBOptions SanitizeOptions(const std::string& dbname, const DBOptions& src) {
...
  if (result.rate_limiter.get() != nullptr) {
    if (result.bytes_per_sync == 0) {
      result.bytes_per_sync = 1024 * 1024;
    }
  }
...

Currently, we don't set bytes_per_sync explicitly, but we use a rate limiter, so it leads to sync every 1MB (independently for each file) at rocksdb level.

mohatagarvit commented 11 months ago

Hi,

Hope you are doing well!

I am Garvit Mohata, a MS CS student at UT Austin. My teammate (Kulin Shah) and I are taking the graduate Distributed Systems course and as a part of the course project, we are exploring the opportunity of contributing to the tikv open source repository.

This issue seems closely related to the content of the course so we were wondering if we can contribute to solve this issue.

Can you provide a bit more specific expectations and details to solve this issue and pointers if possible? Thank you!

Regards, Garvit

rthallamko3 commented 11 months ago

Hi @mohatagarvit , Refer to Yugabyte contribution page for instructions - https://docs.yugabyte.com/preview/contribute/core-database/checklist/ . Feel free to take up this issue. cc @Huqicheng in case you need references to this particular issue. If you get past the initial aspects, we can identify a couple more items in this area.