public OrderController(IOrderSevice orderSevice, IConnectionMultiplexer redis, IRedisClient redisClient)
 {
     _orderSevice = orderSevice;
     _redis       = redis;
     _redisClient = redisClient;
     _db          = _redis.GetDatabase();
     _server      = redis.GetServer(redis.GetEndPoints()[0]);
 }
Example #2
0
        //string connectionStr = Configuration.GetSection("AppSetting")["MapKey"];

        public HomeController(UserSevice userService, SysUserSevice sysUserService, IOrderSevice orderSevice, IConnectionMultiplexer redis, IRedisClient redisClient, IMemoryCache memoryCache)
        {
            _userService    = userService;
            _sysUserService = sysUserService;
            _orderSevice    = orderSevice;
            _redis          = redis;
            _redisClient    = redisClient;
            _db             = _redis.GetDatabase();
            _server         = redis.GetServer(redis.GetEndPoints()[0]);
            _memoryCache    = memoryCache;
        }