Is UseIISPlatformHandler () used to use UseIIS ()?

To this place , there, information on changes in Core is as follows.

public void Configure(IApplicationBuilder app, ILoggerFactory loggerfactory) { ... // Remove call to app.UseIISPlatformHandler(); This is handled by UseIIS in Main. // Remove call to app.UseForwardedHeaders(); This is handled by UseIIS in Main. ... } 

However, when checking the contents of a method, there is no such call as UseIIS (). Closest to UseIISIntegration (), but he commented as if it replaces UseForwardedHeaders ().

 public static void Main(string[] args) { var host = new WebHostBuilder() .UseDefaultConfiguration(args) .UseServer("Microsoft.AspNetCore.Server.Kestrel") // Replaces call to UseIISPlatformHandlerUrl() .UseIISIntegration() .UseStartup<Startup>() .Build(); host.Run(); } 

What? I do not understand?

+5
source share
1 answer

The problem is quite old, and since then some things have changed. You're on the right track though.

The call to UseIISPlatformHandler really moved from Startup to the beginning of the program and was renamed to UseIISIntegration .

+5
source

Source: https://habr.com/ru/post/1259653/


All Articles