docs(config): clarify per-type WORKER_*_MAX_SLOTS is a reservation floor, not a cap - #2987
Closed
nicoloboschi wants to merge 1 commit into
Closed
docs(config): clarify per-type WORKER_*_MAX_SLOTS is a reservation floor, not a cap#2987nicoloboschi wants to merge 1 commit into
nicoloboschi wants to merge 1 commit into
Conversation
…oor, not a cap The HINDSIGHT_API_WORKER_<TYPE>_MAX_SLOTS env vars set a reserved minimum (a floor) for each operation type, not a per-type ceiling. A type can overflow its reservation into the shared pool up to WORKER_MAX_SLOTS, so the name reads as the opposite of the behaviour (issue #2963). Clarify the config table entries and add a warning admonition explaining the real ceiling (reserved + shared) and the only way to actually cap a type today (reserve the whole pool so the shared pool is zero). Mirrored into the published version-0.8 docs so it appears on the live site.
Collaborator
Author
|
Superseded by #3016, which does the full rename (RESERVED_SLOTS floor + MAX_CONCURRENT ceiling, deprecated MAX_SLOTS alias) and includes the same docs clarification. Closing in favor of that. |
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.
What
Documentation-only fix for #2963. The per-operation
HINDSIGHT_API_WORKER_<TYPE>_MAX_SLOTSenv vars are named like a per-type ceiling but actually set a reserved minimum (a floor). A type is guaranteed at least its reservation and may then overflow into the shared pool (WORKER_MAX_SLOTS - sum(reservations)) up toWORKER_MAX_SLOTS. So the name reads as the opposite of the behaviour, which cost the reporter a production latency investigation over aconsolidation=6/1(avail=0)log line that was working as designed.Changes
*_MAX_SLOTSnow say Reserved (minimum) slots … a floor, not a per-type cap.reserved(type) + shared pool currently available;CONSOLIDATION_MAX_SLOTS=1still allows up to 10 concurrent);versioned_docs/version-0.8so it appears on the live site (production ships released versions only, notcurrent).Scope
Docs only — no behaviour change. Verified against
config.py(WORKER_SLOT_RESERVATION_TYPES, thetotal_reserved <= worker_max_slotsfloor-shaped validation),worker/poller.py(_get_available_slots), andengine/db/ops_postgresql.py::claim_tasks(reserved phase + shared phase claims for any type).A rename to
*_RESERVED_SLOTS(with a deprecated alias) and/or an actual per-type ceiling knob — both suggested in the issue — are larger, behaviour-changing follow-ups intentionally left out of this PR.Closes #2963