Examples of QueueRequest


Examples of com.leansoft.bigqueue.thrift.QueueRequest

    try {
      this.initClient();
     
      System.out.println("big queue size before enqueue : " + client.getSize(TOPIC));
     
      QueueRequest req = new QueueRequest();
      req.setData("hello world".getBytes());
      client.enqueue(TOPIC, req);
     
      System.out.println("big queue size after enqueue : " + client.getSize(TOPIC));
     
      QueueResponse resp = client.peek(TOPIC);
View Full Code Here

Examples of com.leansoft.bigqueue.thrift.QueueRequest

            // DO NOT generate random logs here, this is accumulatively time consuming
            // and will affact the result of performance test,
            // instead pre-gen a log when the producer is initialized
//            byte[] logEvent = RandomLogGenerator.genRandomLogEventBytes(LOG_MESSAGE_SIZE_LIMIT);
            long begin = System.currentTimeMillis();
            QueueRequest request = new QueueRequest();
            request.setData(logEvent);
            QueueResponse response = client.enqueue(TestClient.TOPIC, request);
            long end = System.currentTimeMillis();
            if (response.getResultCode() == ResultCode.SUCCESS) {
              testResult.successCount++;
            } else {
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.