Document per-node, per-data-source scope of MaxOpenConns#9107
Open
mrckndt wants to merge 1 commit into
Open
Conversation
…-wide sizing formula. Clarifies that MaxOpenConns is applied independently on each Mattermost server node for the master database and each read/search replica - not as a cluster-wide limit. Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
Contributor
📝 WalkthroughWalkthroughThe documentation clarifies that connection limits apply per data source and Mattermost server node, adds HA cluster sizing formulas and examples, and explains separate pools for each configured read or search replica. ChangesConnection pool sizing
Estimated code review effort: 1 (Trivial) | ~5 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
Contributor
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In
`@source/administration-guide/configure/environment-configuration-settings.rst`:
- Around line 816-825: Clarify the database connection-sizing guidance around
MaxOpenConns and the HA example to state that the calculated value is
Mattermost’s pool upper bound, not the database’s exact max_connections setting.
Instruct readers to reserve additional capacity for administrative sessions,
migrations, monitoring, and other non-Mattermost clients.
In
`@source/administration-guide/scale/high-availability-cluster-based-deployment.rst`:
- Around line 702-706: Clarify the max_connections sizing guidance around the
formula using the nearby MaxOpenConns example: identify the result as Mattermost
application connection demand, not the complete database or pooler limit.
Instruct administrators to add appropriate headroom for administration,
monitoring, replication, migrations, and other clients, and to size
pooler-facing limits separately.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 7e5a832a-66cf-4ed5-8c54-c4d05a7c9934
📒 Files selected for processing (2)
source/administration-guide/configure/environment-configuration-settings.rstsource/administration-guide/scale/high-availability-cluster-based-deployment.rst
roberson-io
approved these changes
Jul 20, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Clarifies that
MaxOpenConnsis applied independently on each Mattermost server node, for the master database and for each configured read/search replica - not as cluster-wide limits. The docs previously said these settings apply "per data source" but never mentioned the additional multiplication by node count, which could lead to undersizingmax_connectionson the database.