Skip to content

feat(config): use reference RocksDB defaults - #50

Draft
bladehan1 wants to merge 1 commit into
developfrom
feature/remove_unverified_rocksdb_config
Draft

feat(config): use reference RocksDB defaults#50
bladehan1 wants to merge 1 commit into
developfrom
feature/remove_unverified_rocksdb_config

Conversation

@bladehan1

@bladehan1 bladehan1 commented Aug 14, 2026

Copy link
Copy Markdown
Owner

What does this PR do?

Remove the unverified storage.dbSettings overrides from the shipped
config.conf, allowing RocksDB defaults to come from reference.conf.

Add a regression test covering the effective block size, L0 compaction
trigger, and target file size.

Why are these changes required?

The shipped configuration overrides the documented RocksDB defaults without
representative production evidence.

In a fixed 500-block Mainnet replay, activating the combined intended options
reduced throughput from 2.421 blocks/s to 1.969 and 1.680 blocks/s. Restoring
the established effective options produced 2.418 blocks/s.

Explicit operator overrides remain supported. This change does not claim or
introduce a new optimized RocksDB profile.

This PR has been tested by:

  • ./gradlew :framework:test --tests org.tron.core.config.ConfigurationTest
  • ./gradlew :framework:checkstyleMain
  • ./gradlew :framework:checkstyleTest

Follow up

Build representative SR block-production benchmarks and observability before
selecting another RocksDB performance profile.

Extra details

No API, protocol, or database-format changes are introduced.

Closes #49


Summary by cubic

Use RocksDB defaults from reference.conf by removing unverified overrides in the shipped config. This restores documented defaults and avoids the observed throughput regression on Mainnet replay.

  • Old behavior: shipped config.conf set custom RocksDB storage.dbSettings (e.g., blocksize=64KB, L0 compaction trigger=4, target file size base=256MB).
  • New behavior: config.conf no longer sets storage.dbSettings; effective options come from reference.conf (blocksize=16KB, L0 compaction trigger=2, target file size base=64MB). Explicit operator overrides still work.
  • Adds a regression test to pin the effective defaults; no API/protocol/db-format changes.

Rollout

  • No action for most deployments. If you require the previous overrides, set storage.dbSettings explicitly in your config (e.g., blocksize=64, level0FileNumCompactionTrigger=4, targetFileSizeBase=256, plus any related keys you relied on).

Written for commit bd3ec32. Summary will update on new commits.

Review in cubic

Remove the shipped dbSettings overrides so config.conf inherits the documented reference defaults. Keep explicit user overrides available and cover the effective default values with a regression test.

Closes #49
@bladehan1 bladehan1 added the type:feature Feature request label Aug 14, 2026
@coderabbitai

coderabbitai Bot commented Aug 14, 2026

Copy link
Copy Markdown

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: f488c4f8-3c46-42b0-b060-9c4218cc458d

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type:feature Feature request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature] Use reference defaults for RocksDB configuration

1 participant