Skip to content

feat: increase max number of topics from 1,000,000 to 2,000,000 - #26956

Open
akdev wants to merge 3 commits into
mainfrom
feature/increase-max-topics-2m
Open

feat: increase max number of topics from 1,000,000 to 2,000,000#26956
akdev wants to merge 3 commits into
mainfrom
feature/increase-max-topics-2m

Conversation

@akdev

@akdev akdev commented Aug 24, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Raise the default topics.maxNumber config property in TopicsConfig.java from 1,000,000 to 2,000,000 to allow more HCS topics to be created on the network.
  • Add test coverage confirming congestion-pricing scaling behaves correctly at the new ceiling: a unit test in UtilizationScaledThrottleMultiplierTest exercising the real 2,000,000 default (below first tier, and crossing tiers), and a new HAPI test UtilScalePricingCheck#topicPriceScalesWithUtilization confirming CONSENSUS_CREATE_TOPIC fees scale with topic utilization end-to-end (modeled on the existing NFT congestion-pricing check).

Closes #26955

Test plan

  • ConsensusCreateTopicHandlerTest passes (parametrizes the limit rather than hardcoding it)
  • Confirm throttle/congestion-pricing scaling (UtilizationScaledThrottleMultiplier) behaves correctly at the new ceiling — covered by new unit test cases and UtilScalePricingCheck#topicPriceScalesWithUtilization (./gradlew hapiTestMiscEmbedded testEmbedded --tests "*UtilScalePricingCheck*", 2 passing)
  • Confirm whether a network dynamic-property update (FileUpdate on 0.0.121) is also needed to raise the limit on already-running networks, since maxNumber is a @NetworkProperty

Raises the default topics.maxNumber config property to allow more HCS
topics to be created on the network.

Closes #26955

Signed-off-by: Akram AbouEmara <508522+akdev@users.noreply.github.com>
@akdev
akdev requested a review from a team as a code owner August 24, 2026 21:38
@akdev akdev self-assigned this Aug 24, 2026
@lfdt-bot

lfdt-bot commented Aug 24, 2026

Copy link
Copy Markdown

Snyk checks have passed. No issues have been found so far.

Status Scan Engine Critical High Medium Low Total (0)
Open Source Security 0 0 0 0 0 issues

💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse.

joshmarinacci
joshmarinacci previously approved these changes Aug 24, 2026
…iling

Adds unit coverage in UtilizationScaledThrottleMultiplierTest for the
real 2,000,000 topics.maxNumber default (below-threshold and
tier-crossing cases), and a new HAPI test, topicPriceScalesWithUtilization,
modeled on the existing NFT congestion-pricing check, confirming
CONSENSUS_CREATE_TOPIC fees scale with topic utilization end-to-end.

Signed-off-by: Akram AbouEmara <508522+akdev@users.noreply.github.com>
@akdev
akdev requested a review from a team as a code owner August 24, 2026 22:02
@swirlds-automation
swirlds-automation dismissed joshmarinacci’s stale review August 24, 2026 22:03

2 file(s) changed in commit 513d65e

Wraps each annotated record component onto its own line to satisfy
the CI-pinned spotless/palantir-java-format output, which a local
cached task result had been masking.

Signed-off-by: Akram AbouEmara <508522+akdev@users.noreply.github.com>
@codecov

codecov Bot commented Aug 25, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

Impacted file tree graph

@@            Coverage Diff            @@
##               main   #26956   +/-   ##
=========================================
  Coverage     70.50%   70.50%           
- Complexity    11692    11693    +1     
=========================================
  Files          2586     2586           
  Lines        108484   108484           
  Branches      12145    12145           
=========================================
+ Hits          76490    76492    +2     
+ Misses        28014    28012    -2     
  Partials       3980     3980           
Files with missing lines Coverage Δ Complexity Δ
...java/com/hedera/node/config/data/TopicsConfig.java 100.00% <ø> (ø) 0.00 <0.00> (ø)

... and 1 file with indirect coverage changes

Impacted file tree graph

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@testlens-app

testlens-app Bot commented Aug 25, 2026

Copy link
Copy Markdown

✅ All tests passed ✅

🏷️ Commit: b02bd3b
▶️ Tests: 22737 executed
⚪️ Checks: 48/48 completed


Learn more about TestLens at testlens.app/docs.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Increase max number of topics (topics.maxNumber) from 1,000,000 to 2,000,000

3 participants