X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?p=controller.git;a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Fsal-inmemory-datastore%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fmd%2Fsal%2Fdom%2Fstore%2Fimpl%2FInMemoryDOMDataStoreConfigProperties.java;h=be89d53a69b2b99b442c0820781959f30832666f;hp=6e451ba12b20241d97c2826dce55d3870de0b9cb;hb=978152c5de3bf78ab6da5da4c2db391eec063429;hpb=51e91f6bdcc88c5aa96f956e516d31dbb5e5d5e0 diff --git a/opendaylight/md-sal/sal-inmemory-datastore/src/main/java/org/opendaylight/controller/md/sal/dom/store/impl/InMemoryDOMDataStoreConfigProperties.java b/opendaylight/md-sal/sal-inmemory-datastore/src/main/java/org/opendaylight/controller/md/sal/dom/store/impl/InMemoryDOMDataStoreConfigProperties.java index 6e451ba12b..be89d53a69 100644 --- a/opendaylight/md-sal/sal-inmemory-datastore/src/main/java/org/opendaylight/controller/md/sal/dom/store/impl/InMemoryDOMDataStoreConfigProperties.java +++ b/opendaylight/md-sal/sal-inmemory-datastore/src/main/java/org/opendaylight/controller/md/sal/dom/store/impl/InMemoryDOMDataStoreConfigProperties.java @@ -20,15 +20,18 @@ public class InMemoryDOMDataStoreConfigProperties { public static final int DEFAULT_MAX_DATA_CHANGE_EXECUTOR_QUEUE_SIZE = 1000; public static final int DEFAULT_MAX_DATA_CHANGE_EXECUTOR_POOL_SIZE = 20; public static final int DEFAULT_MAX_DATA_CHANGE_LISTENER_QUEUE_SIZE = 1000; + public static final int DEFAULT_MAX_DATA_STORE_EXECUTOR_QUEUE_SIZE = 5000; private static final InMemoryDOMDataStoreConfigProperties DEFAULT = create(DEFAULT_MAX_DATA_CHANGE_EXECUTOR_POOL_SIZE, DEFAULT_MAX_DATA_CHANGE_EXECUTOR_QUEUE_SIZE, - DEFAULT_MAX_DATA_CHANGE_LISTENER_QUEUE_SIZE); + DEFAULT_MAX_DATA_CHANGE_LISTENER_QUEUE_SIZE, + DEFAULT_MAX_DATA_STORE_EXECUTOR_QUEUE_SIZE); private final int maxDataChangeExecutorQueueSize; private final int maxDataChangeExecutorPoolSize; private final int maxDataChangeListenerQueueSize; + private final int maxDataStoreExecutorQueueSize; /** * Constructs an instance with the given property values. @@ -39,11 +42,22 @@ public class InMemoryDOMDataStoreConfigProperties { * maximum queue size for the data change notification executor. * @param maxDataChangeListenerQueueSize * maximum queue size for the data change listeners. + * @param maxDataStoreExecutorQueueSize + * maximum queue size for the data store executor. */ + public static InMemoryDOMDataStoreConfigProperties create(int maxDataChangeExecutorPoolSize, + int maxDataChangeExecutorQueueSize, int maxDataChangeListenerQueueSize, + int maxDataStoreExecutorQueueSize) { + return new InMemoryDOMDataStoreConfigProperties(maxDataChangeExecutorPoolSize, + maxDataChangeExecutorQueueSize, maxDataChangeListenerQueueSize, + maxDataStoreExecutorQueueSize); + } + public static InMemoryDOMDataStoreConfigProperties create(int maxDataChangeExecutorPoolSize, int maxDataChangeExecutorQueueSize, int maxDataChangeListenerQueueSize) { return new InMemoryDOMDataStoreConfigProperties(maxDataChangeExecutorPoolSize, - maxDataChangeExecutorQueueSize, maxDataChangeListenerQueueSize); + maxDataChangeExecutorQueueSize, maxDataChangeListenerQueueSize, + DEFAULT_MAX_DATA_STORE_EXECUTOR_QUEUE_SIZE); } /** @@ -54,10 +68,12 @@ public class InMemoryDOMDataStoreConfigProperties { } private InMemoryDOMDataStoreConfigProperties(int maxDataChangeExecutorPoolSize, - int maxDataChangeExecutorQueueSize, int maxDataChangeListenerQueueSize) { + int maxDataChangeExecutorQueueSize, int maxDataChangeListenerQueueSize, + int maxDataStoreExecutorQueueSize) { this.maxDataChangeExecutorQueueSize = maxDataChangeExecutorQueueSize; this.maxDataChangeExecutorPoolSize = maxDataChangeExecutorPoolSize; this.maxDataChangeListenerQueueSize = maxDataChangeListenerQueueSize; + this.maxDataStoreExecutorQueueSize = maxDataStoreExecutorQueueSize; } /** @@ -80,4 +96,11 @@ public class InMemoryDOMDataStoreConfigProperties { public int getMaxDataChangeListenerQueueSize() { return maxDataChangeListenerQueueSize; } + + /** + * Returns the maximum queue size for the data store executor. + */ + public int getMaxDataStoreExecutorQueueSize() { + return maxDataStoreExecutorQueueSize; + } }