0a493f336c116a85a80da0d5a5860a5060435f0b
[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
13     <reference id="defaultSwitchConnProvider" interface="org.opendaylight.openflowjava.protocol.spi.connection.SwitchConnectionProvider"
14                odl:type="openflow-switch-connection-provider-default-impl"/>
15
16     <reference id="legacySwitchConnProvider" interface="org.opendaylight.openflowjava.protocol.spi.connection.SwitchConnectionProvider"
17                odl:type="openflow-switch-connection-provider-legacy-impl"/>
18
19     <reference id="openflowPluginProviderFactory"
20                interface="org.opendaylight.openflowplugin.api.openflow.OpenFlowPluginProviderFactory"/>
21
22     <reference id="configurationServiceFactory"
23                interface="org.opendaylight.openflowplugin.api.openflow.configuration.ConfigurationServiceFactory"/>
24
25     <odl:clustered-app-config id="openflowProviderConfig"
26                               binding-class="org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.openflow.provider.config.rev160510.OpenflowProviderConfig"/>
27
28     <bean id="configurationService"
29           factory-ref="configurationServiceFactory"
30           factory-method="newInstance"
31           destroy-method="close">
32         <argument ref="openflowProviderConfig" />
33         <argument ref="blueprintBundleContext" />
34         <cm:managed-properties persistent-id="org.opendaylight.openflowplugin"
35                                update-strategy="component-managed"
36                                update-method="update"/>
37     </bean>
38
39     <service ref="configurationService" interface="org.opendaylight.openflowplugin.api.openflow.configuration.ConfigurationService"/>
40
41     <bean id="openflowPluginProvider"
42           factory-ref="openflowPluginProviderFactory"
43           factory-method="newInstance"
44           destroy-method="close">
45         <argument ref="configurationService"/>
46         <argument ref="dataBroker"/>
47         <argument ref="rpcRegistry"/>
48         <argument ref="notificationPublishService"/>
49         <argument ref="entityOwnershipService"/>
50         <argument>
51             <list>
52                 <ref component-id="defaultSwitchConnProvider"/>
53                 <ref component-id="legacySwitchConnProvider"/>
54             </list>
55         </argument>
56         <argument ref="clusterSingletonServiceProvider"/>
57     </bean>
58
59     <service ref="openflowPluginProvider" odl:type="openflow-plugin-provider-impl">
60         <interfaces>
61             <value>org.opendaylight.openflowplugin.api.openflow.OpenFlowPluginProvider</value>
62             <value>org.opendaylight.openflowplugin.extension.api.OpenFlowPluginExtensionRegistratorProvider</value>
63         </interfaces>
64     </service>
65
66 </blueprint>