commit | 1172da7883d57738a02cb766fd4e70c1e438c1f7 | [log] [tgz] |
---|---|---|
author | Madan Jampani <madan.jampani@gmail.com> | Wed Feb 17 18:40:36 2016 -0800 |
committer | Madan Jampani <madan.jampani@gmail.com> | Wed Feb 17 18:40:36 2016 -0800 |
tree | 1be92e2658d5556a36f7608b36e9fc2518473276 | |
parent | 28a697423999fc265c273ffc53969df183d2e877 [diff] [blame] |
Set max number of copycat transport server threads to 4 Change-Id: I20c662fdfcabd86b547c7b699b5f97ce3d912a41
diff --git a/core/store/primitives/src/main/java/org/onosproject/store/primitives/impl/CopycatTransportServer.java b/core/store/primitives/src/main/java/org/onosproject/store/primitives/impl/CopycatTransportServer.java index 2f24d6b..d4f851f 100644 --- a/core/store/primitives/src/main/java/org/onosproject/store/primitives/impl/CopycatTransportServer.java +++ b/core/store/primitives/src/main/java/org/onosproject/store/primitives/impl/CopycatTransportServer.java
@@ -64,7 +64,7 @@ this.messagingService = checkNotNull(messagingService); this.protocolMessageSubject = String.format("onos-copycat-server-%s", partitionId); this.newConnectionMessageSubject = String.format("onos-copycat-server-connection-%s", partitionId); - this.executorService = Executors.newScheduledThreadPool(Runtime.getRuntime().availableProcessors(), + this.executorService = Executors.newScheduledThreadPool(Math.min(4, Runtime.getRuntime().availableProcessors()), new CatalystThreadFactory("copycat-server-p" + partitionId + "-%d")); }