System ready integration for OFP
[openflowplugin.git] / openflowplugin-blueprint-config / src / main / resources / org / opendaylight / blueprint / openflowplugin.xml
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.1.0"
5            odl:use-default-for-reference-types="true">
6
7     <reference id="dataBroker" interface="org.opendaylight.controller.md.sal.binding.api.DataBroker" odl:type="pingpong"/>
8     <reference id="rpcRegistry" interface="org.opendaylight.controller.sal.binding.api.RpcProviderRegistry"/>
9     <reference id="notificationPublishService" interface="org.opendaylight.controller.md.sal.binding.api.NotificationPublishService"/>
10     <reference id="entityOwnershipService" interface="org.opendaylight.controller.md.sal.common.api.clustering.EntityOwnershipService"/>
11     <reference id="clusterSingletonServiceProvider" interface="org.opendaylight.mdsal.singleton.common.api.ClusterSingletonServiceProvider"/>
12     <reference id="diagStatusService" interface="org.opendaylight.infrautils.diagstatus.DiagStatusService" />
13     <reference id="systemReadyMonitor" interface="org.opendaylight.infrautils.ready.SystemReadyMonitor" />
14
15     <reference id="defaultSwitchConnProvider" interface="org.opendaylight.openflowjava.protocol.spi.connection.SwitchConnectionProvider"
16                odl:type="openflow-switch-connection-provider-default-impl"/>
17
18     <reference id="legacySwitchConnProvider" interface="org.opendaylight.openflowjava.protocol.spi.connection.SwitchConnectionProvider"
19                odl:type="openflow-switch-connection-provider-legacy-impl"/>
20
21     <reference id="openflowPluginProviderFactory"
22                interface="org.opendaylight.openflowplugin.api.openflow.OpenFlowPluginProviderFactory"/>
23
24     <reference id="configurationServiceFactory"
25                interface="org.opendaylight.openflowplugin.api.openflow.configuration.ConfigurationServiceFactory"/>
26
27     <reference id="mastershipChangeServiceManager"
28                interface="org.opendaylight.openflowplugin.api.openflow.mastership.MastershipChangeServiceManager"/>
29
30     <odl:clustered-app-config id="openflowProviderConfig"
31                               binding-class="org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.openflow.provider.config.rev160510.OpenflowProviderConfig"/>
32
33     <bean id="configurationService"
34           factory-ref="configurationServiceFactory"
35           factory-method="newInstance"
36           destroy-method="close">
37         <argument ref="openflowProviderConfig" />
38         <argument ref="blueprintBundleContext" />
39         <cm:managed-properties persistent-id="org.opendaylight.openflowplugin"
40                                update-strategy="component-managed"
41                                update-method="update"/>
42     </bean>
43
44     <bean id="ofPluginDiagstatusProvider"
45           class="org.opendaylight.openflowplugin.api.diagstatus.OpenflowPluginDiagStatusProvider">
46         <argument ref="diagStatusService"/>
47     </bean>
48
49     <service ref="ofPluginDiagstatusProvider" interface="org.opendaylight.infrautils.diagstatus.ServiceStatusProvider"/>
50
51     <service ref="configurationService" interface="org.opendaylight.openflowplugin.api.openflow.configuration.ConfigurationService"/>
52
53     <bean id="openflowPluginProvider"
54           factory-ref="openflowPluginProviderFactory"
55           factory-method="newInstance"
56           destroy-method="close">
57         <argument ref="configurationService"/>
58         <argument ref="dataBroker"/>
59         <argument ref="rpcRegistry"/>
60         <argument ref="notificationPublishService"/>
61         <argument ref="entityOwnershipService"/>
62         <argument>
63             <list>
64                 <ref component-id="defaultSwitchConnProvider"/>
65                 <ref component-id="legacySwitchConnProvider"/>
66             </list>
67         </argument>
68         <argument ref="clusterSingletonServiceProvider"/>
69         <argument ref="mastershipChangeServiceManager"/>
70         <argument ref="ofPluginDiagstatusProvider"/>
71         <argument ref="systemReadyMonitor"/>
72     </bean>
73
74     <service ref="openflowPluginProvider" odl:type="openflow-plugin-provider-impl">
75         <interfaces>
76             <value>org.opendaylight.openflowplugin.api.openflow.OpenFlowPluginProvider</value>
77             <value>org.opendaylight.openflowplugin.extension.api.OpenFlowPluginExtensionRegistratorProvider</value>
78         </interfaces>
79     </service>
80
81 </blueprint>