Add BUCK for tenbi and tetunnel
1. Add BUCK for tenbi and tetunnel
2. Fix check style errors in tenbi
3. Fix a BUCK error in tetopology
Change-Id: I618bdd2a119cc6be3250cb3c3e9002fa4f5e4750
diff --git a/apps/tenbi/BUCK b/apps/tenbi/BUCK
new file mode 100644
index 0000000..30ed481
--- /dev/null
+++ b/apps/tenbi/BUCK
@@ -0,0 +1,18 @@
+BUNDLES = [
+ '//apps/tenbi/yangmodel:onos-apps-tenbi-yangmodel',
+ '//apps/tenbi/utils:onos-apps-tenbi-utils',
+ '//apps/tenbi/tunnel:onos-apps-tenbi-tunnel',
+ '//apps/tenbi/topology:onos-apps-tenbi-topology',
+]
+
+onos_app (
+ title = 'TE NBI',
+ category = 'ACTN APP',
+ url = 'http://onosproject.org',
+ included_bundles = BUNDLES,
+ description = 'TE YANG NBI.',
+ required_apps = [ 'org.onosproject.onos-app-tetopology',
+ 'org.onosproject.onos-app-tetunnel',
+ 'org.onosproject.onos-app-yms' ],
+)
+
diff --git a/apps/tenbi/topology/BUCK b/apps/tenbi/topology/BUCK
new file mode 100644
index 0000000..40e2be6
--- /dev/null
+++ b/apps/tenbi/topology/BUCK
@@ -0,0 +1,17 @@
+COMPILE_DEPS = [
+ '//lib:CORE_DEPS',
+ '//apps/tenbi/yangmodel:onos-apps-tenbi-yangmodel',
+ '//apps/tenbi/utils:onos-apps-tenbi-utils',
+ '//apps/tetopology/api:onos-apps-tetopology-api',
+ '//apps/yms/api:onos-apps-yms-api',
+]
+
+TEST_DEPS = [
+ '//lib:TEST_ADAPTERS',
+ '//utils/osgi:onlab-osgi-tests',
+]
+
+osgi_jar_with_tests (
+ deps = COMPILE_DEPS,
+ test_deps = TEST_DEPS,
+)
diff --git a/apps/tenbi/tunnel/BUCK b/apps/tenbi/tunnel/BUCK
new file mode 100644
index 0000000..57756ac
--- /dev/null
+++ b/apps/tenbi/tunnel/BUCK
@@ -0,0 +1,19 @@
+COMPILE_DEPS = [
+ '//lib:CORE_DEPS',
+ '//apps/tenbi/yangmodel:onos-apps-tenbi-yangmodel',
+ '//apps/tenbi/utils:onos-apps-tenbi-utils',
+ '//apps/tetopology/api:onos-apps-tetopology-api',
+ '//apps/tetunnel/api:onos-apps-tetunnel-api',
+ '//apps/yms/api:onos-apps-yms-api',
+ '//incubator/api:onos-incubator-api',
+]
+
+TEST_DEPS = [
+ '//lib:TEST_ADAPTERS',
+ '//utils/osgi:onlab-osgi-tests',
+]
+
+osgi_jar_with_tests (
+ deps = COMPILE_DEPS,
+ test_deps = TEST_DEPS,
+)
diff --git a/apps/tenbi/utils/BUCK b/apps/tenbi/utils/BUCK
new file mode 100644
index 0000000..aaf248d
--- /dev/null
+++ b/apps/tenbi/utils/BUCK
@@ -0,0 +1,16 @@
+COMPILE_DEPS = [
+ '//lib:CORE_DEPS',
+ '//apps/tenbi/yangmodel:onos-apps-tenbi-yangmodel',
+ '//apps/tetopology/api:onos-apps-tetopology-api',
+ '//apps/tetunnel/api:onos-apps-tetunnel-api',
+]
+
+TEST_DEPS = [
+ '//lib:TEST_ADAPTERS',
+ '//utils/osgi:onlab-osgi-tests',
+]
+
+osgi_jar_with_tests (
+ deps = COMPILE_DEPS,
+ test_deps = TEST_DEPS,
+)
diff --git a/apps/tenbi/utils/src/main/java/org/onosproject/teyang/utils/topology/NodeConverter.java b/apps/tenbi/utils/src/main/java/org/onosproject/teyang/utils/topology/NodeConverter.java
index 84f1351..4874af2 100644
--- a/apps/tenbi/utils/src/main/java/org/onosproject/teyang/utils/topology/NodeConverter.java
+++ b/apps/tenbi/utils/src/main/java/org/onosproject/teyang/utils/topology/NodeConverter.java
@@ -408,7 +408,6 @@
*
* @param yangNode Node in YANG model
* @param yangNetwork YANG network
- * @param yangNetwork Network node in YANG model
* @return TE subsystem node
*/
public static org.onosproject.tetopology.management.api.node.NetworkNode
diff --git a/apps/tenbi/utils/src/main/java/org/onosproject/teyang/utils/tunnel/BasicConverter.java b/apps/tenbi/utils/src/main/java/org/onosproject/teyang/utils/tunnel/BasicConverter.java
index 3b7ee37..f6e4898 100644
--- a/apps/tenbi/utils/src/main/java/org/onosproject/teyang/utils/tunnel/BasicConverter.java
+++ b/apps/tenbi/utils/src/main/java/org/onosproject/teyang/utils/tunnel/BasicConverter.java
@@ -19,7 +19,7 @@
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev20130715.ietfinettypes.IpAddress;
/**
- * Basic converter tools for ietf NBI & SBI.
+ * Basic converter tools for ietf NBI & SBI.
*/
public abstract class BasicConverter {
diff --git a/apps/tenbi/utils/src/main/java/org/onosproject/teyang/utils/tunnel/TunnelConverter.java b/apps/tenbi/utils/src/main/java/org/onosproject/teyang/utils/tunnel/TunnelConverter.java
index 30d42b0..e82ee64 100755
--- a/apps/tenbi/utils/src/main/java/org/onosproject/teyang/utils/tunnel/TunnelConverter.java
+++ b/apps/tenbi/utils/src/main/java/org/onosproject/teyang/utils/tunnel/TunnelConverter.java
@@ -32,27 +32,37 @@
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.DefaultTe;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.Te;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.pathparamsconfig.Type;
-import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.pathparamsconfig.type.DefaultDynamic;
-import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.pathparamsconfig.type.DefaultExplicit;
-import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.pathparamsconfig.type.explicit.DefaultExplicitRouteObjects;
-import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.pathparamsconfig.type.explicit.ExplicitRouteObjects;
+import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.pathparamsconfig.type
+ .DefaultDynamic;
+import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.pathparamsconfig.type
+ .DefaultExplicit;
+import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.pathparamsconfig.type
+ .explicit.DefaultExplicitRouteObjects;
+import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.pathparamsconfig.type
+ .explicit.ExplicitRouteObjects;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.tunnelproperties.Config;
-import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.tunnelproperties.DefaultPrimaryPaths;
+import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.tunnelproperties
+ .DefaultPrimaryPaths;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.tunnelproperties.DefaultState;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.tunnelproperties.PrimaryPaths;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.tunnelproperties.State;
-import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.tunnelsgrouping.DefaultTunnels;
+import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.tunnelsgrouping
+ .DefaultTunnels;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.tunnelsgrouping.Tunnels;
-import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.tunnelsgrouping.tunnels.DefaultTunnel;
-import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.tunnelsgrouping.tunnels.Tunnel;
+import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.tunnelsgrouping.tunnels
+ .DefaultTunnel;
+import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.rev20160705.ietfte.tunnelsgrouping.tunnels
+ .Tunnel;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes.LspProt1Forn;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes.LspProtBidir1To1;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes.LspProtReroute;
-import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes.LspProtRerouteExtra;
+import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes
+ .LspProtRerouteExtra;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes.LspProtType;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes.LspProtUnidir1To1;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes.LspProtUnprotected;
-import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes.PathSignalingRsvpte;
+import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes
+ .PathSignalingRsvpte;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes.PathSignalingSr;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes.RouteIncludeEro;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes.StateDown;
@@ -60,8 +70,10 @@
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes.TunnelP2Mp;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes.TunnelP2p;
import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes.TunnelType;
-import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes.explicitroutesubobject.type.DefaultUnnumberedLink;
-import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes.explicitroutesubobject.type.UnnumberedLink;
+import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes
+ .explicitroutesubobject.type.DefaultUnnumberedLink;
+import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.te.types.rev20160705.ietftetypes
+ .explicitroutesubobject.type.UnnumberedLink;
import org.slf4j.Logger;
import java.util.ArrayList;
@@ -224,7 +236,8 @@
* Converts a YANG TE tunnel defined in the YANG model to a specific TE
* tunnel defined in the TE tunnel APP.
*
- * @param tunnel yang tunnel object
+ * @param tunnel yang tunnel object
+ * @param topologyKey key of the TE topology to which this tunnel belongs
* @return default Te tunnel defined in TE tunnel APP
*/
public static DefaultTeTunnel yang2TeTunnel(org.onosproject.yang.gen.v1.
diff --git a/apps/tenbi/yangmodel/BUCK b/apps/tenbi/yangmodel/BUCK
index 9c47ca7..4422110 100644
--- a/apps/tenbi/yangmodel/BUCK
+++ b/apps/tenbi/yangmodel/BUCK
@@ -1,9 +1,10 @@
-COMPILE = [
- '//lib:guava',
+COMPILE_DEPS = [
+ '//lib:CORE_DEPS'
]
-#yang_library(
-# deps = COMPILE,
-# name = 'onos-app-tenbi-yangmodel',
-# srcs = glob(['src/main/**/*.yang']),
-#)
+yang_library(
+ deps = COMPILE_DEPS,
+ name = 'onos-apps-tenbi-yangmodel',
+ srcs = glob(['src/main/**/*.yang']),
+ visibility = [ 'PUBLIC' ],
+)