Document max_endpoint_dbs - #25
Draft
tillkruss wants to merge 4 commits into
Draft
Conversation
There was a problem hiding this comment.
Pull request overview
Updates the 1.x documentation around relay.max_endpoint_dbs to reflect the newer shared-cache behavior and to steer performance tuning toward relay.max_db_writers.
Changes:
- Updates
relay.max_endpoint_dbsdocumentation to describe the default of1and explain why higher values are usually counterproductive. - Revises historical guidance (previous default
32/min(vCPUs, pm.max_children)) and points readers torelay.max_db_writersfor write concurrency tuning. - Updates the configuration reference to reflect the new default for
relay.max_endpoint_dbsand adjusts the “peak performance” directives callout.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| docs/1.x/performance.md | Revises relay.max_endpoint_dbs guidance and related performance notes to match the newer concurrency model. |
| docs/1.x/configuration.md | Updates default values and tuning guidance to align with the updated performance recommendations. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+13
to
+17
| This directive determines the maximum number of PHP workers that will have their own in-memory cache. Not all workers need their own cache — workers without one become read-only workers that read from the shared memory pool. Giving too many workers an in-memory cache can negatively impact performance. | ||
|
|
||
| The default of `32` should be tuned to the number of CPU cores or maximum workers, whichever is lower: | ||
| The default is `1`, meaning all workers share a single in-memory cache per endpoint. This is the right setting for the vast majority of deployments and generally does not need to be changed. | ||
|
|
||
| ``` | ||
| max_endpoint_dbs = min(vCPUs, pm.max_children) | ||
| ``` | ||
| Earlier versions defaulted to `32` and recommended tuning this to roughly `min(vCPUs, pm.max_children)`, because a cache could only be written to by a single worker. That is no longer the case: multiple workers can now write to the same cache concurrently, so additional caches mostly duplicate the same data and consume more of `relay.maxmemory` without improving throughput. Use [`relay.max_db_writers`](#relaymax_db_writers) to control write concurrency instead. |
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.
No description provided.