Azure App ServiceSession Timeout
Redis, Cosmos DB, SQL Server
CloudAzure
ASP.NET Core MVCStartup.csConfigureService()
// SQL Server
services.AddDistributedSqlServerCache(options =>
{
options.ConnectionString = Configuration.GetConnectionString("DefaultConnection");
options.SchemaName = "dbo";
options.TableName = "SQLSessions";
});
services.AddSession(options =>
{
options.IdleTimeout = TimeSpan.FromMinutes(60 * 24);
options.Cookie.HttpOnly = true;
options.Cookie.IsEssential = true;
options.Cookie.SecurePolicy = CookieSecurePolicy.Always;
});