Examples of hlen()


Examples of redis.clients.jedis.Jedis.hlen()

        return hdel;
    }

    public Long hlen() {
        Jedis jedis = getResource();
        Long hlen = jedis.hlen(key());
        returnResource(jedis);
        return hlen;
    }

    public Set<String> hkeys() {
View Full Code Here

Examples of redis.clients.jedis.Jedis.hlen()

        jedis.connect();
        jedis.getClient().setTimeoutInfinite();

        // Get all the key value pairs from the Redis instance and store
        // them in memory
        totalKVs = jedis.hlen(hashKey);
        keyValueMapIter = jedis.hgetAll(hashKey).entrySet().iterator();
        LOG.info("Got " + totalKVs + " from " + hashKey);
        jedis.disconnect();
      }
View Full Code Here

Examples of redis.clients.jedis.Jedis.hlen()

    public long hLen(String key) throws Exception {
        Jedis jedis = null;
        try {
            jedis = this.jedisPool.getResource();
            long ret = jedis.hlen(SafeEncoder.encode(key));
            LOG.info("hlen key:" + key);

            return ret;
        } catch (Exception e) {
            LOG.error(e.getMessage(), e);
View Full Code Here

Examples of redis.clients.jedis.Jedis.hlen()

      pollKey = jedis.get(webKey);
      title = jedis.hget(pollKey, "title");
      question = jedis.hget(pollKey, "question");
      multiple = jedis.hget(pollKey, "multiple");
     
      long pollSize = jedis.hlen(pollKey);
      int otherFields = 10;
          long numAnswers = (pollSize-otherFields)/2;
         
          answers  = new ArrayList <String>();
         
View Full Code Here

Examples of redis.clients.jedis.Jedis.hlen()

    public long hLen(String key) throws Exception {
        Jedis jedis = null;
        try {
            jedis = this.jedisPool.getResource();
            long ret = jedis.hlen(SafeEncoder.encode(key));
            LOG.info("hlen key:" + key);

            return ret;
        } catch (Exception e) {
            LOG.error(e.getMessage(), e);
View Full Code Here

Examples of redis.clients.jedis.ShardedJedis.hlen()

                    tryCheckAndProcessRevisibleSet(queueUrl, shard, CMBProperties.getInstance().getRedisRevisibleSetFrequencySec());
                }
             
                //get the count number from
                if(suffix.equals("-H")){
                  messageCount += jedis.hlen(queueUrl + "-" + shard + suffix);
                } else if (suffix.equals("-V")){
                  messageCount += jedis.zcard(queueUrl + "-" + shard + suffix);
                }
            }
         
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.