1 <?xml version="1.0" encoding="UTF-8"?>
2 <blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
3 xmlns:odl="http://opendaylight.org/xmlns/blueprint/v1.0.0"
4 xmlns:cm="http://aries.apache.org/blueprint/xmlns/blueprint-cm/v1.2.0">
6 <cm:property-placeholder persistent-id="org.opendaylight.controller.cluster.datastore.broker" update-strategy="none">
7 <cm:default-properties>
8 <cm:property name="max-data-broker-future-callback-queue-size" value="1000"/>
9 <cm:property name="max-data-broker-future-callback-pool-size" value="20"/>
10 </cm:default-properties>
11 </cm:property-placeholder>
13 <odl:static-reference id="schemaService" interface="org.opendaylight.mdsal.dom.api.DOMSchemaService" />
15 <!-- Datastore properties -->
16 <reference id="actorSystemProvider" interface="org.opendaylight.controller.cluster.ActorSystemProvider"/>
17 <reference id="introspectorFactory" interface="org.opendaylight.controller.cluster.datastore.DatastoreContextIntrospectorFactory"/>
19 <cm:cm-properties id="datastoreProps" persistent-id="org.opendaylight.controller.cluster.datastore"/>
21 <!-- Distributed Config Datastore -->
22 <bean id="datastoreSnapshotRestore" class="org.opendaylight.controller.cluster.datastore.DatastoreSnapshotRestore"
23 factory-method="instance">
24 <argument value="./clustered-datastore-restore"/>
27 <bean id="introspectorConfig" factory-ref="introspectorFactory" factory-method="newInstance">
28 <argument type="org.opendaylight.mdsal.common.api.LogicalDatastoreType" value="CONFIGURATION"/>
31 <bean id="updaterConfig" class="org.opendaylight.controller.cluster.datastore.DatastoreContextPropertiesUpdater">
32 <cm:managed-properties persistent-id="org.opendaylight.controller.cluster.datastore" update-strategy="component-managed" update-method="update"/>
33 <argument ref="introspectorConfig"/>
34 <argument ref="datastoreProps"/>
37 <bean id="configDatastore" class="org.opendaylight.controller.cluster.datastore.DistributedDataStoreFactory"
38 factory-method="createInstance" destroy-method="close">
39 <argument ref="schemaService"/>
41 <bean factory-ref="introspectorConfig" factory-method="getContext" />
43 <argument ref="datastoreSnapshotRestore"/>
44 <argument ref="actorSystemProvider"/>
45 <argument ref="introspectorConfig"/>
46 <argument ref="updaterConfig"/>
49 <service ref="configDatastore" odl:type="distributed-config">
51 <value>org.opendaylight.controller.cluster.datastore.DistributedDataStoreInterface</value>
55 <!-- Distributed Operational Datastore -->
56 <bean id="fileModuleShardConfigProvider" class="org.opendaylight.controller.cluster.datastore.config.FileModuleShardConfigProvider">
57 <argument value="./configuration/initial/module-shards.conf"/>
58 <argument value="./configuration/initial/modules.conf"/>
61 <bean id="configurationImpl" class="org.opendaylight.controller.cluster.datastore.config.ConfigurationImpl">
62 <argument ref="fileModuleShardConfigProvider"/>
65 <bean id="introspectorOper" factory-ref="introspectorFactory" factory-method="newInstance">
66 <argument type="org.opendaylight.mdsal.common.api.LogicalDatastoreType" value="OPERATIONAL"/>
69 <bean id="updaterOper" class="org.opendaylight.controller.cluster.datastore.DatastoreContextPropertiesUpdater">
70 <cm:managed-properties persistent-id="org.opendaylight.controller.cluster.datastore" update-strategy="component-managed" update-method="update"/>
71 <argument ref="introspectorOper"/>
72 <argument ref="datastoreProps"/>
75 <bean id="operDatastore" class="org.opendaylight.controller.cluster.datastore.DistributedDataStoreFactory"
76 factory-method="createInstance" destroy-method="close">
77 <argument ref="schemaService"/>
79 <bean factory-ref="introspectorOper" factory-method="getContext" />
81 <argument ref="datastoreSnapshotRestore"/>
82 <argument ref="actorSystemProvider"/>
83 <argument ref="introspectorOper"/>
84 <argument ref="updaterOper"/>
85 <argument ref="configurationImpl" />
88 <service ref="operDatastore" odl:type="distributed-operational">
90 <value>org.opendaylight.controller.cluster.datastore.DistributedDataStoreInterface</value>
94 <!-- Concurrent DOMDataBroker -->
96 <bean id="listenableFutureExecutor" class="org.opendaylight.yangtools.util.concurrent.SpecialExecutors"
97 factory-method="newBlockingBoundedCachedThreadPool">
98 <argument value="${max-data-broker-future-callback-pool-size}"/>
99 <argument value="${max-data-broker-future-callback-queue-size}"/>
100 <argument value="CommitFutures"/>
102 <!-- We should use a more specific class -->
103 <bean factory-ref="operDatastore" factory-method="getClass"/>
107 <bean id="commitStatsTracker" class="org.opendaylight.yangtools.util.DurationStatisticsTracker"
108 factory-method="createConcurrent"/>
110 <bean id="clusteredDOMDataBroker" class="org.opendaylight.controller.cluster.databroker.ConcurrentDOMDataBroker"
111 destroy-method="close">
114 <entry key="CONFIGURATION" value-ref="configDatastore"/>
115 <entry key="OPERATIONAL" value-ref="operDatastore"/>
118 <argument ref="listenableFutureExecutor"/>
119 <argument ref="commitStatsTracker"/>
122 <service ref="clusteredDOMDataBroker" interface="org.opendaylight.mdsal.dom.api.DOMDataBroker"
125 <!-- JMX beans for the data broker -->
127 <bean id="commitStatsMXBean" class="org.opendaylight.controller.cluster.datastore.jmx.mbeans.CommitStatsMXBeanImpl"
128 init-method="register" destroy-method="unregister">
129 <argument ref="commitStatsTracker"/>
130 <argument value="DOMDataBroker"/>
133 <bean id="threadStatsMXBean" class="org.opendaylight.controller.md.sal.common.util.jmx.ThreadExecutorStatsMXBeanImpl"
134 factory-method="create" destroy-method="unregister">
135 <argument ref="listenableFutureExecutor"/>
136 <argument value="CommitFutureExecutorStats"/>
137 <argument value="DOMDataBroker"/>
140 <!-- CDS shard manager -->
141 <bean id="cdsNodeManager" class="org.opendaylight.controller.cluster.sharding.DistributedShardedDOMDataTree"
143 <argument ref="actorSystemProvider"/>
144 <argument ref="operDatastore"/>
145 <argument ref="configDatastore"/>
148 <service ref="cdsNodeManager" odl:type="default">
150 <value>org.opendaylight.mdsal.dom.api.DOMDataTreeShardingService</value>
151 <value>org.opendaylight.mdsal.dom.api.DOMDataTreeService</value>
152 <value>org.opendaylight.controller.cluster.sharding.DistributedShardFactory</value>