From 9f552d29ee0af914c89b82f7076da3e4340b61fb Mon Sep 17 00:00:00 2001 From: Vedika Gupta Date: Sat, 24 Jan 2026 20:03:02 +0530 Subject: [PATCH 1/4] Fix SystemWebAdapters registration syntax in HttpApplicationHost --- .../fx-to-core/areas/authentication/samples/AspNetApp.cs | 2 +- aspnetcore/migration/fx-to-core/areas/hosting.md | 6 +++--- .../fx-to-core/areas/session/samples/remote/Global.asax.cs | 2 +- aspnetcore/migration/fx-to-core/inc/remote-app-setup.md | 6 +++--- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/aspnetcore/migration/fx-to-core/areas/authentication/samples/AspNetApp.cs b/aspnetcore/migration/fx-to-core/areas/authentication/samples/AspNetApp.cs index 9015b3ed0016..b535c5237c2b 100644 --- a/aspnetcore/migration/fx-to-core/areas/authentication/samples/AspNetApp.cs +++ b/aspnetcore/migration/fx-to-core/areas/authentication/samples/AspNetApp.cs @@ -16,7 +16,7 @@ protected void Application_Start() // HttpApplicationHost.RegisterHost(builder => { - builder.AddSystemWebAdapters() + builder.Services.AddSystemWebAdapters() .AddProxySupport(options => options.UseForwardedHeaders = true) .AddRemoteAppServer(options => { diff --git a/aspnetcore/migration/fx-to-core/areas/hosting.md b/aspnetcore/migration/fx-to-core/areas/hosting.md index 78c672f40c61..6ea8b122317e 100644 --- a/aspnetcore/migration/fx-to-core/areas/hosting.md +++ b/aspnetcore/migration/fx-to-core/areas/hosting.md @@ -43,7 +43,7 @@ namespace MvcApp { builder.AddServiceDefaults(); builder.AddSystemWebDependencyInjection(); - builder.AddSystemWebAdapters(); + builder.Services.AddSystemWebAdapters(); }); // Existing ASP.NET Framework configuration @@ -80,7 +80,7 @@ Register services with the dependency injection container by accessing the `Serv HttpApplicationHost.RegisterHost(builder => { builder.AddSystemWebDependencyInjection(); - builder.AddSystemWebAdapters(); + builder.Services.AddSystemWebAdapters(); builder.Services.AddScoped(); builder.Services.AddSingleton(); @@ -221,7 +221,7 @@ HttpApplicationHost.RegisterHost(builder => builder.Configuration.GetSection("Email")); builder.AddSystemWebDependencyInjection(); - builder.AddSystemWebAdapters(); + builder.Services.AddSystemWebAdapters(); }); // Consume options diff --git a/aspnetcore/migration/fx-to-core/areas/session/samples/remote/Global.asax.cs b/aspnetcore/migration/fx-to-core/areas/session/samples/remote/Global.asax.cs index 89073fe84f52..ee242554d04e 100644 --- a/aspnetcore/migration/fx-to-core/areas/session/samples/remote/Global.asax.cs +++ b/aspnetcore/migration/fx-to-core/areas/session/samples/remote/Global.asax.cs @@ -4,7 +4,7 @@ protected void Application_Start() { HttpApplicationHost.RegisterHost(builder => { - builder.AddSystemWebAdapters() + builder.Services.AddSystemWebAdapters() .AddJsonSessionSerializer(options => { // Serialization/deserialization requires each session key to be registered to a type diff --git a/aspnetcore/migration/fx-to-core/inc/remote-app-setup.md b/aspnetcore/migration/fx-to-core/inc/remote-app-setup.md index c97b2e88430b..586a78cf15dc 100644 --- a/aspnetcore/migration/fx-to-core/inc/remote-app-setup.md +++ b/aspnetcore/migration/fx-to-core/inc/remote-app-setup.md @@ -64,7 +64,7 @@ To configure the application to be available to handle the requests from the ASP { HttpApplicationHost.RegisterHost(builder => { - builder.AddSystemWebAdapters() + builder.Services.AddSystemWebAdapters() .AddRemoteAppServer(options => { // ApiKey is a string representing a GUID @@ -266,7 +266,7 @@ To enable proxying from the ASP.NET Core application to the ASP.NET Framework ap HttpApplicationHost.RegisterHost(builder => { builder.AddServiceDefaults(); - builder.AddSystemWebAdapters(); + builder.Services.AddSystemWebAdapters(); }); } ``` @@ -280,7 +280,7 @@ To enable proxying from the ASP.NET Core application to the ASP.NET Framework ap var builder = WebApplication.CreateBuilder(); builder.AddServiceDefaults(); - + builder.AddSystemWebAdapters(); + + builder.Services.AddSystemWebAdapters(); ... From 2499309457f8bba59d6c196d41711a568c0d436f Mon Sep 17 00:00:00 2001 From: Vedika Gupta Date: Sun, 25 Jan 2026 01:15:14 +0530 Subject: [PATCH 2/4] fixes --- .../fx-to-core/areas/authentication/samples/AspNetApp.cs | 2 +- aspnetcore/migration/fx-to-core/areas/hosting.md | 6 +++--- .../fx-to-core/areas/session/samples/remote/Global.asax.cs | 2 +- aspnetcore/migration/fx-to-core/inc/remote-app-setup.md | 4 ++-- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/aspnetcore/migration/fx-to-core/areas/authentication/samples/AspNetApp.cs b/aspnetcore/migration/fx-to-core/areas/authentication/samples/AspNetApp.cs index b535c5237c2b..9015b3ed0016 100644 --- a/aspnetcore/migration/fx-to-core/areas/authentication/samples/AspNetApp.cs +++ b/aspnetcore/migration/fx-to-core/areas/authentication/samples/AspNetApp.cs @@ -16,7 +16,7 @@ protected void Application_Start() // HttpApplicationHost.RegisterHost(builder => { - builder.Services.AddSystemWebAdapters() + builder.AddSystemWebAdapters() .AddProxySupport(options => options.UseForwardedHeaders = true) .AddRemoteAppServer(options => { diff --git a/aspnetcore/migration/fx-to-core/areas/hosting.md b/aspnetcore/migration/fx-to-core/areas/hosting.md index 6ea8b122317e..78c672f40c61 100644 --- a/aspnetcore/migration/fx-to-core/areas/hosting.md +++ b/aspnetcore/migration/fx-to-core/areas/hosting.md @@ -43,7 +43,7 @@ namespace MvcApp { builder.AddServiceDefaults(); builder.AddSystemWebDependencyInjection(); - builder.Services.AddSystemWebAdapters(); + builder.AddSystemWebAdapters(); }); // Existing ASP.NET Framework configuration @@ -80,7 +80,7 @@ Register services with the dependency injection container by accessing the `Serv HttpApplicationHost.RegisterHost(builder => { builder.AddSystemWebDependencyInjection(); - builder.Services.AddSystemWebAdapters(); + builder.AddSystemWebAdapters(); builder.Services.AddScoped(); builder.Services.AddSingleton(); @@ -221,7 +221,7 @@ HttpApplicationHost.RegisterHost(builder => builder.Configuration.GetSection("Email")); builder.AddSystemWebDependencyInjection(); - builder.Services.AddSystemWebAdapters(); + builder.AddSystemWebAdapters(); }); // Consume options diff --git a/aspnetcore/migration/fx-to-core/areas/session/samples/remote/Global.asax.cs b/aspnetcore/migration/fx-to-core/areas/session/samples/remote/Global.asax.cs index ee242554d04e..89073fe84f52 100644 --- a/aspnetcore/migration/fx-to-core/areas/session/samples/remote/Global.asax.cs +++ b/aspnetcore/migration/fx-to-core/areas/session/samples/remote/Global.asax.cs @@ -4,7 +4,7 @@ protected void Application_Start() { HttpApplicationHost.RegisterHost(builder => { - builder.Services.AddSystemWebAdapters() + builder.AddSystemWebAdapters() .AddJsonSessionSerializer(options => { // Serialization/deserialization requires each session key to be registered to a type diff --git a/aspnetcore/migration/fx-to-core/inc/remote-app-setup.md b/aspnetcore/migration/fx-to-core/inc/remote-app-setup.md index 586a78cf15dc..826b9851e5bc 100644 --- a/aspnetcore/migration/fx-to-core/inc/remote-app-setup.md +++ b/aspnetcore/migration/fx-to-core/inc/remote-app-setup.md @@ -64,7 +64,7 @@ To configure the application to be available to handle the requests from the ASP { HttpApplicationHost.RegisterHost(builder => { - builder.Services.AddSystemWebAdapters() + builder.AddSystemWebAdapters() .AddRemoteAppServer(options => { // ApiKey is a string representing a GUID @@ -266,7 +266,7 @@ To enable proxying from the ASP.NET Core application to the ASP.NET Framework ap HttpApplicationHost.RegisterHost(builder => { builder.AddServiceDefaults(); - builder.Services.AddSystemWebAdapters(); + builder.AddSystemWebAdapters(); }); } ``` From c731a0ccc8e7fc506173562be64230eb8d2c3e71 Mon Sep 17 00:00:00 2001 From: Vedika Gupta Date: Sun, 25 Jan 2026 01:22:23 +0530 Subject: [PATCH 3/4] fixes --- aspnetcore/migration/fx-to-core/inc/remote-app-setup.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/aspnetcore/migration/fx-to-core/inc/remote-app-setup.md b/aspnetcore/migration/fx-to-core/inc/remote-app-setup.md index 826b9851e5bc..e94101739969 100644 --- a/aspnetcore/migration/fx-to-core/inc/remote-app-setup.md +++ b/aspnetcore/migration/fx-to-core/inc/remote-app-setup.md @@ -64,7 +64,7 @@ To configure the application to be available to handle the requests from the ASP { HttpApplicationHost.RegisterHost(builder => { - builder.AddSystemWebAdapters() + builder.Services.AddSystemWebAdapters() .AddRemoteAppServer(options => { // ApiKey is a string representing a GUID @@ -266,7 +266,7 @@ To enable proxying from the ASP.NET Core application to the ASP.NET Framework ap HttpApplicationHost.RegisterHost(builder => { builder.AddServiceDefaults(); - builder.AddSystemWebAdapters(); + builder.Services.AddSystemWebAdapters(); }); } ``` @@ -280,7 +280,7 @@ To enable proxying from the ASP.NET Core application to the ASP.NET Framework ap var builder = WebApplication.CreateBuilder(); builder.AddServiceDefaults(); - + builder.Services.AddSystemWebAdapters(); + + builder.AddSystemWebAdapters(); ... From 5b304c3c5bb6e01fdd78e54bcecbad5a385bc1f3 Mon Sep 17 00:00:00 2001 From: Wade Pickett Date: Mon, 26 Jan 2026 11:29:09 -0800 Subject: [PATCH 4/4] Apply suggestion from @wadepickett Updated the doc date. --- aspnetcore/migration/fx-to-core/inc/remote-app-setup.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/aspnetcore/migration/fx-to-core/inc/remote-app-setup.md b/aspnetcore/migration/fx-to-core/inc/remote-app-setup.md index e94101739969..29370b8f2fc1 100644 --- a/aspnetcore/migration/fx-to-core/inc/remote-app-setup.md +++ b/aspnetcore/migration/fx-to-core/inc/remote-app-setup.md @@ -5,7 +5,7 @@ author: wadepickett description: Remote app setup monikerRange: '>= aspnetcore-6.0' ms.author: wpickett -ms.date: 12/10/2025 +ms.date: 01/26/2026 ms.topic: article uid: migration/fx-to-core/inc/remote-app-setup zone_pivot_groups: migration-remote-app-setup