Examples of lpush()


Examples of org.jredis.JRedis.lpush()

    private void saveIndexMeta(final String type, final String indexName, final String className, Set<String> keys){
        JRedis db = this.graph.getDatabase();

        try {
            if (type.equals(RedisIndexKeys.AUTO)) {
                db.lpush(RedisIndexKeys.META_INDICES_AUTO, indexName);
                db.set(RedisIndexKeys.META_AUTO + indexName + ":class", className);
                if(null != keys){
                    String key_list = RedisIndexKeys.META_AUTO + indexName + ":keys";
                    for(String key : keys){
                        db.sadd(key_list, key);
View Full Code Here

Examples of org.jredis.JRedis.lpush()

                    for(String key : keys){
                        db.sadd(key_list, key);
                    }
                }
            } else {
                db.lpush(RedisIndexKeys.META_INDICES_MANUAL, indexName);
                db.set(RedisIndexKeys.META_MANUAL + indexName + ":class", className);
            }
        } catch (RedisException e) {
            e.printStackTrace();
        }
View Full Code Here

Examples of org.jredis.JRedisFuture.lpush()

        do {
          int cnt = 0;
          Util.Timer timer = Timer.startNewTimer();
          Future<ResponseStatus> futureStat = null;
          while(cnt < reqCnt){
            futureStat = pipeline.lpush(key, data);
            cnt++;
          }
          long reqDoneTime = timer.mark();
        futureStat.get();
          long respDoneTime = timer.mark();
View Full Code Here

Examples of org.jredis.JRedisFuture.lpush()

        do {
          int cnt = 0;
          Util.Timer timer = Timer.startNewTimer();
          Future<ResponseStatus> futureStat = null;
          while(cnt < reqCnt){
            futureLong = pipeline.lpush(key, data);
            cnt++;
          }
          long reqDoneTime = timer.mark();
          assert futureStat != null;
          @SuppressWarnings({ "null", "unused" })
View Full Code Here

Examples of org.jredis.ri.alphazero.JRedisPipeline.lpush()

          Random rand = new Random();
          byte[] data = new byte[8];
          for(int i=0; i<100000; i++){
            rand.nextBytes(data);
            pipeline.lpush("my-list", data);
          }
          /* sync call */
          long llen = pipeline.sync().llen("my-list");
         
          String cntrKey = "my-cntr";
View Full Code Here

Examples of org.jredis.ri.alphazero.JRedisPipeline.lpush()

        do {
          int cnt = 0;
          Util.Timer timer = Timer.startNewTimer();
          Future<ResponseStatus> futureStat = null;
          while(cnt < reqCnt){
            futureStat = pipeline.lpush(key, data);
            cnt++;
          }
          long reqDoneTime = timer.mark();
        futureStat.get();
          long respDoneTime = timer.mark();
View Full Code Here

Examples of org.jredis.ri.alphazero.JRedisPipeline.lpush()

          Random rand = new Random();
          byte[] data = new byte[8];
          for(int i=0; i<1000000; i++){
            rand.nextBytes(data);
            pipeline.lpush("my-list", data);
          }
          /*
           * switch to synchronous semantics
           * the following call will block until
           * all the responses for above + the llen()
View Full Code Here

Examples of org.jredis.ri.alphazero.JRedisPipeline.lpush()

        do {
          int cnt = 0;
          Util.Timer timer = Timer.startNewTimer();
          Future<ResponseStatus> futureStat = null;
          while(cnt < reqCnt){
            futureLong = pipeline.lpush(key, data);
            cnt++;
          }
          long reqDoneTime = timer.mark();
          assert futureStat != null;
          @SuppressWarnings({ "null", "unused" })
View Full Code Here

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

  (new Thread(new Runnable() {
      public void run() {
    try {
        Thread.sleep(100);
        Jedis j = createJedis();
        j.lpush("foo", "a");
    } catch (InterruptedException e) {
        e.printStackTrace();
    }
      }
  })).start();
View Full Code Here

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

  (new Thread(new Runnable() {
      public void run() {
    try {
        Thread.sleep(100);
        Jedis j = createJedis();
        j.lpush("foo", "a");
    } catch (InterruptedException e) {
        e.printStackTrace();
    }
      }
  })).start();
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.