Examples of zincrby()


Examples of redis.clients.jedis.Pipeline.zincrby()

  Response<String> list = p.lpop("list");
  Response<String> hash = p.hget("hash", "foo");
  Response<Set<String>> zset = p.zrange("zset", 0, -1);
  Response<String> set = p.spop("set");
  Response<Boolean> blist = p.exists("list");
  Response<Double> zincrby = p.zincrby("zset", 1, "foo");
  Response<Long> zcard = p.zcard("zset");
  p.lpush("list", "bar");
  Response<List<String>> lrange = p.lrange("list", 0, -1);
  Response<Map<String, String>> hgetAll = p.hgetAll("hash");
  p.sadd("set", "foo");
View Full Code Here

Examples of redis.clients.jedis.Pipeline.zincrby()

        pipe.hset("login:", token, user);
        pipe.zadd("recent:", timestamp, token);
        if (item != null){
            pipe.zadd("viewed:" + token, timestamp, item);
            pipe.zremrangeByRank("viewed:" + token, 0, -26);
            pipe.zincrby("viewed:", -1, item);
        }
        pipe.exec();
    }
}
View Full Code Here

Examples of redis.clients.jedis.ShardedJedisPipeline.zincrby()

  Response<String> list = p.lpop("list");
  Response<String> hash = p.hget("hash", "foo");
  Response<Set<String>> zset = p.zrange("zset", 0, -1);
  Response<String> set = p.spop("set");
  Response<Boolean> blist = p.exists("list");
  Response<Double> zincrby = p.zincrby("zset", 1, "foo");
  Response<Long> zcard = p.zcard("zset");
  p.lpush("list", "bar");
  Response<List<String>> lrange = p.lrange("list", 0, -1);
  Response<Map<String, String>> hgetAll = p.hgetAll("hash");
  p.sadd("set", "foo");
View Full Code Here

Examples of redis.clients.jedis.Transaction.zincrby()

            trans.expire(matchedKey, 900);
        }

        trans.incr("type:" + type + ":views:");
        for (String term : terms) {
            trans.zincrby("views:" + adId, 1, term);
        }
        trans.zincrby("views:" + adId, 1, "");

        List<Object> response = trans.exec();
        double views = (Double)response.get(response.size() - 1);
View Full Code Here

Examples of redis.clients.jedis.Transaction.zincrby()

        trans.incr("type:" + type + ":views:");
        for (String term : terms) {
            trans.zincrby("views:" + adId, 1, term);
        }
        trans.zincrby("views:" + adId, 1, "");

        List<Object> response = trans.exec();
        double views = (Double)response.get(response.size() - 1);
        if ((views % 100) == 0){
            updateCpms(conn, adId);
View Full Code Here

Examples of redis.clients.jedis.Transaction.zincrby()

        }else{
            trans.incr("type:" + type + ":clicks:");
        }

        for (String word : matched) {
            trans.zincrby(clickKey, 1, word);
        }
        trans.exec();

        updateCpms(conn, adId);
    }
View Full Code Here

Examples of redis.clients.jedis.Transaction.zincrby()

                trans.rename(commonDest, commonDest + ":last");
                trans.rename(startKey, commonDest + ":pstart");
                trans.set(startKey, hourStart);
            }

            trans.zincrby(commonDest, 1, message);

            String recentDest = "recent:" + name + ':' + severity;
            trans.lpush(recentDest, TIMESTAMP.format(new Date()) + ' ' + message);
            trans.ltrim(recentDest, 0, 99);
            List<Object> results = trans.exec();
View Full Code Here

Examples of redis.clients.jedis.Transaction.zincrby()

                destination,
                new ZParams().aggregate(ZParams.Aggregate.MAX),
                destination, tkey2);

            trans.del(tkey1, tkey2);
            trans.zincrby(destination, 1, "count");
            trans.zincrby(destination, value, "sum");
            trans.zincrby(destination, value * value, "sumsq");

            List<Object> results = trans.exec();
            if (results == null){
View Full Code Here

Examples of redis.clients.jedis.Transaction.zincrby()

                new ZParams().aggregate(ZParams.Aggregate.MAX),
                destination, tkey2);

            trans.del(tkey1, tkey2);
            trans.zincrby(destination, 1, "count");
            trans.zincrby(destination, value, "sum");
            trans.zincrby(destination, value * value, "sumsq");

            List<Object> results = trans.exec();
            if (results == null){
                continue;
View Full Code Here

Examples of redis.clients.jedis.Transaction.zincrby()

                destination, tkey2);

            trans.del(tkey1, tkey2);
            trans.zincrby(destination, 1, "count");
            trans.zincrby(destination, value, "sum");
            trans.zincrby(destination, value * value, "sumsq");

            List<Object> results = trans.exec();
            if (results == null){
                continue;
            }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.