mirror of
https://gitee.com/ccnetcore/Yi
synced 2026-03-28 12:46:36 +08:00
22 lines
673 B
C#
22 lines
673 B
C#
|
|
using Microsoft.AspNetCore.Builder;
|
|||
|
|
using Microsoft.Extensions.DependencyInjection;
|
|||
|
|
using StartupModules;
|
|||
|
|
using Yi.Framework.Core.Configuration;
|
|||
|
|
|
|||
|
|
namespace Yi.Framework.Caching.Redis
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
public class YiFrameworkCachingRedisModule : IStartupModule
|
|||
|
|
{
|
|||
|
|
public void Configure(IApplicationBuilder app, ConfigureMiddlewareContext context)
|
|||
|
|
{
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
public void ConfigureServices(IServiceCollection services, ConfigureServicesContext context)
|
|||
|
|
{
|
|||
|
|
services.Configure<CachingConnOptions>(Appsettings.appConfiguration("CachingConnOptions"));
|
|||
|
|
services.AddSingleton<CacheInvoker, RedisCacheClient>();
|
|||
|
|
}
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
}
|