Ejemplo n.º 1
0
        protected internal RedisCondition([NotNull] RedisContext context, [NotNull] ITransaction transaction)
        {
            Check.NotNull(context, nameof(context));
            Check.NotNull(transaction, nameof(transaction));

            _context = context;
            _transaction = transaction;
        }
Ejemplo n.º 2
0
 public ForumDiscussion(RedisKey key, RedisEntryMetadata metadata, RedisContext context, RedisEntry parent) : base(key, metadata, context, parent)
 {
 }
Ejemplo n.º 3
0
 public ForumComment(RedisKey key, RedisEntryMetadata metadata, RedisContext context, RedisEntry parent) : base(key, metadata, context, parent)
 {
 }
Ejemplo n.º 4
0
 protected internal RedisBatch(RedisContext context) : base(context)
 {
     Batch = context.Database.Database.CreateBatch();
 }
Ejemplo n.º 5
0
 public RedisSet(RedisKey key, RedisEntryMetadata metadata, RedisContext context, RedisEntry parent) : base(key, metadata, context, parent)
 {
 }
Ejemplo n.º 6
0
 public UserHelper(RedisContext redis)
 {
     this.redis = redis;
 }
Ejemplo n.º 7
0
        protected internal RedisBatch(RedisContext context, IBatch batch) : base(context)
        {
            Check.NotNull(batch, nameof(batch));

            Batch = batch;
        }
Ejemplo n.º 8
0
 protected override CustomerAccount UpdateEntity(RedisContext entityContext, CustomerAccount entity)
 {
     throw new NotImplementedException();
 }
Ejemplo n.º 9
0
 protected override IEnumerable <CustomerAccount> GetEntities(RedisContext entityContext, string k)
 {
     throw new NotImplementedException();
 }
Ejemplo n.º 10
0
 public RedisSearchCache(IDataContext context)
 {
     Context = (RedisContext)context;
 }
Ejemplo n.º 11
0
 public MoviesController()
 {
     context = new RedisContext();
 }
Ejemplo n.º 12
0
        public async static Task <Tuple <ChatRoom, User, ChatRoomConnectionPool> > BuildScenarioWithChatRoomAndUserWithPreviousConnectionPool(string chatRoomName,
                                                                                                                                              int activeConnectionsLimit, string userName, DBContext db, RedisContext redis)
        {
            var chatRoomConnectionPool = BuildChatRoomConnectionPoolWithFourUsers();
            var newChatRoom            = new ChatRoom
            {
                Id   = chatRoomConnectionPool.ChatRoomId,
                Name = chatRoomName,
                ActiveConnectionsLimit = activeConnectionsLimit
            };

            var newUser = new User
            {
                Name = userName
            };

            // creates chat room with the same Id of the pool and a user
            await db.ChatRooms.AddAsync(newChatRoom);

            await db.Users.AddAsync(newUser);

            await db.SaveChangesAsync();

            // creates a connection pool for the chat room
            await redis.SetKey(chatRoomConnectionPool.ChatRoomId, chatRoomConnectionPool, null);

            return(new Tuple <ChatRoom, User, ChatRoomConnectionPool>(newChatRoom, newUser, chatRoomConnectionPool));
        }