什么是configuration需要设置为asp.net的核心Web组件缩放?

//Startup.cs

我们为openid connect – Azure AD(授权)添加了configuration,如果只有一个实例正在运行,则下面的代码正在工作。 如果我们缩放为3个实例,那么实例正在按预期运行(dockerized容器),但授权不会发生?

services.AddAuthentication( options => { options.DefaultSignInScheme = CookieAuthenticationDefaults.AuthenticationScheme; options.DefaultChallengeScheme = CookieAuthenticationDefaults.AuthenticationScheme; options.DefaultScheme = CookieAuthenticationDefaults.AuthenticationScheme; options.DefaultAuthenticateScheme = OpenIdConnectDefaults.AuthenticationScheme; }).AddCookie(options => new CookieAuthenticationOptions { LoginPath = new PathString("/Home/"), ExpireTimeSpan = TimeSpan.FromMinutes(5), SlidingExpiration = false, }).AddOpenIdConnect(options => { options.SignInScheme = "Cookies"; options.ClientId = Configuration["ClientId"]; options.ClientSecret = Configuration["ClientSecret"]; options.Authority = Configuration["AADInstance"] + Configuration["TenantId"]; options.CallbackPath = Configuration["CallbackPath"]; options.ResponseType = OpenIdConnectResponseType.IdToken; }); 

我在其中一个实例中得到了下面的错误

 [40m[1m[33mwarn[39m[22m[49m: Microsoft.AspNetCore.Authentication.OpenIdConnect.OpenIdConnectHandler[14] .AspNetCore.Correlation. state property not found. [40m[1m[33mwarn[39m[22m[49m: Microsoft.AspNetCore.Authentication.OpenIdConnect.OpenIdConnectHandler[14] .AspNetCore.Correlation. state property not found. [41m[30mfail[39m[22m[49m: Microsoft.AspNetCore.Diagnostics.ExceptionHandlerMiddleware[0] A unhandled exception has occurred: Correlation failed. System.Exception: Correlation failed. at Microsoft.AspNetCore.Authentication.RemoteAuthenticationHandler`1. <HandleRequestAsync>d__12.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() atSystem.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)