Kestrel on linux logs a first chance exception with every EC2 health check request #61081
Open
1 task done
Labels
area-networking
Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions
Is there an existing issue for this?
Describe the bug
on linux we see a first chance exception with every
httpshealth test request from ec2Expected Behavior
the health check requests do not cause exceptions. it looks like the amount of exceptions is causing increased GC heap size and increased CPU and process memory usage.
Steps To Reproduce
a simple webapp that logs first chance exceptions, eg:
deploy as systemd service, eg:
add the instance to a TLS target group in EC2, the http requests from the health checks trigger these exceptions several times a second.
Exceptions (if any)
.NET Version
9.0.3
Anything else?
the environment is AWS EC2, we've tested with Amazon Linux 2023 and Ubuntu 24.04, and every version of dotnet from 8.0.0 to 9.0.3
the exceptions don't appear on Windows (tested server 2022 and 2025)
output from
dotnet --info
:The text was updated successfully, but these errors were encountered: