6febae33d3a2b5a0ef6f5e3877534cc7c3e065dc
[bgpcep.git] / config-loader / config-loader-impl / src / main / resources / org / opendaylight / blueprint / bgp-config-loader.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3   ~ Copyright (c) 2016 Cisco Systems, Inc. and others.  All rights reserved.
4   ~
5   ~ This program and the accompanying materials are made available under the
6   ~ terms of the Eclipse Public License v1.0 which accompanies this distribution,
7   ~ and is available at http://www.eclipse.org/legal/epl-v10.html
8   -->
9
10 <blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0" xmlns:odl="http://opendaylight.org/xmlns/blueprint/v1.0.0">
11     <odl:static-reference id="domSchemaService" interface="org.opendaylight.mdsal.dom.api.DOMSchemaService"/>
12     <odl:static-reference id="mappingCodec" interface="org.opendaylight.mdsal.binding.dom.codec.api.BindingNormalizedNodeSerializer"/>
13
14     <bean id="bgpFileWatcher" class="org.opendaylight.protocol.bgp.config.loader.impl.BGPFileWatcher"  destroy-method="close" />
15
16     <bean id="bgpConfigLoader" class="org.opendaylight.protocol.bgp.config.loader.impl.ConfigLoaderImpl"  destroy-method="close">
17         <argument>
18             <bean factory-ref="domSchemaService" factory-method="getGlobalContext"/>
19         </argument>
20         <argument ref="mappingCodec"/>
21         <argument>
22             <bean factory-ref="bgpFileWatcher" factory-method="getPathFile"/>
23         </argument>
24         <argument>
25             <bean factory-ref="bgpFileWatcher" factory-method="getWatchService"/>
26         </argument>
27     </bean>
28
29     <service ref="bgpConfigLoader" interface="org.opendaylight.protocol.bgp.config.loader.spi.ConfigLoader" odl:type="default"/>
30 </blueprint>