{"slug": "net-11-at-net-conf-c-15-runtime-async-mcp", "title": ".NET 11 at .NET Conf: C# 15, Runtime Async, MCP", "summary": "Microsoft's .NET 11, set to be detailed at .NET Conf 2026 opening November 10, ships C# 15 with a new `union` keyword for closed type sets, Runtime Async enabled by default for projects targeting net11.0 with no feature flag, and native Model Context Protocol support in ASP.NET Core via the `ModelContextProtocol.AspNetCore` package for HTTP/SSE transport. The official MCP C# SDK, co-maintained by Microsoft and Anthropic, lets teams register existing REST endpoints as MCP tools for AI agents without a rewrite, while EF Core 11 adds FullJoin and hybrid vector search alongside breaking changes affecting older SQL Server configurations. C# 15 also introduces the `closed` keyword for exhaustive class hierarchies, and the release marks the arrival of union types the community has requested since 2014.", "body_md": ".NET Conf 2026 opens November 10 and .NET 11 is the reason to watch. This is the most significant C# release in years: union types land after a decade of community demand, Runtime Async graduates from preview and runs without a feature flag, and ASP.NET Core ships native MCP support so your existing APIs can talk to AI agents with a few lines of setup. EF Core 11 adds FullJoin and hybrid vector search while quietly introducing breaking changes that will bite teams on old SQL Server configurations. Here is what is worth adopting immediately and what needs a migration plan before you upgrade.\n\n## C# 15 Union Types: The OneOf Killer\n\nThe `union` keyword in C# 15 is the feature the community has been asking for since 2014. It declares a closed set of alternative types without inheritance. `Pet` is not a base class — `Cat` and `Dog` have no knowledge that `Pet` exists.\n\n```\npublic record class Cat(string Name);\npublic record class Dog(string Name);\npublic record class Bird(string Name);\n\npublic union Pet(Cat, Dog, Bird);\n\nstring Describe(Pet pet) => pet switch\n{\n    Dog d  => $\"dog: {d.Name}\",\n    Cat c  => $\"cat: {c.Name}\",\n    Bird b => $\"bird: {b.Name}\",\n};\n```\n\nAdd a fourth case type and every switch that does not handle it refuses to compile. That exhaustiveness check is the whole point. The `OneOf<T1,T2,T3,TError>` NuGet pattern that half the ecosystem has been using as a workaround is now obsolete.\n\nC# 15 also adds the `closed` keyword for class hierarchies. Where `union` composes independent types into a named set, `closed` handles the case where types share genuine IS-A inheritance but the compiler needed to know the family was complete.\n\n```\npublic closed record class GateState;\npublic record class Closed : GateState;\npublic record class Open(float Percent) : GateState;\n\nstring Describe(GateState state) => state switch\n{\n    Closed        => \"closed\",\n    Open(var pct) => $\"{pct}% open\",\n};\n```\n\nNo default arm. No compiler warning. The `closed` modifier locks derivation to the assembly so the compiler knows every case that can exist. [Andrew Lock’s deep-dive on union types in the .NET 11 previews](https://andrewlock.net/exploring-the-dotnet-11-preview-2-dotnet-gets-union-types/) covers the serialization edges with System.Text.Json if you need the full picture.\n\n## Runtime Async: On by Default, Nothing to Configure\n\nRuntime Async has been in preview for two releases. In .NET 11 it becomes the default for projects targeting `net11.0` — no `EnablePreviewFeatures` flag, no opt-in. You get it when you upgrade.\n\nThe architectural change is that the runtime generates async state machines instead of the C# compiler. In practice: actual method names appear on the call stack during execution. No more a wall of `MoveNext` compiler artifacts in your profiler. Local variables stay on the stack until execution actually crosses an await boundary that suspends, so heap allocations drop. Async continuations skip `ExecutionContext` capture when no ambient state is in use — a meaningful performance win in high-throughput services where most awaits complete synchronously.\n\nThis is the kind of improvement that is invisible until you are debugging a production incident. Then it matters a lot.\n\n## ASP.NET Core Gets Native MCP Support\n\nThe .NET 11 ASP.NET Core roadmap explicitly prioritizes “building agentic web apps” and that is not marketing. The official MCP C# SDK, co-maintained by Microsoft and Anthropic, is production-ready and ships the `ModelContextProtocol.AspNetCore` package for HTTP/SSE transport.\n\nWhat this means for teams with existing REST APIs: you can register your existing endpoints as MCP tools and expose the whole thing to AI agents without a rewrite. The app can also run as an MCP client, consuming tools from other servers. The same pattern works for console apps and Azure Functions.\n\nThe .NET 11 Agent Framework layers on top with OpenAI responses protocol support, agent-to-agent orchestration, and AG-UI for real-time agent-to-UI interactions. For enterprise teams who have spent years building ASP.NET Core services, this is the fastest credible on-ramp to the AI agent ecosystem. See [how to expose your existing ASP.NET Core APIs as MCP server tools](https://dev.to/rahmatafridi/expose-your-existing-aspnet-core-apis-to-ai-agents-with-a-secure-mcp-server-3067) for a practical walkthrough.\n\n## EF Core 11: New Queries and Real Breaking Changes\n\nThe headline additions in EF Core 11 are `FullJoin` (which translates directly to a SQL FULL JOIN, replacing the GroupJoin gymnastics needed before), `MaxBy`/` MinBy` LINQ-to-SQL translation, and hybrid vector search — combining SQL Server’s approximate vector index with full-text search to merge semantic and linguistic result rankings.\n\nThe breaking changes deserve equal attention. Three things to audit before you upgrade:\n\n- **SqlVector<T> columns are no longer auto-loaded.** Properties are null unless you explicitly fetch them. Code that assumed these came back with the entity will break silently.\n- **SQL Server compatibility level default changed from 150 to 160.** Apps running against SQL Server 2019 or earlier need to set the compat level explicitly or EF Core 11 will target features that do not exist on the server.\n- **LINQ queries can generate different SQL even when you have not changed them.** The query optimizer removes unnecessary joins, orderings, and no-op casts. Run your integration test suite against EF Core 11 before shipping to production.\n\nThe full change list is in the [official EF Core 11 What’s New documentation](https://learn.microsoft.com/en-us/ef/core/what-is-new/ef-core-11.0/whatsnew).\n\n## .NET 11 Upgrade Checklist\n\nThe practical steps to migrate:\n\n1. Update the SDK and change `<TargetFramework>net11.0</TargetFramework>` in your project file.\n2. Update EF Core, ASP.NET Core, and other Microsoft NuGet packages to 11.x.\n3. Run your integration tests. Pay specific attention to EF Core query output — different SQL is the most common upgrade surprise.\n4. If you use `SqlVector<T>` : audit all loading patterns. These properties are now null by default.\n5. If you target SQL Server older than 2022: add an explicit compatibility level override in your EF Core configuration.\n6. Runtime Async is on by default on `net11.0` . No action needed.\n7. Union types are additive. Adopt in new code at your own pace — nothing forces migration of existing patterns.\n\n.NET Conf 2026 starts November 10 — the [.NET Conf 2026 agenda](https://dotnet.microsoft.com/en-us/conf/2026/agenda) has four days of sessions including the official GA keynote. The complete feature documentation is at [What’s New in .NET 11](https://learn.microsoft.com/en-us/dotnet/core/whats-new/dotnet-11/overview). For teams running .NET 10 LTS, there is no urgency — but union types alone make .NET 11 worth planning for.", "url": "https://wpnews.pro/news/net-11-at-net-conf-c-15-runtime-async-mcp", "canonical_source": "https://byteiota.com/dotnet-11-csharp-15-runtime-async-mcp/", "published_at": "2026-11-06 02:07:22+00:00", "updated_at": "2026-11-06 02:21:57.568295+00:00", "lang": "en", "topics": ["developer-tools", "ai-agents", "agent-protocols", "artificial-intelligence"], "entities": ["Microsoft", ".NET 11", "C# 15", "ASP.NET Core", "Anthropic", "Model Context Protocol", "EF Core 11", ".NET Conf 2026"], "also_reported_by": [], "alternates": {"html": "https://wpnews.pro/news/net-11-at-net-conf-c-15-runtime-async-mcp", "markdown": "https://wpnews.pro/news/net-11-at-net-conf-c-15-runtime-async-mcp.md", "text": "https://wpnews.pro/news/net-11-at-net-conf-c-15-runtime-async-mcp.txt", "jsonld": "https://wpnews.pro/news/net-11-at-net-conf-c-15-runtime-async-mcp.jsonld"}}