From: Prem Sankar Date: Fri, 24 Apr 2015 17:45:21 +0000 (+0000) Subject: Merge "CHanger for interface mgr as provider, new commit." X-Git-Tag: release/lithium~65 X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?p=vpnservice.git;a=commitdiff_plain;h=d4a3b9f6268942ba8e22fadfda58fd9a950875aa;hp=7eaafc9c756f01ce75531b7d4077bbcd55bca1c7 Merge "CHanger for interface mgr as provider, new commit." --- diff --git a/features/src/main/features/features.xml b/features/src/main/features/features.xml index ffe2b953..5045cbea 100644 --- a/features/src/main/features/features.xml +++ b/features/src/main/features/features.xml @@ -19,7 +19,6 @@ and is available at http://www.eclipse.org/legal/epl-v10.html odl-openflowplugin-nsf-model mvn:org.opendaylight.vpnservice/model-bgp/{{VERSION}} mvn:org.opendaylight.vpnservice/vpnmanager-api/${vpnmanager.version} - mvn:org.opendaylight.vpnservice/interfacemgr-api/${interfacemgr.version} mvn:org.opendaylight.vpnservice/nexthopmgr-api/${nexthopmgr.version} mvn:org.opendaylight.vpnservice/idmanager-api/${idmanager.version} mvn:org.opendaylight.vpnservice/fibmanager-api/${fibmanager.version} @@ -31,6 +30,7 @@ and is available at http://www.eclipse.org/legal/epl-v10.html mvn:org.opendaylight.vpnservice/bgpmanager-api/${project.version} mvn:org.opendaylight.vpnservice/bgpmanager-impl/${project.version} mvn:org.opendaylight.vpnservice/vpnmanager-impl/${vpnmanager.version} + mvn:org.opendaylight.vpnservice/interfacemgr-api/${interfacemgr.version} mvn:org.opendaylight.vpnservice/interfacemgr-impl/${interfacemgr.version} mvn:org.opendaylight.vpnservice/nexthopmgr-impl/${nexthopmgr.version} mvn:org.opendaylight.vpnservice/idmanager-impl/${idmanager.version} diff --git a/interfacemgr/interfacemgr-api/pom.xml b/interfacemgr/interfacemgr-api/pom.xml index f1dce550..84f0c09c 100644 --- a/interfacemgr/interfacemgr-api/pom.xml +++ b/interfacemgr/interfacemgr-api/pom.xml @@ -8,9 +8,9 @@ and is available at http://www.eclipse.org/legal/epl-v10.html --> - org.opendaylight.yangtools - binding-parent - 0.7.0-SNAPSHOT + org.opendaylight.controller + config-parent + 0.3.0-SNAPSHOT @@ -28,7 +28,6 @@ and is available at http://www.eclipse.org/legal/epl-v10.html 0.7.0-SNAPSHOT 1.2.0-SNAPSHOT - org.opendaylight.yangtools @@ -71,4 +70,4 @@ and is available at http://www.eclipse.org/legal/epl-v10.html ${mdsal.version} - + \ No newline at end of file diff --git a/interfacemgr/interfacemgr-api/src/main/java/org/opendaylight/vpnservice/interfacemgr/interfaces/IInterfaceManager.java b/interfacemgr/interfacemgr-api/src/main/java/org/opendaylight/vpnservice/interfacemgr/interfaces/IInterfaceManager.java new file mode 100644 index 00000000..bda2d8c0 --- /dev/null +++ b/interfacemgr/interfacemgr-api/src/main/java/org/opendaylight/vpnservice/interfacemgr/interfaces/IInterfaceManager.java @@ -0,0 +1,7 @@ +package org.opendaylight.vpnservice.interfacemgr.interfaces; + +public interface IInterfaceManager { + + public void testApi(); + +} \ No newline at end of file diff --git a/interfacemgr/interfacemgr-api/src/main/yang/odl-interface.yang b/interfacemgr/interfacemgr-api/src/main/yang/odl-interface.yang index f1483dba..78816c8d 100644 --- a/interfacemgr/interfacemgr-api/src/main/yang/odl-interface.yang +++ b/interfacemgr/interfacemgr-api/src/main/yang/odl-interface.yang @@ -21,7 +21,11 @@ module odl-interface { } import opendaylight-inventory { - prefix inv; revision-date "2013-08-19"; + prefix inv; revision-date 2013-08-19; + } + + import config { + prefix config; revision-date 2013-04-05; } revision "2015-03-31" { @@ -61,6 +65,11 @@ module odl-interface { base tunnel-type-base; } + identity odl-interface { + base "config:service-type"; + config:java-class "org.opendaylight.vpnservice.interfacemgr.interfaces.IInterfaceManager"; + } + /* base/common properties */ augment "/if:interfaces/if:interface" { ext:augment-identifier "base-ids"; @@ -156,4 +165,3 @@ module odl-interface { } } - diff --git a/interfacemgr/interfacemgr-impl/src/main/config/default-config.xml b/interfacemgr/interfacemgr-impl/src/main/config/default-config.xml index 9404e2aa..e4fb6f45 100644 --- a/interfacemgr/interfacemgr-impl/src/main/config/default-config.xml +++ b/interfacemgr/interfacemgr-impl/src/main/config/default-config.xml @@ -9,6 +9,7 @@ and is available at http://www.eclipse.org/legal/epl-v10.html --> + urn:opendaylight:vpnservice:interfacemgr?module=odl-interface&revision=2015-03-31 urn:opendaylight:params:xml:ns:yang:interfacemgr:impl?module=interfacemgr-impl&revision=2015-03-25 urn:opendaylight:params:xml:ns:yang:controller:md:sal:binding?module=opendaylight-md-sal-binding&revision=2013-10-28 @@ -25,6 +26,15 @@ and is available at http://www.eclipse.org/legal/epl-v10.html + + + prefix:odl-interface + + interfacemgr-service + /modules/module[type='interfacemgr-impl'][name='interfacemgr-default'] + + + - + \ No newline at end of file diff --git a/interfacemgr/interfacemgr-impl/src/main/java/org/opendaylight/vpnservice/interfacemgr/InterfacemgrProvider.java b/interfacemgr/interfacemgr-impl/src/main/java/org/opendaylight/vpnservice/interfacemgr/InterfacemgrProvider.java index ad2a315d..ab30a083 100644 --- a/interfacemgr/interfacemgr-impl/src/main/java/org/opendaylight/vpnservice/interfacemgr/InterfacemgrProvider.java +++ b/interfacemgr/interfacemgr-impl/src/main/java/org/opendaylight/vpnservice/interfacemgr/InterfacemgrProvider.java @@ -12,11 +12,12 @@ import org.opendaylight.controller.sal.binding.api.BindingAwareBroker.ProviderCo import org.opendaylight.controller.sal.binding.api.BindingAwareProvider; import org.slf4j.Logger; import org.slf4j.LoggerFactory; +import org.opendaylight.vpnservice.interfacemgr.interfaces.IInterfaceManager; -public class InterfacemgrProvider implements BindingAwareProvider, AutoCloseable { +public class InterfacemgrProvider implements BindingAwareProvider, AutoCloseable, IInterfaceManager { private static final Logger LOG = LoggerFactory.getLogger(InterfacemgrProvider.class); - + private InterfaceManager interfaceManager; @Override @@ -36,4 +37,8 @@ public class InterfacemgrProvider implements BindingAwareProvider, AutoCloseable interfaceManager.close(); } -} + @Override + public void testApi() { + LOG.debug("Testing interface mgr api"); + } +} \ No newline at end of file diff --git a/interfacemgr/interfacemgr-impl/src/main/yang/interfacemgr-impl.yang b/interfacemgr/interfacemgr-impl/src/main/yang/interfacemgr-impl.yang index 774fdbcf..d53803fa 100644 --- a/interfacemgr/interfacemgr-impl/src/main/yang/interfacemgr-impl.yang +++ b/interfacemgr/interfacemgr-impl/src/main/yang/interfacemgr-impl.yang @@ -5,6 +5,7 @@ module interfacemgr-impl { import config { prefix config; revision-date 2013-04-05; } import opendaylight-md-sal-binding { prefix md-sal-binding; revision-date 2013-10-28;} + import odl-interface {prefix odlif; revision-date 2015-03-31;} description "Service definition for interfacemgr project"; @@ -16,6 +17,7 @@ module interfacemgr-impl { identity interfacemgr-impl { base config:module-type; + config:provided-service odlif:odl-interface; config:java-name-prefix InterfacemgrImpl; } @@ -32,4 +34,4 @@ module interfacemgr-impl { } } } -} +} \ No newline at end of file