Merge "Integration of MDSAL into distribution"
authorEd Warnicke <eaw@cisco.com>
Mon, 26 Aug 2013 19:19:18 +0000 (19:19 +0000)
committerGerrit Code Review <gerrit@opendaylight.org>
Mon, 26 Aug 2013 19:19:18 +0000 (19:19 +0000)
opendaylight/commons/opendaylight/pom.xml
opendaylight/distribution/opendaylight/pom.xml
opendaylight/sal/yang-prototype/sal/sal-binding-broker-impl/src/main/java/org/opendaylight/controller/sal/binding/impl/utils/GeneratorUtils.xtend

index ff6b5a1..7edee85 100644 (file)
     <geminiweb.version>2.2.0.RELEASE</geminiweb.version>
     <checkstyle.version>2.10</checkstyle.version>
     <testvm.argLine>-Xmx1024m -XX:MaxPermSize=256m</testvm.argLine>
+    <yang.version>0.5.7-SNAPSHOT</yang.version>
+    <guava.version>14.0.1</guava.version>
+    <ietf-inet-types.version>2010.09.24-SNAPSHOT</ietf-inet-types.version>
+    <ietf-yang-types.version>2010.09.24-SNAPSHOT</ietf-yang-types.version>
+    <yang-ext.version>2013.09.07-SNAPSHOT</yang-ext.version>
+    <javassist.version>3.17.1-GA</javassist.version>
+    <sample-toaster.version>1.0-SNAPSHOT</sample-toaster.version>
   </properties>
 
   <pluginRepositories>
       <artifactId>jersey-json</artifactId>
       <version>${jersey.version}</version>
     </dependency>
+
+    <!-- yangtools -->
+
+    <dependency>
+      <groupId>org.opendaylight.yangtools</groupId>
+      <artifactId>yang-binding</artifactId>
+      <version>${yang.version}</version>
+    </dependency>
+    <dependency>
+      <groupId>org.opendaylight.yangtools</groupId>
+      <artifactId>yang-common</artifactId>
+      <version>${yang.version}</version>
+    </dependency>
+    <dependency>
+      <groupId>org.opendaylight.yangtools</groupId>
+      <artifactId>yang-data-api</artifactId>
+      <version>${yang.version}</version>
+    </dependency>
+    <dependency>
+      <groupId>org.opendaylight.yangtools</groupId>
+      <artifactId>yang-model-api</artifactId>
+      <version>${yang.version}</version>
+    </dependency>
+    <dependency>
+      <groupId>org.opendaylight.yangtools</groupId>
+      <artifactId>yang-data-util</artifactId>
+      <version>${yang.version}</version>
+    </dependency>
+
+    <!-- Models -->
+
+    <dependency>
+      <groupId>org.opendaylight.yangtools.model</groupId>
+      <artifactId>ietf-inet-types</artifactId>
+      <version>${ietf-inet-types.version}</version>
+    </dependency>
+    <dependency>
+      <groupId>org.opendaylight.yangtools.model</groupId>
+      <artifactId>ietf-yang-types</artifactId>
+      <version>${ietf-yang-types.version}</version>
+    </dependency>
+    <dependency>
+      <groupId>org.opendaylight.yangtools</groupId>
+      <artifactId>yang-ext</artifactId>
+      <version>${yang-ext.version}</version>
+    </dependency>
+
+    <!-- Other MDSAL dependencies -->
+
+    <dependency>
+      <groupId>com.google.guava</groupId>
+      <artifactId>guava</artifactId>
+      <version>${guava.version}</version>
+      <type>jar</type>
+    </dependency>
+    <dependency>
+      <groupId>org.javassist</groupId>
+      <artifactId>javassist</artifactId>
+      <version>${javassist.version}</version>
+    </dependency>
   </dependencies>
 </project>
index 1833b4a..abf508e 100644 (file)
@@ -5,10 +5,10 @@
   <prerequisites>
     <maven>3.0</maven>
   </prerequisites>
-
   <scm>
-    <connection>scm:git:https://git.opendaylight.org/gerrit/p/controller.git</connection>
+    <connection>scm:git:ssh://git.opendaylight.org:29418/controller.git</connection>
     <developerConnection>scm:git:ssh://git.opendaylight.org:29418/controller.git</developerConnection>
+    <url>https://wiki.opendaylight.org/view/OpenDaylight_Controller:Main</url>
   </scm>
   <parent>
     <groupId>org.opendaylight.controller</groupId>
@@ -67,6 +67,7 @@
     <module>../../../third-party/openflowj</module>
     <module>../../../third-party/net.sf.jung2</module>
     <module>../../../third-party/jersey-servlet</module>
+    <module>../../../third-party/commons/thirdparty</module>
 
     <!-- SAL bundles -->
     <module>../../sal/api</module>
@@ -78,6 +79,9 @@
     <module>../../sal/networkconfiguration/api</module>
     <module>../../sal/networkconfiguration/implementation</module>
 
+    <!-- MD-SAL bundles -->
+    <module>../../sal/yang-prototype</module>
+
     <!--  Web bundles -->
     <module>../../web/root</module>
     <module>../../web/flows</module>
     <module>../../samples/simpleforwarding</module>
     <module>../../samples/loadbalancer</module>
     <module>../../samples/northbound/loadbalancer</module>
+
+    <!-- Parents -->
     <module>../../commons/concepts</module>
     <module>../../commons/integrationtest</module>
     <module>../../commons/checkstyle</module>
     <module>../../commons/opendaylight</module>
+    <module>../../commons/parent</module>
   </modules>
 
   <build>
index e94c375..c888121 100644 (file)
@@ -8,6 +8,8 @@
 package org.opendaylight.controller.sal.binding.impl.utils
 
 import javassist.ClassPool
+import javassist.NotFoundException
+import javassist.LoaderClassPath
 
 class GeneratorUtils {
 
@@ -16,8 +18,13 @@ class GeneratorUtils {
     public static def generatedName(Class<?> cls, String suffix) {
         '''«PREFIX»«cls.package.name».«cls.simpleName»$«suffix»'''.toString()
     }
-    
-    public static def get(ClassPool pool,Class<?> cls) {
-        pool.get(cls.name);
+
+    public static def get(ClassPool pool, Class<?> cls) {
+        try {
+            return pool.get(cls.name)
+        } catch (NotFoundException e) {
+            pool.appendClassPath(new LoaderClassPath(cls.classLoader));
+            return pool.get(cls.name)
+        }
     }
 }

©2013 OpenDaylight, A Linux Foundation Collaborative Project. All Rights Reserved.
OpenDaylight is a registered trademark of The OpenDaylight Project, Inc.
Linux Foundation and OpenDaylight are registered trademarks of the Linux Foundation.
Linux is a registered trademark of Linus Torvalds.