Refactor: split api from SONA simple fabric
Change-Id: Icbdb10b730af29057097b14df8ddc377f4107853
diff --git a/apps/simplefabric/BUCK b/apps/simplefabric/BUCK
index 177b953..e181a98 100644
--- a/apps/simplefabric/BUCK
+++ b/apps/simplefabric/BUCK
@@ -1,32 +1,13 @@
-COMPILE_DEPS = [
- '//lib:CORE_DEPS',
- '//lib:JACKSON',
- '//lib:concurrent-trees',
- '//lib:javax.ws.rs-api',
- '//lib:org.apache.karaf.shell.console',
- '//cli:onos-cli',
- '//utils/rest:onlab-rest',
-]
-
BUNDLES = [
- '//apps/simplefabric:onos-apps-simplefabric',
+ '//apps/simplefabric/api:onos-apps-simplefabric-api',
+ '//apps/simplefabric/app:onos-apps-simplefabric-app',
]
-TEST_DEPS = [
- '//lib:TEST_ADAPTERS',
-]
-
-osgi_jar_with_tests (
- deps = COMPILE_DEPS,
- test_deps = TEST_DEPS,
- web_context = '/onos/v1/simplefabric',
-)
-
onos_app (
- title = 'SimpleFabric',
- category = 'Traffic Engineering',
- url = 'http://onosproject.org',
- included_bundles = BUNDLES,
- description = 'Simple Fabric application',
- required_apps = [ 'org.onosproject.openflow-base', 'org.onosproject.lldpprovider', 'org.onosproject.hostprovider' ],
-)
+ title = 'SONA SimpleFabric',
+ category = 'Traffic Engineering',
+ url = 'http://onosproject.org',
+ included_bundles = BUNDLES,
+ description = 'SONA Simple Fabric Application',
+ required_apps = [ 'org.onosproject.openflow-base', 'org.onosproject.lldpprovider', 'org.onosproject.hostprovider' ],
+)
\ No newline at end of file
diff --git a/apps/simplefabric/BUILD b/apps/simplefabric/BUILD
index 03e118d..3fabae0 100644
--- a/apps/simplefabric/BUILD
+++ b/apps/simplefabric/BUILD
@@ -1,26 +1,17 @@
-COMPILE_DEPS = CORE_DEPS + JACKSON + CLI + REST + [
- "@concurrent_trees//jar",
-]
-
BUNDLES = [
- "//apps/simplefabric:onos-apps-simplefabric",
+ "//apps/simplefabric/api:onos-apps-simplefabric-api",
+ "//apps/simplefabric/app:onos-apps-simplefabric-app",
]
-osgi_jar_with_tests(
- test_deps = TEST_ADAPTERS,
- web_context = "/onos/v1/simplefabric",
- deps = COMPILE_DEPS,
-)
-
onos_app(
category = "Traffic Engineering",
- description = "Simple Fabric application",
+ description = "SONA Simple Fabric Application",
included_bundles = BUNDLES,
required_apps = [
"org.onosproject.openflow-base",
"org.onosproject.lldpprovider",
"org.onosproject.hostprovider",
],
- title = "SimpleFabric",
+ title = "SONA SimpleFabric",
url = "http://onosproject.org",
)
diff --git a/apps/simplefabric/api/BUCK b/apps/simplefabric/api/BUCK
new file mode 100644
index 0000000..520bddf
--- /dev/null
+++ b/apps/simplefabric/api/BUCK
@@ -0,0 +1,16 @@
+COMPILE_DEPS = [
+ '//lib:CORE_DEPS',
+ '//lib:org.apache.karaf.shell.console',
+ '//cli:onos-cli',
+]
+
+TEST_DEPS = [
+ '//lib:TEST_ADAPTERS',
+ '//core/api:onos-api-tests',
+ '//core/common:onos-core-common-tests',
+]
+
+osgi_jar_with_tests (
+ deps = COMPILE_DEPS,
+ test_deps = TEST_DEPS,
+)
diff --git a/apps/simplefabric/api/BUILD b/apps/simplefabric/api/BUILD
new file mode 100644
index 0000000..b22d9f6
--- /dev/null
+++ b/apps/simplefabric/api/BUILD
@@ -0,0 +1,11 @@
+COMPILE_DEPS = CORE_DEPS + CLI
+
+TEST_DEPS = TEST_ADAPTERS + [
+ "//core/api:onos-api-tests",
+ "//core/common:onos-core-common-tests",
+]
+
+osgi_jar_with_tests(
+ test_deps = TEST_DEPS,
+ deps = COMPILE_DEPS,
+)
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/IpSubnet.java b/apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/IpSubnet.java
similarity index 97%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/IpSubnet.java
rename to apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/IpSubnet.java
index 596c659..d307e7f 100644
--- a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/IpSubnet.java
+++ b/apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/IpSubnet.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2017-present Open Networking Foundation
+ * Copyright 2018-present Open Networking Foundation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.onosproject.simplefabric;
+package org.onosproject.simplefabric.api;
import com.google.common.base.MoreObjects;
import org.onlab.packet.IpAddress;
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/L2Network.java b/apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/L2Network.java
similarity index 97%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/L2Network.java
rename to apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/L2Network.java
index 5579159..0b38f48 100644
--- a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/L2Network.java
+++ b/apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/L2Network.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2017-present Open Networking Foundation
+ * Copyright 2018-present Open Networking Foundation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package org.onosproject.simplefabric;
+package org.onosproject.simplefabric.api;
import com.google.common.base.MoreObjects;
import com.google.common.collect.ImmutableSet;
@@ -57,7 +57,7 @@
* @param l2Forward flag for l2Forward intents to be installed or not
* @param l2Broadcast flag for l2Broadcast intents to be installed or not
*/
- L2Network(String name, Collection<String> ifaceNames, EncapsulationType encapsulation,
+ public L2Network(String name, Collection<String> ifaceNames, EncapsulationType encapsulation,
boolean l2Forward, boolean l2Broadcast) {
this.name = name;
this.interfaceNames = Sets.newHashSet();
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/Route.java b/apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/Route.java
similarity index 97%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/Route.java
rename to apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/Route.java
index 8eabb95..a008193 100644
--- a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/Route.java
+++ b/apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/Route.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2016-present Open Networking Foundation
+ * Copyright 2018-present Open Networking Foundation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -18,7 +18,7 @@
* to remove dependency on onos.incubator.routing services, since 2017-08-09.
*/
-package org.onosproject.simplefabric;
+package org.onosproject.simplefabric.api;
import org.onlab.packet.IpAddress;
import org.onlab.packet.IpPrefix;
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricEvent.java b/apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/SimpleFabricEvent.java
similarity index 95%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricEvent.java
rename to apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/SimpleFabricEvent.java
index cac1276..aac465b 100644
--- a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricEvent.java
+++ b/apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/SimpleFabricEvent.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2017-present Open Networking Foundation
+ * Copyright 2018-present Open Networking Foundation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package org.onosproject.simplefabric;
+package org.onosproject.simplefabric.api;
import org.onosproject.event.AbstractEvent;
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricListener.java b/apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/SimpleFabricListener.java
similarity index 88%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricListener.java
rename to apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/SimpleFabricListener.java
index 726d578..25bf529 100644
--- a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricListener.java
+++ b/apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/SimpleFabricListener.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2017-present Open Networking Foundation
+ * Copyright 2018-present Open Networking Foundation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.onosproject.simplefabric;
+package org.onosproject.simplefabric.api;
import org.onosproject.event.EventListener;
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricService.java b/apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/SimpleFabricService.java
similarity index 98%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricService.java
rename to apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/SimpleFabricService.java
index be2bed3..18464dc 100644
--- a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricService.java
+++ b/apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/SimpleFabricService.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2017-present Open Networking Foundation
+ * Copyright 2018-present Open Networking Foundation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.onosproject.simplefabric;
+package org.onosproject.simplefabric.api;
import org.onlab.packet.IpAddress;
import org.onlab.packet.MacAddress;
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricListener.java b/apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/package-info.java
similarity index 67%
copy from apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricListener.java
copy to apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/package-info.java
index 726d578..a11519f 100644
--- a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricListener.java
+++ b/apps/simplefabric/api/src/main/java/org/onosproject/simplefabric/api/package-info.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2017-present Open Networking Foundation
+ * Copyright 2018-present Open Networking Foundation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -13,13 +13,8 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.onosproject.simplefabric;
-
-import org.onosproject.event.EventListener;
/**
- * Entity capable of receiving alarm related events.
+ * Simple fabric API package.
*/
-public interface SimpleFabricListener extends EventListener<SimpleFabricEvent> {
-}
-
+package org.onosproject.simplefabric.api;
\ No newline at end of file
diff --git a/apps/simplefabric/app/BUCK b/apps/simplefabric/app/BUCK
new file mode 100644
index 0000000..104aee1
--- /dev/null
+++ b/apps/simplefabric/app/BUCK
@@ -0,0 +1,23 @@
+COMPILE_DEPS = [
+ '//lib:CORE_DEPS',
+ '//lib:JACKSON',
+ '//lib:concurrent-trees',
+ '//lib:javax.ws.rs-api',
+ '//lib:org.apache.karaf.shell.console',
+ '//cli:onos-cli',
+ '//utils/rest:onlab-rest',
+ '//apps/simplefabric/api:onos-apps-simplefabric-api',
+]
+
+TEST_DEPS = [
+ '//lib:TEST_ADAPTERS',
+]
+
+osgi_jar_with_tests (
+ api_description = 'REST API for Simple Fabric',
+ api_package = 'org.onosproject.simplefabric.web',
+ api_title = 'Simple Fabric API',
+ deps = COMPILE_DEPS,
+ test_deps = TEST_DEPS,
+ web_context = '/onos/v1/simplefabric',
+)
\ No newline at end of file
diff --git a/apps/simplefabric/app/BUILD b/apps/simplefabric/app/BUILD
new file mode 100644
index 0000000..9d93d06
--- /dev/null
+++ b/apps/simplefabric/app/BUILD
@@ -0,0 +1,12 @@
+COMPILE_DEPS = CORE_DEPS + JACKSON + CLI + REST + [
+ "//apps/simplefabric/api:onos-apps-simplefabric-api",
+ "@concurrent_trees//jar",
+]
+
+osgi_jar_with_tests(
+ api_description = "REST API for Simple Fabric",
+ api_package = "org.onosproject.simplefabric.web",
+ api_title = "Simple Fabric API",
+ web_context = "/onos/v1/simplefabric",
+ deps = COMPILE_DEPS,
+)
diff --git a/apps/simplefabric/app.xml b/apps/simplefabric/app/app.xml
similarity index 100%
rename from apps/simplefabric/app.xml
rename to apps/simplefabric/app/app.xml
diff --git a/apps/simplefabric/features.xml b/apps/simplefabric/app/features.xml
similarity index 100%
rename from apps/simplefabric/features.xml
rename to apps/simplefabric/app/features.xml
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/RouteTools.java b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/RouteTools.java
similarity index 100%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/RouteTools.java
rename to apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/RouteTools.java
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricCommand.java b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricCommand.java
similarity index 97%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricCommand.java
rename to apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricCommand.java
index b515259..75db695 100644
--- a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricCommand.java
+++ b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricCommand.java
@@ -18,6 +18,7 @@
import org.apache.karaf.shell.commands.Argument;
import org.apache.karaf.shell.commands.Command;
import org.onosproject.cli.AbstractShellCommand;
+import org.onosproject.simplefabric.api.SimpleFabricService;
/**
* CLI to interact with the SIMPLE_FABRIC application.
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricCommandCompleter.java b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricCommandCompleter.java
similarity index 100%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricCommandCompleter.java
rename to apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricCommandCompleter.java
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricConfig.java b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricConfig.java
similarity index 97%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricConfig.java
rename to apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricConfig.java
index 7bae152..fada766 100644
--- a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricConfig.java
+++ b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricConfig.java
@@ -24,6 +24,9 @@
import org.onosproject.core.ApplicationId;
import org.onosproject.net.config.Config;
import org.onosproject.net.EncapsulationType;
+import org.onosproject.simplefabric.api.IpSubnet;
+import org.onosproject.simplefabric.api.L2Network;
+import org.onosproject.simplefabric.api.Route;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricL2Forward.java b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricL2Forward.java
similarity index 98%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricL2Forward.java
rename to apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricL2Forward.java
index a67ed1a..45a9fdd 100644
--- a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricL2Forward.java
+++ b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricL2Forward.java
@@ -46,6 +46,10 @@
import org.onosproject.net.intent.SinglePointToMultiPointIntent;
import org.onosproject.net.intent.constraint.EncapsulationConstraint;
import org.onosproject.net.intent.constraint.PartialFailureConstraint;
+import org.onosproject.simplefabric.api.L2Network;
+import org.onosproject.simplefabric.api.SimpleFabricEvent;
+import org.onosproject.simplefabric.api.SimpleFabricListener;
+import org.onosproject.simplefabric.api.SimpleFabricService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricManager.java b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricManager.java
similarity index 98%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricManager.java
rename to apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricManager.java
index 43686ab..445fb71 100644
--- a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricManager.java
+++ b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricManager.java
@@ -65,6 +65,12 @@
import org.onosproject.net.packet.PacketService;
import org.onosproject.net.packet.DefaultOutboundPacket;
import org.onosproject.net.packet.OutboundPacket;
+import org.onosproject.simplefabric.api.IpSubnet;
+import org.onosproject.simplefabric.api.L2Network;
+import org.onosproject.simplefabric.api.Route;
+import org.onosproject.simplefabric.api.SimpleFabricEvent;
+import org.onosproject.simplefabric.api.SimpleFabricListener;
+import org.onosproject.simplefabric.api.SimpleFabricService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricNeighbour.java b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricNeighbour.java
similarity index 97%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricNeighbour.java
rename to apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricNeighbour.java
index d796346..1b5330c 100644
--- a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricNeighbour.java
+++ b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricNeighbour.java
@@ -30,6 +30,10 @@
import org.onosproject.net.neighbour.NeighbourResolutionService;
import org.onosproject.net.Host;
import org.onosproject.net.host.HostService;
+import org.onosproject.simplefabric.api.L2Network;
+import org.onosproject.simplefabric.api.SimpleFabricEvent;
+import org.onosproject.simplefabric.api.SimpleFabricListener;
+import org.onosproject.simplefabric.api.SimpleFabricService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricReactiveRouting.java b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricReactiveRouting.java
similarity index 98%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricReactiveRouting.java
rename to apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricReactiveRouting.java
index e66d700..4f83ae3 100644
--- a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricReactiveRouting.java
+++ b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricReactiveRouting.java
@@ -70,6 +70,12 @@
import org.onosproject.net.packet.PacketPriority;
import org.onosproject.net.packet.PacketProcessor;
import org.onosproject.net.packet.PacketService;
+import org.onosproject.simplefabric.api.IpSubnet;
+import org.onosproject.simplefabric.api.L2Network;
+import org.onosproject.simplefabric.api.Route;
+import org.onosproject.simplefabric.api.SimpleFabricEvent;
+import org.onosproject.simplefabric.api.SimpleFabricListener;
+import org.onosproject.simplefabric.api.SimpleFabricService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricWebApplication.java b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricWebApplication.java
similarity index 100%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricWebApplication.java
rename to apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricWebApplication.java
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricWebResource.java b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricWebResource.java
similarity index 97%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricWebResource.java
rename to apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricWebResource.java
index f1e9af7..3274a3e 100644
--- a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/SimpleFabricWebResource.java
+++ b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/SimpleFabricWebResource.java
@@ -17,6 +17,7 @@
package org.onosproject.simplefabric;
import org.onosproject.rest.AbstractWebResource;
+import org.onosproject.simplefabric.api.SimpleFabricService;
import java.io.ByteArrayOutputStream;
import javax.ws.rs.GET;
diff --git a/apps/simplefabric/src/main/java/org/onosproject/simplefabric/package-info.java b/apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/package-info.java
similarity index 100%
rename from apps/simplefabric/src/main/java/org/onosproject/simplefabric/package-info.java
rename to apps/simplefabric/app/src/main/java/org/onosproject/simplefabric/package-info.java
diff --git a/apps/simplefabric/src/main/resources/OSGI-INF/blueprint/shell-config.xml b/apps/simplefabric/app/src/main/resources/OSGI-INF/blueprint/shell-config.xml
similarity index 100%
rename from apps/simplefabric/src/main/resources/OSGI-INF/blueprint/shell-config.xml
rename to apps/simplefabric/app/src/main/resources/OSGI-INF/blueprint/shell-config.xml
diff --git a/apps/simplefabric/src/main/webapp/WEB-INF/web.xml b/apps/simplefabric/app/src/main/webapp/WEB-INF/web.xml
similarity index 100%
rename from apps/simplefabric/src/main/webapp/WEB-INF/web.xml
rename to apps/simplefabric/app/src/main/webapp/WEB-INF/web.xml