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"/>
18 <reference id="datastoreSnapshotRestore" interface="org.opendaylight.controller.cluster.datastore.DatastoreSnapshotRestore"/>
20 <cm:cm-properties id="datastoreProps" persistent-id="org.opendaylight.controller.cluster.datastore"/>
22 <!-- Distributed Config Datastore -->
23 <bean id="introspectorConfig" factory-ref="introspectorFactory" factory-method="newInstance">
24 <argument type="org.opendaylight.mdsal.common.api.LogicalDatastoreType" value="CONFIGURATION"/>
27 <bean id="updaterConfig" class="org.opendaylight.controller.cluster.datastore.DatastoreContextPropertiesUpdater">
28 <cm:managed-properties persistent-id="org.opendaylight.controller.cluster.datastore" update-strategy="component-managed" update-method="update"/>
29 <argument ref="introspectorConfig"/>
30 <argument ref="datastoreProps"/>
33 <bean id="configDatastore" class="org.opendaylight.controller.cluster.datastore.DistributedDataStoreFactory"
34 factory-method="createInstance" destroy-method="close">
35 <argument ref="schemaService"/>
37 <bean factory-ref="introspectorConfig" factory-method="getContext" />
39 <argument ref="datastoreSnapshotRestore"/>
40 <argument ref="actorSystemProvider"/>
41 <argument ref="introspectorConfig"/>
42 <argument ref="updaterConfig"/>
45 <service ref="configDatastore" odl:type="distributed-config">
47 <value>org.opendaylight.controller.cluster.datastore.DistributedDataStoreInterface</value>
51 <!-- Distributed Operational Datastore -->
52 <bean id="fileModuleShardConfigProvider" class="org.opendaylight.controller.cluster.datastore.config.FileModuleShardConfigProvider">
53 <argument value="./configuration/initial/module-shards.conf"/>
54 <argument value="./configuration/initial/modules.conf"/>
57 <bean id="configurationImpl" class="org.opendaylight.controller.cluster.datastore.config.ConfigurationImpl">
58 <argument ref="fileModuleShardConfigProvider"/>
61 <bean id="introspectorOper" factory-ref="introspectorFactory" factory-method="newInstance">
62 <argument type="org.opendaylight.mdsal.common.api.LogicalDatastoreType" value="OPERATIONAL"/>
65 <bean id="updaterOper" class="org.opendaylight.controller.cluster.datastore.DatastoreContextPropertiesUpdater">
66 <cm:managed-properties persistent-id="org.opendaylight.controller.cluster.datastore" update-strategy="component-managed" update-method="update"/>
67 <argument ref="introspectorOper"/>
68 <argument ref="datastoreProps"/>
71 <bean id="operDatastore" class="org.opendaylight.controller.cluster.datastore.DistributedDataStoreFactory"
72 factory-method="createInstance" destroy-method="close">
73 <argument ref="schemaService"/>
75 <bean factory-ref="introspectorOper" factory-method="getContext" />
77 <argument ref="datastoreSnapshotRestore"/>
78 <argument ref="actorSystemProvider"/>
79 <argument ref="introspectorOper"/>
80 <argument ref="updaterOper"/>
81 <argument ref="configurationImpl" />
84 <service ref="operDatastore" odl:type="distributed-operational">
86 <value>org.opendaylight.controller.cluster.datastore.DistributedDataStoreInterface</value>
90 <!-- Concurrent DOMDataBroker -->
92 <bean id="listenableFutureExecutor" class="org.opendaylight.yangtools.util.concurrent.SpecialExecutors"
93 factory-method="newBlockingBoundedCachedThreadPool">
94 <argument value="${max-data-broker-future-callback-pool-size}"/>
95 <argument value="${max-data-broker-future-callback-queue-size}"/>
96 <argument value="CommitFutures"/>
98 <!-- We should use a more specific class -->
99 <bean factory-ref="operDatastore" factory-method="getClass"/>
103 <bean id="commitStatsTracker" class="org.opendaylight.yangtools.util.DurationStatisticsTracker"
104 factory-method="createConcurrent"/>
106 <bean id="clusteredDOMDataBroker" class="org.opendaylight.controller.cluster.databroker.ConcurrentDOMDataBroker"
107 destroy-method="close">
110 <entry key="CONFIGURATION" value-ref="configDatastore"/>
111 <entry key="OPERATIONAL" value-ref="operDatastore"/>
114 <argument ref="listenableFutureExecutor"/>
115 <argument ref="commitStatsTracker"/>
118 <service ref="clusteredDOMDataBroker" interface="org.opendaylight.mdsal.dom.api.DOMDataBroker"
121 <!-- JMX beans for the data broker -->
123 <bean id="commitStatsMXBean" class="org.opendaylight.controller.cluster.datastore.jmx.mbeans.CommitStatsMXBeanImpl"
124 init-method="register" destroy-method="unregister">
125 <argument ref="commitStatsTracker"/>
126 <argument value="DOMDataBroker"/>
129 <bean id="threadStatsMXBean" class="org.opendaylight.controller.md.sal.common.util.jmx.ThreadExecutorStatsMXBeanImpl"
130 factory-method="create" destroy-method="unregister">
131 <argument ref="listenableFutureExecutor"/>
132 <argument value="CommitFutureExecutorStats"/>
133 <argument value="DOMDataBroker"/>
136 <!-- CDS shard manager -->
137 <bean id="cdsNodeManager" class="org.opendaylight.controller.cluster.sharding.DistributedShardedDOMDataTree"
139 <argument ref="actorSystemProvider"/>
140 <argument ref="operDatastore"/>
141 <argument ref="configDatastore"/>
144 <service ref="cdsNodeManager" odl:type="default">
146 <value>org.opendaylight.mdsal.dom.api.DOMDataTreeShardingService</value>
147 <value>org.opendaylight.mdsal.dom.api.DOMDataTreeService</value>
148 <value>org.opendaylight.controller.cluster.sharding.DistributedShardFactory</value>