Пример #1
0
 public static void RedisIncrement()
 {
     using (IRedisNativeClient nrc = new RedisNativeClient())
     {
         nrc.Del("Increment");
         for (int i = 0; i < iterations; i++)
         {
             nrc.Incr("Increment");
         }
     }
 }
Пример #2
0
        //------------------------------------------------------------------
        // INTEGER

        public long Incr(string key)
        {
            RedisNativeClient client = this.pool.GetRedisClient(key);

            return((client == null) ? 0L : client.Incr(key));
        }