Fixed sample and instructions

This commit is contained in:
Kiran Challa 2015-07-17 10:29:03 -07:00
parent 64fa05dbaf
commit 0d78bdbef2
1 changed files with 10 additions and 10 deletions

View File

@ -20,21 +20,21 @@ namespace SessionSample
public void ConfigureServices(IServiceCollection services) public void ConfigureServices(IServiceCollection services)
{ {
// Adds a default in-memory implementation of IDistributedCache // Uncomment the following line to use the Microsoft SQL Server implementation of IDistributedCache.
services.AddCaching(); // Note that this would require setting up the session state database.
//services.AddSqlServerCache(o =>
//{
// o.ConnectionString = "Server=.;Database=ASPNET5SessionState;Trusted_Connection=True;";
// o.SchemaName = "dbo";
// o.TableName = "Sessions";
//});
// Uncomment the following line to use the Redis implementation of IDistributedCache. // Uncomment the following line to use the Redis implementation of IDistributedCache.
// This will override any previously registered IDistributedCache service. // This will override any previously registered IDistributedCache service.
//services.AddTransient<IDistributedCache, RedisCache>(); //services.AddTransient<IDistributedCache, RedisCache>();
// Uncomment the following line to use the Microsoft SQL Server implementation of IDistributedCache. // Adds a default in-memory implementation of IDistributedCache
// Note that this would require setting up the session state database. services.AddCaching();
// This will override any previously registered IDistributedCache service.
//services.AddSqlServerCache(o =>
//{
// o.ConnectionString = "Server=.;Database=ASPNET5SessionState;Trusted_Connection=True;";
// o.TableName = "Sessions";
//});
services.AddSession(); services.AddSession();