2 * Copyright (c) 2014 Brocade Communications Systems, Inc. and others. All rights reserved.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
9 package org.opendaylight.controller.cluster.datastore;
12 * Wrapper class for DistributedDataStore configuration properties.
14 * @author Thomas Pantelis
16 public class DistributedDataStoreProperties {
17 private final int maxShardDataChangeListenerQueueSize;
18 private final int maxShardDataChangeExecutorQueueSize;
19 private final int maxShardDataChangeExecutorPoolSize;
20 private final int shardTransactionIdleTimeoutInMinutes;
22 public DistributedDataStoreProperties() {
23 maxShardDataChangeListenerQueueSize = 1000;
24 maxShardDataChangeExecutorQueueSize = 1000;
25 maxShardDataChangeExecutorPoolSize = 20;
26 shardTransactionIdleTimeoutInMinutes = 10;
29 public DistributedDataStoreProperties(int maxShardDataChangeListenerQueueSize,
30 int maxShardDataChangeExecutorQueueSize, int maxShardDataChangeExecutorPoolSize,
31 int shardTransactionIdleTimeoutInMinutes) {
32 this.maxShardDataChangeListenerQueueSize = maxShardDataChangeListenerQueueSize;
33 this.maxShardDataChangeExecutorQueueSize = maxShardDataChangeExecutorQueueSize;
34 this.maxShardDataChangeExecutorPoolSize = maxShardDataChangeExecutorPoolSize;
35 this.shardTransactionIdleTimeoutInMinutes = shardTransactionIdleTimeoutInMinutes;
38 public int getMaxShardDataChangeListenerQueueSize() {
39 return maxShardDataChangeListenerQueueSize;
42 public int getMaxShardDataChangeExecutorQueueSize() {
43 return maxShardDataChangeExecutorQueueSize;
46 public int getMaxShardDataChangeExecutorPoolSize() {
47 return maxShardDataChangeExecutorPoolSize;
50 public int getShardTransactionIdleTimeoutInMinutes() {
51 return shardTransactionIdleTimeoutInMinutes;