Skip to content

[Docs] operations/troubleshooting.mdx (EN+DE) still prescribes a per-actor ThroughputDispatcher for HTTP latency, the exact fix dispatcher-tuning.mdx retracts as a no-op #1203

Description

@pathosDev

Where

  • docs/src/content/docs/operations/troubleshooting.mdx → lines 226-228, "Symptom: HTTP latency high under load"
  • docs/src/content/docs/de/operations/troubleshooting.mdx → lines 233-234, "Symptom: HTTP-Latenz unter Last hoch"

Contradicted by:

  • docs/src/content/docs/operations/tuning/dispatcher-tuning.mdx → line 63, :::caution[Not \withDispatcher(new ThroughputDispatcher(...))`]`
  • docs/src/content/docs/de/operations/tuning/dispatcher-tuning.mdx → line 63

What's wrong

troubleshooting.mdx prescribes exactly the fix that dispatcher-tuning.mdx
explicitly retracts — and links to the retracting page while doing it.

troubleshooting.mdx (EN):

Actor work is fine; HTTP responses are slow.
Cause: an actor monopolizes the event loop, starving HTTP handlers.
Fix: per-actor ThroughputDispatcher
on the heavy actor.

dispatcher-tuning.mdx, the page that link points at:

Not withDispatcher(new ThroughputDispatcher(...))
This page used to recommend giving the busy actor its own ThroughputDispatcher.
That does not batch anything (#409): a dispatcher's queue holds one turn
per actor, and an actor may only have one turn queued at a time — so a
dispatcher dedicated to a single actor never has a second unit to drain, and
its batch is always exactly 1. withThroughput() is the per-actor knob.

The same page repeats it at line ~208:

What a per-actor dispatcher is not good for is batching. A
ThroughputDispatcher given to one actor drains a queue that never holds more
than that actor's single pending turn, so its budget is unreachable — use
withThroughput() instead.

So a reader hitting the HTTP-latency symptom is sent to apply a fix that is a
documented no-op, via a link to the page explaining that it is a no-op. The
retraction was applied to dispatcher-tuning.mdx but never propagated to the
troubleshooting entry, in either language.

Suggested fix

Rewrite the fix line in both troubleshooting.mdx files to name the knob that
actually works — ActorOptions.withThroughput(), which exists at
src/ActorOptions.ts:157:

Fix: lower the heavy actor's per-actor batch with
withThroughput()
so it yields to the event loop sooner. Do not give it its own
ThroughputDispatcher — a single-actor dispatcher's batch is always 1 (#409).

Kind

Factually wrong

Notes

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentationi18nTranslation, locale, and i18n trackingpriority: mediumUseful, not urgent

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions