I have an identityserver4 which validates tokens sent along with the requests my APIs receive.
To do that I am using identityserver3.accesstokenvalidation.
In startup:
JwtSecurityTokenHandler.InboundClaimTypeMap = new Dictionary<string, string>();
app.UseIdentityServerBearerTokenAuthentication(new IdentityServerBearerTokenAuthenticationOptions
{
Authority = Configurations.AuthorizationAuthority,
});
Now I might face cases where server running identityserver4 is shortly (multiple seconds) unavailable.
If this happens the service containing my APIs will not be able to run saying that:
No connection could be made because the target machine actively refused it
I want my API service to start even if IdentityServer server is not running, is there some kind of configuration Identityserver3.accesstokenvalidation provides to overcome this issue?
Set DelayLoadMetadata
to true
.