Commit 698754749db681278e0c36e81f3533a508a633ba

Authored by Igor Kulikov
2 parents 1fe5d1c0 34c149de

Merge branch 'master' of github.com:thingsboard/thingsboard

... ... @@ -45,7 +45,7 @@ public class RpcManagerActor extends ContextAwareActor {
45 45
46 46 private final ServerAddress instance;
47 47
48   - public RpcManagerActor(ActorSystemContext systemContext) {
  48 + RpcManagerActor(ActorSystemContext systemContext) {
49 49 super(systemContext);
50 50 this.sessionActors = new HashMap<>();
51 51 this.pendingMsgs = new HashMap<>();
... ... @@ -55,7 +55,6 @@ public class RpcManagerActor extends ContextAwareActor {
55 55 .filter(otherServer -> otherServer.getServerAddress().compareTo(instance) > 0)
56 56 .forEach(otherServer -> onCreateSessionRequest(
57 57 new RpcSessionCreateRequestMsg(UUID.randomUUID(), otherServer.getServerAddress(), null)));
58   -
59 58 }
60 59
61 60 @Override
... ...
... ... @@ -48,7 +48,8 @@ public class CassandraBufferedRateExecutor extends AbstractBufferedRateExecutor<
48 48
49 49 @Scheduled(fixedDelayString = "${cassandra.query.rate_limit_print_interval_ms}")
50 50 public void printStats() {
51   - log.info("Permits totalAdded [{}] totalLaunched [{}] totalReleased [{}] totalFailed [{}] totalExpired [{}] totalRejected [{}] currBuffer [{}] ",
  51 + log.info("Permits queueSize [{}] totalAdded [{}] totalLaunched [{}] totalReleased [{}] totalFailed [{}] totalExpired [{}] totalRejected [{}] currBuffer [{}] ",
  52 + getQueueSize(),
52 53 totalAdded.getAndSet(0), totalLaunched.getAndSet(0), totalReleased.getAndSet(0),
53 54 totalFailed.getAndSet(0), totalExpired.getAndSet(0), totalRejected.getAndSet(0),
54 55 concurrencyLevel.get());
... ...
... ... @@ -166,4 +166,8 @@ public abstract class AbstractBufferedRateExecutor<T extends AsyncTask, F extend
166 166 log.debug("[{}] {} task", taskCtx.getId(), action);
167 167 }
168 168 }
  169 +
  170 + protected int getQueueSize(){
  171 + return queue.size();
  172 + }
169 173 }
... ...