News
.NET 10 Preview 3 Adds Native Container Publishing
Microsoft' third preview of .NET 10 focuses on performance, developer ergonomics, and modern cloud-native patterns.
While Preview 3 comes with a wide array of incremental improvements across performance, libraries, CLI tooling, ASP.NET Core/Blazor and more, it doesn't introduce any major new features.
The cloud-native camp, however, sees improvements to containerization functionality, including the ability to natively create container images in console apps. Also, developers can now explicity control the image format of containers.
"Console apps can now create container images via dotnet publish /t:PublishContainer
without having to set the <EnableSdkContainerSupport>
property to true
in the project file," said the Preview 3 release notes. "This brings them into line with the existing behavior for ASP.NET Core apps and Worker SDK apps, which have supported this for a while. If you need to disable this support for any reason, you can set the <EnableSdkContainerSupport>
property to false
in the project file."
[Click on image for larger view.] .NET 10 Preview 3 (source: Microsoft).
As far as controlling container image formats, developers can now explicitly control the container image format (.Docker or .OCI) using the new <ContainerImageFormat>
property in the .NET SDK. By default, the SDK chooses the format based on whether the container is multi-architecture and the format of the base image. This new property overrides that behavior, helping teams standardize on OCI if desired. It only affects container builds, not other SDK operations.
Preview 3 also includes several more cloud-native updates. ASP.NET Core now supports OpenAPI 3.1, aligning with the latest industry standards and enabling better integration with modern API gateways and design tools. Developers can also now serve OpenAPI documents in YAML format, which is widely used in infrastructure-as-code and DevOps workflows. On the frontend, Blazor Web Apps see notable improvements, including a new ReconnectModal
component for handling client disconnections more gracefully, enhancements to the QuickGrid component for conditional row styling and UI control, and improved navigation behavior that avoids unnecessary page scrolling and better handles query strings. Additionally, the Blazor framework script is now served as a fingerprinted static web asset, improving caching and performance -- especially useful in CDN or edge-deployed environments.
Other incremental improvements include:
- SDK Pruning Enhancements: The .NET SDK now automatically removes unused framework-provided package references, reducing disk usage and improving build performance.
- Noun-First CLI Command Aliases: New aliases like
dotnet package add
(for dotnet add package
) improve clarity and consistency in CLI commands.
- Native Shell Tab Completion: Generate shell completion scripts using
dotnet completions generate <SHELL>
for bash
, zsh
, powershell
, and others.
- CLI Interactive Mode by Default: In interactive terminals, CLI commands now default to interactive mode, streamlining user experience.
- Array Interface Method Devirtualization: The JIT can now devirtualize and inline interface methods on arrays, improving performance in collection-heavy code.
- Array Enumeration Optimization: Enumerator abstraction for arrays has been reduced, enabling better JIT inlining and stack allocation.
- Inlining of Late Devirtualized Methods: The JIT now supports inlining methods that become devirtualized after earlier inlining steps.
- Stack Allocation for Small Arrays: Small fixed-size arrays of value types (without GC pointers) can now be stack-allocated, reducing heap pressure.
- New Certificate APIs: Support for finding certificates by thumbprint using non-SHA1 algorithms like SHA-256.
- PEM Encoding Improvements: PEM APIs now support reading ASCII/UTF-8 text directly, simplifying cross-platform key and cert handling.
- DateOnly Support in
ISOWeek
: New overloads for working with DateOnly
values in week-based date logic.
- String Normalization for Spans: New APIs allow Unicode normalization directly on
Span<char>
and ReadOnlySpan<char>
types, reducing allocations.
- Numeric Ordering in String Comparisons:
CompareOptions.NumericOrdering
enables natural number-aware string comparisons (e.g., "Item2" <>
- ZipArchive Performance Enhancements: Updates improve performance in update mode and during parallel extraction.
- OrderedDictionary API Improvements: New overloads for
TryAdd
and TryGetValue
return index positions for efficient access.
- JSON Source Generation Update:
JsonSourceGenerationOptionsAttribute
now supports ReferenceHandler
for advanced serialization control.
You can learn more in "What's new in .NET 10" documentation, which was updated today (April 15). You can download Preview 3 here.
About the Author
David Ramel is an editor and writer at Converge 360.