Skip to content

Dotnet-monitor graceful shutdown #6878

Open
@agobezy

Description

@agobezy

Discussed in #6865

Originally posted by agobezy June 21, 2024
I've been looking into this issue for the entire day and wanted to get some advice.

Environment details:

  1. Azure Kubernetes Cluster
  2. Single pod running two containers (dotnet app and dotnet monitor)
  3. Dotnet monitor image - mcr.microsoft.com/dotnet/monitor:8

Kubernetes allows you to run commands before a pod is terminated. The preStop is working on the dotnet app. The dotnet monitor stops instantly and leads to a server error.

image

image

image

image

Troubleshooting attempted:

  1. Following https://pracucci.com/graceful-shutdown-of-kubernetes-pods.html and setting a terminationGracePeriod of 300 seconds

Can the dotnet monitor process gracefully shutdown instead of terminating instantly?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions