Document graceful shutdown configuration for actor hosts on Kubernetes
I maintainer di solito rispondono entro 1 giorno
Una pull request collegata è già stata integrata.
- #5317 di @shaul-apiiro — integrata
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 78/100
- Tipo di issue
- Documentazione
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- kubernetes
- Ambito
- documentation
Direzione di ricerca
Start with operations/hosting/kubernetes/kubernetes-production.md and add the requested “Graceful shutdown for actor hosts” production-guidelines section. Then add the short cross-linking note in developing-applications/building-blocks/actors/actors-runtime-config.md and the caveat in operations/resiliency/health-checks/sidecar-health.md. Done means the three pages explain the sidecar-outlives-app pattern, duration relationships, health-check warning, and native-sidecar exception.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
What content needs to be created or modified?
The docs describe dapr.io/block-shutdown-duration, dapr.io/graceful-shutdown-seconds, drainOngoingCallTimeout, and drainRebalancedActors individually, but nothing explains how they interact with Kubernetes pod termination for actor hosts.
Kubernetes sends SIGTERM to the application container and the daprd sidecar at the same time. An idle application typically exits in well under a second, while the sidecar is still in its shutdown sequence. The sidecar then fails every actor deactivation with connection refused (Failed to halt all actors...), OnDeactivateAsync never runs, and until the sidecar exits and placement is re-disseminated, other sidecars keep routing calls to actors placed on the dying pod — a multi-second window of failed actor invocations on every ordinary rolling restart. The drain settings are silently ineffective in this configuration because the application is already gone when draining happens.
We hit this in production and verified the behavior experimentally on dapr 1.18.4: with defaults, every rolling restart produces refused deactivations and a multi-second actor black-hole; with the sidecar-outlives-app configuration described below, deactivations complete against a live app and the failure window disappears.
Describe the solution you'd like
A production-guidelines section explaining the parallel-SIGTERM pitfall and the sidecar-outlives-app pattern: a preStop sleep on the application container, block-shutdown-duration, terminationGracePeriodSeconds, the drain settings, and the app health check (on an app-only endpoint) so the block ends early if the app genuinely dies — including how to size the durations relative to each other, a warning against probing the app through the sidecar (circular dependency), and a note that this guidance does not apply to native sidecars (where the app terminates first by design).
Where should the new material be placed?
operations/hosting/kubernetes/kubernetes-production.md— new section "Graceful shutdown for actor hosts" (main content)developing-applications/building-blocks/actors/actors-runtime-config.md— short note that the drain settings require the app to outlive the sidecar's shutdown, linking to the new sectionoperations/resiliency/health-checks/sidecar-health.md— one-line caveat under "Delay graceful shutdown" (the flag list there is also duplicated and can be fixed in passing)
The associated pull request from dapr/dapr, dapr/components-contrib, or other Dapr code repos
None — documentation of existing runtime behavior.
Additional context
Happy to submit the PR; the content is written and follows the docs contribution guide.
- Lingua principale
- SCSS
- Stelle
- 1k
- Fork
- 808
- Merge medio
- 2g 15h
- PR unite (30g)
- 73
Preparare l'ambiente
Avvia il container di sviluppo del progetto nel browser, con il tuo account GitHub.
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di dapr/docs
-
Add PHP tab to the Pub/Sub quickstart (and other PHP-supported building blocks)Forse già presa @hexmode l’ha presa 39 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 85/100
I maintainer di solito rispondono entro 1 giorno
-
content/missing-information
Difficoltà 1/5 1-3 ore Idoneità per principianti 88/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
Dapr Agents Quickstart is not in sync with dapr-agents git repoForse di nuovo libera @Pittu-Sharma l’ha presa 139 giorni fa e non c’è nessuna pull request aperta. Apertacontent/incorrect-information
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
-
content/incorrect-information
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno
Issue simili
-
bug documentation
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 80/100
awslabs/visual-asset-management-system#936 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno
-
14.3.x
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
-
good first issue help wanted r-docs
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
servo/rust-smallvec#824 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
I maintainer di solito rispondono entro 2 giorni