r/dotnet
How are you guys dealing with .NET cold start in ephemeral containers?
- upvotes
- 35
- comments
- 47
Post
I am curious what people are seeing in production with .NET cold start, especially for workloads where containers are expected to come up quickly and may not live very long. I am less interested in synthetic hello-world numbers and more interested in actual services with DI, configuration, logging, authentication, Minimal APIs or MVC, JSON serialization, database clients, telemetry, etc. For those running regular CoreCLR, what combination of things got startup into an acceptable range? For example: ReadyToRun Composite ReadyToRun Tiered compilation / Quick JIT settings Startup warmup Preloading specific code paths ProfileOptimization / multicore JIT Reducing reflection or moving work to source generators Kubernetes startup/readiness probe tuning Keeping minimum replicas around Anything else that made a measurable difference What kind of cold-start numbers did you start with, and what did you get them down to? I am also especially interested in people who actually deployed NativeAOT for a nontrivial service. NativeAOT obviously attacks cold start much more directly, but once you leave small Minimal API examples there are some real tradeoffs. MVC is out, dynamic/reflection-heavy libraries can become a problem, some libraries need changes for trimming/AOT, and the diagnostics/observability story is different from normal CoreCLR. If you are using NativeAOT in...
Keep reading with a free account
The rest of this post, and every signal for Akamai, is in your free account.
Extracted from these lines
[comment u/pfluggs11] Fermyon, a company I worked at previously, built a whole cloud platform to solve this problem. Eventually they were acquired by Akamai but Spin Framework is open source and Spinkube is a CNCF project.