Refactor: split api from single bundle for openstacknetworking

Change-Id: I8d94476d04bea1c0440e9735f519fdca3b1bd77d
diff --git a/apps/openstacknetworking/api/BUCK b/apps/openstacknetworking/api/BUCK
new file mode 100644
index 0000000..b502204
--- /dev/null
+++ b/apps/openstacknetworking/api/BUCK
@@ -0,0 +1,12 @@
+include_defs('//apps/openstacknetworking/openstack4j.bucklet')
+
+COMPILE_DEPS = [
+    '//lib:CORE_DEPS',
+    '//lib:openstack4j-core',
+]
+
+osgi_jar_with_tests (
+    deps = COMPILE_DEPS,
+
+    import_packages = INCLUDE_PACKAGES + ',' + EXCLUDE_PACKAGES  + ',' + ALL_PACKAGES,
+)
diff --git a/apps/openstacknetworking/api/pom.xml b/apps/openstacknetworking/api/pom.xml
new file mode 100644
index 0000000..ea606bd
--- /dev/null
+++ b/apps/openstacknetworking/api/pom.xml
@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  ~ 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.
+  ~ You may obtain a copy of the License at
+  ~
+  ~     http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing, software
+  ~ distributed under the License is distributed on an "AS IS" BASIS,
+  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  ~ See the License for the specific language governing permissions and
+  ~ limitations under the License.
+  -->
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.onosproject</groupId>
+        <artifactId>onos-apps-openstacknetworking</artifactId>
+        <version>1.13.0-SNAPSHOT</version>
+    </parent>
+
+    <artifactId>onos-apps-openstacknetworking-api</artifactId>
+    <packaging>bundle</packaging>
+
+    <description>SONA Openstack Networking API Application</description>
+
+    <dependencies>
+
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onos-api</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>org.pacesys</groupId>
+            <artifactId>openstack4j-core</artifactId>
+            <version>${openstack4j.version}</version>
+        </dependency>
+
+    </dependencies>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.felix</groupId>
+                <artifactId>maven-bundle-plugin</artifactId>
+                <extensions>true</extensions>
+                <configuration>
+                    <instructions>
+                        <Bundle-SymbolicName>
+                            ${project.groupId}.${project.artifactId}
+                        </Bundle-SymbolicName>
+                        <Import-Package>
+                            !org.openstack4j.*,
+                            *
+                        </Import-Package>
+                    </instructions>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
+
+</project>
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/Constants.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/Constants.java
new file mode 100644
index 0000000..8a7a2bb
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/Constants.java
@@ -0,0 +1,58 @@
+/*
+ * Copyright 2016-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onlab.packet.MacAddress;
+
+/**
+ * Provides constants used in OpenStackSwitching.
+ */
+public final class Constants {
+
+    private Constants() {
+    }
+
+    public static final String OPENSTACK_NETWORKING_APP_ID = "org.onosproject.openstacknetworking";
+
+    public static final String DEFAULT_GATEWAY_MAC_STR = "fe:00:00:00:00:02";
+    public static final MacAddress DEFAULT_GATEWAY_MAC = MacAddress.valueOf(DEFAULT_GATEWAY_MAC_STR);
+    public static final MacAddress DEFAULT_EXTERNAL_ROUTER_MAC = MacAddress.valueOf("fe:00:00:00:00:01");
+
+    public static final int PRIORITY_TUNNEL_TAG_RULE = 30000;
+    public static final int PRIORITY_FLOATING_INTERNAL = 42000;
+    public static final int PRIORITY_FLOATING_EXTERNAL = 41000;
+    public static final int PRIORITY_STATEFUL_SNAT_RULE = 40500;
+    public static final int PRIORITY_ICMP_RULE = 43000;
+    public static final int PRIORITY_INTERNAL_ROUTING_RULE = 28000;
+    public static final int PRIORITY_EXTERNAL_ROUTING_RULE = 25000;
+    public static final int PRIORITY_EXTERNAL_FLOATING_ROUTING_RULE = 26000;
+    public static final int PRIORITY_SNAT_RULE = 26000;
+    public static final int PRIORITY_SWITCHING_RULE = 30000;
+    public static final int PRIORITY_ADMIN_RULE = 32000;
+    public static final int PRIORITY_ACL_RULE = 31000;
+    public static final int PRIORITY_CT_HOOK_RULE = 30500;
+    public static final int PRIORITY_CT_RULE = 32000;
+    public static final int PRIORITY_CT_DROP_RULE = 32500;
+
+    public static final int SRC_VNI_TABLE = 0;
+    public static final int ACL_TABLE = 1;
+    public static final int CT_TABLE = 2;
+    public static final int JUMP_TABLE = 3;
+    public static final int ROUTING_TABLE = 4;
+    public static final int FORWARDING_TABLE = 5;
+    public static final int GW_COMMON_TABLE = 0;
+    public static final int ERROR_TABLE = 10;
+}
\ No newline at end of file
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/ExternalPeerRouter.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/ExternalPeerRouter.java
new file mode 100644
index 0000000..d42d337
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/ExternalPeerRouter.java
@@ -0,0 +1,46 @@
+/*
+ * 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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onlab.packet.IpAddress;
+import org.onlab.packet.MacAddress;
+import org.onlab.packet.VlanId;
+
+/**
+ * Representation of external peer router.
+ */
+public interface ExternalPeerRouter {
+    /**
+     * Returns external peer router ip address.
+     *
+     * @return ip address.
+     */
+    IpAddress externalPeerRouterIp();
+
+    /**
+     * Returns external peer router mac address.
+     *
+     * @return mac address
+     */
+    MacAddress externalPeerRouterMac();
+
+    /**
+     * Returns external peer router vlan id.
+     *
+     * @return vlan id
+     */
+    VlanId externalPeerRouterVlanId();
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/InstancePort.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/InstancePort.java
new file mode 100644
index 0000000..606e214
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/InstancePort.java
@@ -0,0 +1,69 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onlab.packet.IpAddress;
+import org.onlab.packet.MacAddress;
+import org.onosproject.net.DeviceId;
+import org.onosproject.net.PortNumber;
+
+/**
+ * Representation of virtual instance port.
+ */
+public interface InstancePort {
+
+    /**
+     * Returns the OpenStack network ID of the instance port.
+     *
+     * @return openstack network id
+     */
+    String networkId();
+
+    /**
+     * Returns the OpenStack port ID of a given host.
+     *
+     * @return openstack port id
+     */
+    String portId();
+
+    /**
+     * Returns the MAC address of the instance port.
+     *
+     * @return mac address
+     */
+    MacAddress macAddress();
+
+    /**
+     * Returns the IP address of the instance port.
+     *
+     * @return ip address
+     */
+    IpAddress ipAddress();
+
+    /**
+     * Returns the device ID of the instance port.
+     *
+     * @return device id
+     */
+    DeviceId deviceId();
+
+    /**
+     * Returns the port number of the instance port.
+     *
+     * @return port number
+     */
+    PortNumber portNumber();
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/InstancePortEvent.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/InstancePortEvent.java
new file mode 100644
index 0000000..547e41f
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/InstancePortEvent.java
@@ -0,0 +1,52 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onosproject.event.AbstractEvent;
+
+/**
+ * Describes virtual instance port event.
+ */
+public class InstancePortEvent extends AbstractEvent<InstancePortEvent.Type, InstancePort> {
+
+    public enum Type {
+
+        /**
+         * Signifies that a new instance port is detected.
+         */
+        OPENSTACK_INSTANCE_PORT_DETECTED,
+
+        /**
+         * Signifies that the instance port is updated.
+         */
+        OPENSTACK_INSTANCE_PORT_UPDATED,
+
+        /**
+         * Signifies that the instance port is disabled.
+         */
+        OPENSTACK_INSTANCE_PORT_VANISHED
+    }
+
+    /**
+     * Creates an event of a given type for the specified instance port.
+     *
+     * @param type     instance port event type
+     * @param instPort instance port
+     */
+    public InstancePortEvent(Type type, InstancePort instPort) {
+        super(type, instPort);
+    }
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/InstancePortListener.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/InstancePortListener.java
new file mode 100644
index 0000000..4a58f35
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/InstancePortListener.java
@@ -0,0 +1,24 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onosproject.event.EventListener;
+
+/**
+ * Listener for instance port event.
+ */
+public interface InstancePortListener extends EventListener<InstancePortEvent> {
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/InstancePortService.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/InstancePortService.java
new file mode 100644
index 0000000..f5ebe11
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/InstancePortService.java
@@ -0,0 +1,69 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onlab.packet.IpAddress;
+import org.onlab.packet.MacAddress;
+import org.onosproject.event.ListenerService;
+
+import java.util.Set;
+
+/**
+ * Service for interacting with the inventory of instance ports.
+ */
+public interface InstancePortService
+        extends ListenerService<InstancePortEvent, InstancePortListener> {
+
+    /**
+     * Returns instance port with the given MAC address.
+     *
+     * @param macAddress mac address
+     * @return instance port; null if not found
+     */
+    InstancePort instancePort(MacAddress macAddress);
+
+    /**
+     * Returns instance port with the given IP address in the given OpenStack network.
+     *
+     * @param ipAddress ip address
+     * @param osNetId   openstack network id
+     * @return instance port; null if not found
+     */
+    InstancePort instancePort(IpAddress ipAddress, String osNetId);
+
+    /**
+     * Returns instance port with the given openstack port ID.
+     *
+     * @param osPortId openstack port id
+     * @return instance port; null if not found
+     */
+    InstancePort instancePort(String osPortId);
+
+    /**
+     * Returns all instance ports.
+     *
+     * @return set of instance ports; empty list if no port exists
+     */
+    Set<InstancePort> instancePorts();
+
+    /**
+     * Returns instance ports in the given OpenStack network.
+     *
+     * @param osNetId openstack network
+     * @return set of instance ports; empty list if no port exists
+     */
+    Set<InstancePort> instancePorts(String osNetId);
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackFlowRuleService.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackFlowRuleService.java
new file mode 100644
index 0000000..5fc9b2b
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackFlowRuleService.java
@@ -0,0 +1,64 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+
+import org.onosproject.core.ApplicationId;
+import org.onosproject.net.DeviceId;
+import org.onosproject.net.flow.TrafficSelector;
+import org.onosproject.net.flow.TrafficTreatment;
+
+/**
+ * Service for setting flow rules.
+ *
+ */
+public interface OpenstackFlowRuleService {
+    /**
+     * Sets the flow rule.
+     *
+     * @param appId application ID
+     * @param deviceId  device ID
+     * @param selector matches of the flow rule
+     * @param treatment actions of the flow rule
+     * @param priority priority of the flow rule
+     * @param tableType table number to put the flow rule
+     * @param install add the rule if true, remove it otherwise
+     */
+    void setRule(ApplicationId appId,
+              DeviceId deviceId,
+              TrafficSelector selector,
+              TrafficTreatment treatment,
+              int priority,
+              int tableType,
+              boolean install);
+
+    /**
+     * Install table miss entry (drop rule) in the table.
+     *
+     * @param deviceId device ID
+     * @param table table number
+     */
+    void setUpTableMissEntry(DeviceId deviceId, int table);
+
+    /**
+     * Install a flor rule for transition from table A to table B.
+     *
+     * @param deviceId device Id
+     * @param fromTable table number of table A
+     * @param toTable table number of table B
+     */
+    void connectTables(DeviceId deviceId, int fromTable, int toTable);
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkAdminService.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkAdminService.java
new file mode 100644
index 0000000..86f66a4
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkAdminService.java
@@ -0,0 +1,94 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.openstack4j.model.network.Network;
+import org.openstack4j.model.network.Port;
+import org.openstack4j.model.network.Subnet;
+
+/**
+ * Service for administering the inventory of OpenStack network, subnet and port.
+ */
+public interface OpenstackNetworkAdminService {
+
+    /**
+     * Creates a network with the given information.
+     *
+     * @param network the new network
+     */
+    void createNetwork(Network network);
+
+    /**
+     * Updates the network with the given information.
+     *
+     * @param network the updated network
+     */
+    void updateNetwork(Network network);
+
+    /**
+     * Removes the network with the given network id.
+     *
+     * @param networkId network id
+     */
+    void removeNetwork(String networkId);
+
+    /**
+     * Creates a subnet with the given information.
+     *
+     * @param subnet the new subnet
+     */
+    void createSubnet(Subnet subnet);
+
+    /**
+     * Updates a subnet with the given information.
+     *
+     * @param subnet the updated subnet
+     */
+    void updateSubnet(Subnet subnet);
+
+    /**
+     * Removes the subnet with the given subnet id.
+     *
+     * @param subnetId subnet id
+     */
+    void removeSubnet(String subnetId);
+
+    /**
+     * Creates a port with the given information.
+     *
+     * @param port the new port
+     */
+    void createPort(Port port);
+
+    /**
+     * Updates the port with the given information.
+     *
+     * @param port the updated port
+     */
+    void updatePort(Port port);
+
+    /**
+     * Removes the port with the given port id.
+     *
+     * @param portId port id
+     */
+    void removePort(String portId);
+
+    /**
+     * Clears the existing network, subnet and port states.
+     */
+    void clear();
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkEvent.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkEvent.java
new file mode 100644
index 0000000..4f4892f
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkEvent.java
@@ -0,0 +1,189 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onlab.util.Tools;
+import org.onosproject.event.AbstractEvent;
+import org.openstack4j.model.network.Network;
+import org.openstack4j.model.network.Port;
+import org.openstack4j.model.network.Subnet;
+
+import static com.google.common.base.MoreObjects.toStringHelper;
+
+/**
+ * Describes OpenStack network service event.
+ */
+public class OpenstackNetworkEvent extends AbstractEvent<OpenstackNetworkEvent.Type, Network> {
+
+    private final Port port;
+    private final Subnet subnet;
+    private final String securityGroupId;
+
+    public enum Type {
+        /**
+         * Signifies that a new OpenStack network is created.
+         */
+        OPENSTACK_NETWORK_CREATED,
+
+        /**
+         * Signifies that the OpenStack network is updated.
+         */
+        OPENSTACK_NETWORK_UPDATED,
+
+        /**
+         * Signifies that the OpenStack network is removed.
+         */
+        OPENSTACK_NETWORK_REMOVED,
+
+        /**
+         * Signifies that a new OpenStack subnet is created.
+         */
+        OPENSTACK_SUBNET_CREATED,
+
+        /**
+         * Signifies that the OpenStack subnet is updated.
+         */
+        OPENSTACK_SUBNET_UPDATED,
+
+        /**
+         * Signifies that the OpenStack subnet is removed.
+         */
+        OPENSTACK_SUBNET_REMOVED,
+
+        /**
+         * Signifies that a new OpenStack port is created.
+         */
+        OPENSTACK_PORT_CREATED,
+
+        /**
+         * Signifies that the OpenStack port is updated.
+         */
+        OPENSTACK_PORT_UPDATED,
+
+        /**
+         * Signifies that the OpenStack port is removed.
+         */
+        OPENSTACK_PORT_REMOVED,
+
+        /**
+         * Signifies that the OpenStack security group rule is added to a specific port.
+         */
+        OPENSTACK_PORT_SECURITY_GROUP_ADDED,
+
+        /**
+         * Signifies that the OpenStack security group rule is removed from a specific port.
+         */
+        OPENSTACK_PORT_SECURITY_GROUP_REMOVED
+    }
+
+    /**
+     * Creates an event of a given type for the specified network and the current time.
+     * @param type    openstack network event type
+     * @param network openstack network
+     */
+    public OpenstackNetworkEvent(Type type, Network network) {
+        super(type, network);
+        this.port = null;
+        this.subnet = null;
+        this.securityGroupId = null;
+    }
+
+    /**
+     * Creates an event of a given type for the specified network, port and the
+     * current time.
+     *
+     * @param type    openstack network event type
+     * @param network openstack network
+     * @param port    openstack port
+     */
+    public OpenstackNetworkEvent(Type type, Network network, Port port) {
+        super(type, network);
+        this.port = port;
+        this.subnet = null;
+        this.securityGroupId = null;
+    }
+
+    /**
+     * Creates an event of a given type for the specified network, subnet and the
+     * current time.
+     *
+     * @param type    openstack network event type
+     * @param network openstack network
+     * @param subnet  openstack subnet
+     */
+    public OpenstackNetworkEvent(Type type, Network network, Subnet subnet) {
+        super(type, network);
+        this.port = null;
+        this.subnet = subnet;
+        this.securityGroupId = null;
+    }
+
+    /**
+     * Creates an event of a given type for the specified port and security groups.
+     *
+     * @param type openstack network event type
+     * @param port openstack port
+     * @param securityGroupId openstack security group
+     */
+    public OpenstackNetworkEvent(Type type, Port port, String securityGroupId) {
+        super(type, null);
+        this.port = port;
+        this.subnet = null;
+        this.securityGroupId = securityGroupId;
+    }
+
+    /**
+     * Returns the port of the network event.
+     *
+     * @return openstack port; null if the event is not port specific
+     */
+    public Port port() {
+        return port;
+    }
+
+    /**
+     * Returns the subnet of the network event.
+     *
+     * @return openstack subnet; null if the event is not subnet specific
+     */
+    public Subnet subnet() {
+        return subnet;
+    }
+
+    /**
+     * Returns the security group rule IDs updated.
+     *
+     * @return openstack security group
+     */
+    public String securityGroupId() {
+        return securityGroupId;
+    }
+
+    @Override
+    public String toString() {
+        if (port == null && subnet == null) {
+            return super.toString();
+        }
+        return toStringHelper(this)
+                .add("time", Tools.defaultOffsetDataTime(time()))
+                .add("type", type())
+                .add("network", subject())
+                .add("port", port)
+                .add("subnet", subnet)
+                .add("security group", securityGroupId())
+                .toString();
+    }
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkListener.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkListener.java
new file mode 100644
index 0000000..4002339
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkListener.java
@@ -0,0 +1,24 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onosproject.event.EventListener;
+
+/**
+ * Listener for OpenStack network event.
+ */
+public interface OpenstackNetworkListener extends EventListener<OpenstackNetworkEvent> {
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkService.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkService.java
new file mode 100644
index 0000000..2974c47
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkService.java
@@ -0,0 +1,174 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onlab.packet.IpAddress;
+import org.onlab.packet.MacAddress;
+import org.onlab.packet.VlanId;
+import org.onosproject.event.ListenerService;
+import org.openstack4j.model.network.ExternalGateway;
+import org.openstack4j.model.network.Network;
+import org.openstack4j.model.network.Port;
+import org.openstack4j.model.network.Router;
+import org.openstack4j.model.network.Subnet;
+
+import java.util.Set;
+
+/**
+ * Service for interacting with the inventory of OpenStack network and port.
+ */
+public interface OpenstackNetworkService
+        extends ListenerService<OpenstackNetworkEvent, OpenstackNetworkListener> {
+    /**
+     * Returns the network with the supplied network ID.
+     *
+     * @param networkId network id
+     * @return openstack network
+     */
+    Network network(String networkId);
+
+    /**
+     * Returns all networks registered in the service.
+     *
+     * @return set of networks
+     */
+    Set<Network> networks();
+
+    /**
+     * Returns the subnet with the supplied subnet ID.
+     *
+     * @param subnetId subnet id
+     * @return subnet
+     */
+    Subnet subnet(String subnetId);
+
+    /**
+     * Returns all subnets registered in the service.
+     *
+     * @return set of subnet
+     */
+    Set<Subnet> subnets();
+
+    /**
+     * Returns all subnets associated with the supplied network.
+     *
+     * @param networkId network id
+     * @return set of subnet
+     */
+    Set<Subnet> subnets(String networkId);
+
+    /**
+     * Returns the OpenStack port with the supplied port ID.
+     *
+     * @param portId openstack port id
+     * @return openstack port
+     */
+    Port port(String portId);
+
+    /**
+     * Returns the OpenStack port with the supplied ONOS port.
+     *
+     * @param port onos port
+     * @return openstack port
+     */
+    Port port(org.onosproject.net.Port port);
+
+    /**
+     * Returns all OpenStack ports registered in the service.
+     *
+     * @return set of ports
+     */
+    Set<Port> ports();
+
+    /**
+     * Returns all OpenStack ports associated with supplied network.
+     *
+     * @param networkId network id
+     * @return set of ports
+     */
+    Set<Port> ports(String networkId);
+
+    /**
+     * Derives external router mac address with supplied external gateway.
+     *
+     * @param externalGateway external gateway information
+     * @param router router which owns externalGateway
+     */
+    void deriveExternalPeerRouterMac(ExternalGateway externalGateway, Router router);
+
+    /**
+     * Deletes external router with supplied external gateway.
+     *
+     * @param externalGateway external gateway information
+     */
+    void deleteExternalPeerRouter(ExternalGateway externalGateway);
+
+    /**
+     * Deletes external router with supplied ip address.
+     *
+     * @param ipAddress ip address
+     */
+    void deleteExternalPeerRouter(String ipAddress);
+
+    /**
+     * Updates external router mac address with supplied ip address.
+     *
+     * @param ipAddress ip address
+     * @param macAddress mac address
+     */
+    void updateExternalPeerRouterMac(IpAddress ipAddress, MacAddress macAddress);
+
+    /**
+     * Updates external router vlan id with supplied ip address.
+     *
+     * @param ipAddress ip address
+     * @param vlanId vlan id
+     */
+    void updateExternalPeerRouterVlan(IpAddress ipAddress, VlanId vlanId);
+
+    /**
+     * Updates external router ith supplied ip address, mac address, vlan id.
+     *
+     * @param ipAddress ip address
+     * @param macAddress mac address
+     * @param vlanId vlan id
+     */
+    void updateExternalPeerRouter(IpAddress ipAddress, MacAddress macAddress, VlanId vlanId);
+
+    /**
+     * Returns external router mac with supplied external gateway.
+     *
+     * @param externalGateway external gateway information
+     * @return mac address
+     */
+    MacAddress externalPeerRouterMac(ExternalGateway externalGateway);
+
+    /**
+     * Returns external peer router with supplied ip address.
+     *
+     * @param ipAddress ip address
+     * @return external peer router
+     */
+    ExternalPeerRouter externalPeerRouter(IpAddress ipAddress);
+
+    /**
+     * Returns external peer router list.
+     *
+     * @return external peer router list
+     */
+    Set<ExternalPeerRouter> externalPeerRouters();
+
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkStore.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkStore.java
new file mode 100644
index 0000000..a584044
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkStore.java
@@ -0,0 +1,146 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onosproject.store.Store;
+import org.openstack4j.model.network.Network;
+import org.openstack4j.model.network.Port;
+import org.openstack4j.model.network.Subnet;
+
+import java.util.Set;
+
+/**
+ * Manages inventory of OpenStack network states; not intended for direct use.
+ */
+public interface OpenstackNetworkStore
+        extends Store<OpenstackNetworkEvent, OpenstackNetworkStoreDelegate> {
+
+    /**
+     * Creates the new network.
+     *
+     * @param network openstack network
+     */
+    void createNetwork(Network network);
+
+    /**
+     * Updates the network.
+     *
+     * @param network openstack network
+     */
+    void updateNetwork(Network network);
+
+    /**
+     * Removes the network with the given network id.
+     *
+     * @param networkId network id
+     * @return removed openstack network; null if failed
+     */
+    Network removeNetwork(String networkId);
+
+    /**
+     * Returns the network with the given network id.
+     *
+     * @param networkId network id
+     * @return network; null if not found
+     */
+    Network network(String networkId);
+
+    /**
+     * Returns all networks.
+     *
+     * @return set of networks
+     */
+    Set<Network> networks();
+
+    /**
+     * Creates a subnet with the given information.
+     *
+     * @param subnet the new subnet
+     */
+    void createSubnet(Subnet subnet);
+
+    /**
+     * Updates a subnet with the given information.
+     *
+     * @param subnet the updated subnet
+     */
+    void updateSubnet(Subnet subnet);
+
+    /**
+     * Removes the subnet with the given subnet id.
+     *
+     * @param subnetId subnet id
+     * @return removed subnet; null if failed
+     */
+    Subnet removeSubnet(String subnetId);
+
+    /**
+     * Returns the subnet with the supplied subnet ID.
+     *
+     * @param subnetId subnet id
+     * @return subnet
+     */
+    Subnet subnet(String subnetId);
+
+    /**
+     * Returns all subnets registered in the service.
+     *
+     * @return set of subnet
+     */
+    Set<Subnet> subnets();
+
+    /**
+     * Creates the new port.
+     *
+     * @param port the new port
+     */
+    void createPort(Port port);
+
+    /**
+     * Updates the port.
+     *
+     * @param port port
+     */
+    void updatePort(Port port);
+
+    /**
+     * Removes the port.
+     *
+     * @param portId port id
+     * @return removed port; null if failed
+     */
+    Port removePort(String portId);
+
+    /**
+     * Returns the port with the given port id.
+     *
+     * @param portId port id
+     * @return port
+     */
+    Port port(String portId);
+
+    /**
+     * Returns all ports.
+     *
+     * @return set of ports
+     */
+    Set<Port> ports();
+
+    /**
+     * Removes the existing network and ports.
+     */
+    void clear();
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkStoreDelegate.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkStoreDelegate.java
new file mode 100644
index 0000000..06f67ff
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackNetworkStoreDelegate.java
@@ -0,0 +1,24 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onosproject.store.StoreDelegate;
+
+/**
+ * OpenStack network store delegate abstraction.
+ */
+public interface OpenstackNetworkStoreDelegate extends StoreDelegate<OpenstackNetworkEvent> {
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterAdminService.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterAdminService.java
new file mode 100644
index 0000000..8742079
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterAdminService.java
@@ -0,0 +1,95 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.openstack4j.model.network.NetFloatingIP;
+import org.openstack4j.model.network.Router;
+import org.openstack4j.model.network.RouterInterface;
+
+/**
+ * Service for administering the inventory of OpenStack router and floating IP.
+ */
+public interface OpenstackRouterAdminService {
+
+    /**
+     * Creates a router with the given information.
+     *
+     * @param osRouter the new router
+     */
+    void createRouter(Router osRouter);
+
+    /**
+     * Updates the router with the given information.
+     *
+     * @param osRouter updated router
+     */
+    void updateRouter(Router osRouter);
+
+    /**
+     * Removes the router with the given router ID.
+     *
+     * @param osRouterId router id
+     */
+    void removeRouter(String osRouterId);
+
+    // TODO fix the logic adding a router interface to a router
+    /**
+     * Adds a new interface to the router.
+     *
+     * @param osRouterIface openstack router interface
+     */
+    void addRouterInterface(RouterInterface osRouterIface);
+
+    /**
+     * Updates the router interface.
+     *
+     * @param osRouterIface openstack router interface
+     */
+    void updateRouterInterface(RouterInterface osRouterIface);
+
+    /**
+     * Removes the router interface.
+     *
+     * @param osRouterIfaceId openstack router interface id
+     */
+    void removeRouterInterface(String osRouterIfaceId);
+
+    /**
+     * Creates a floating IP with the given information.
+     *
+     * @param floatingIP the new floating ip
+     */
+    void createFloatingIp(NetFloatingIP floatingIP);
+
+    /**
+     * Updates the floating IP with the given information.
+     *
+     * @param floatingIP the updated floating ip
+     */
+    void updateFloatingIp(NetFloatingIP floatingIP);
+
+    /**
+     * Removes the floating IP with the given floating IP ID.
+     *
+     * @param floatingIpId floating ip id
+     */
+    void removeFloatingIp(String floatingIpId);
+
+    /**
+     * Clears the existing routers and floating IPs.
+     */
+    void clear();
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterEvent.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterEvent.java
new file mode 100644
index 0000000..ba15cd0
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterEvent.java
@@ -0,0 +1,240 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onlab.util.Tools;
+import org.onosproject.event.AbstractEvent;
+import org.openstack4j.model.network.ExternalGateway;
+import org.openstack4j.model.network.NetFloatingIP;
+import org.openstack4j.model.network.Router;
+import org.openstack4j.model.network.RouterInterface;
+
+import static com.google.common.base.MoreObjects.toStringHelper;
+
+/**
+ * Describes OpenStack router service events.
+ */
+public class OpenstackRouterEvent extends AbstractEvent<OpenstackRouterEvent.Type, Router> {
+
+    private final ExternalGateway exGateway;
+    private final RouterInterface routerIface;
+    private final NetFloatingIP floatingIP;
+    private final String portId;
+
+    public enum Type {
+
+        /**
+         * Signifies that a new OpenStack router is created.
+         */
+        OPENSTACK_ROUTER_CREATED,
+
+        /**
+         * Signifies that the OpenStack router is updated.
+         */
+        OPENSTACK_ROUTER_UPDATED,
+
+        /**
+         * Signifies that the OpenStack router is removed.
+         */
+        OPENSTACK_ROUTER_REMOVED,
+
+        /**
+         * Signifies that the external gateway is added to the router.
+         */
+        OPENSTACK_ROUTER_GATEWAY_ADDED,
+
+        /**
+         * Signifies that the external gateway is removed from the router.
+         */
+        OPENSTACK_ROUTER_GATEWAY_REMOVED,
+
+        /**
+         * Signifies that the OpenStack router interface is added.
+         */
+        OPENSTACK_ROUTER_INTERFACE_ADDED,
+
+        /**
+         * Signifies that the OpenStack router interface is updated.
+         */
+        OPENSTACK_ROUTER_INTERFACE_UPDATED,
+
+        /**
+         * Signifies that the OpenStack router interface is removed.
+         */
+        OPENSTACK_ROUTER_INTERFACE_REMOVED,
+
+        /**
+         * Signifies that a new floating IP is created.
+         */
+        OPENSTACK_FLOATING_IP_CREATED,
+
+        /**
+         * Signifies that the floating IP is updated.
+         */
+        OPENSTACK_FLOATING_IP_UPDATED,
+
+        /**
+         * Signifies that the floating IP is removed.
+         */
+        OPENSTACK_FLOATING_IP_REMOVED,
+
+        /**
+         * Signifies that the floating IP is associated to a fixed IP.
+         */
+        OPENSTACK_FLOATING_IP_ASSOCIATED,
+
+        /**
+         * Signifies that the floating IP disassociated from the fixed IP.
+         */
+        OPENSTACK_FLOATING_IP_DISASSOCIATED
+    }
+
+    /**
+     * Creates an event of a given type for the specified router and the current time.
+     *
+     * @param type   openstack router event type
+     * @param osRouter openstack router
+     */
+    public OpenstackRouterEvent(Type type, Router osRouter) {
+        super(type, osRouter);
+        this.exGateway = null;
+        this.routerIface = null;
+        this.floatingIP = null;
+        this.portId = null;
+    }
+
+    /**
+     * Creates an event of a given type for the specified router, external gateway and
+     * the current time.
+     *
+     * @param type      openstack router event type
+     * @param osRouter  openstack router
+     * @param exGateway openstack router external gateway
+     */
+    public OpenstackRouterEvent(Type type, Router osRouter, ExternalGateway exGateway) {
+        super(type, osRouter);
+        this.exGateway = exGateway;
+        this.routerIface = null;
+        this.floatingIP = null;
+        this.portId = null;
+    }
+
+    /**
+     * Creates an event of a given type for the specified router, floating IP and
+     * the current time.
+     *
+     * @param type          openstack router event type
+     * @param osRouter      openstack router
+     * @param osRouterIface openstack router interface
+     */
+    public OpenstackRouterEvent(Type type, Router osRouter, RouterInterface osRouterIface) {
+        super(type, osRouter);
+        this.exGateway = null;
+        this.routerIface = osRouterIface;
+        this.floatingIP = null;
+        this.portId = null;
+    }
+
+    /**
+     * Creates an event of a given type for the specified router, floating IP and
+     * the current time.
+     *
+     * @param type       openstack router event type
+     * @param router     openstack router
+     * @param floatingIP openstack floating ip
+     */
+    public OpenstackRouterEvent(Type type, Router router, NetFloatingIP floatingIP) {
+        super(type, router);
+        this.exGateway = null;
+        this.routerIface = null;
+        this.floatingIP = floatingIP;
+        this.portId = null;
+    }
+
+    /**
+     * Creates an event of a given type for the specified router, floating IP,
+     * associated OpenStack port ID and the current time.
+     *
+     * @param type       openstack router event type
+     * @param router     openstack router
+     * @param floatingIP openstack floating ip
+     * @param portId     associated openstack port id
+     */
+    public OpenstackRouterEvent(Type type, Router router, NetFloatingIP floatingIP,
+                                String portId) {
+        super(type, router);
+        this.exGateway = null;
+        this.routerIface = null;
+        this.floatingIP = floatingIP;
+        this.portId = portId;
+    }
+
+    /**
+     * Returns the router external gateway object of the router event.
+     *
+     * @return openstack router external gateway; null if the event is not
+     * relevant to the router external gateway
+     */
+    public ExternalGateway externalGateway() {
+        return exGateway;
+    }
+
+    /**
+     * Returns the router interface object of the router event.
+     *
+     * @return openstack router interface; null if the event is not relevant to
+     * the router interface
+     */
+    public RouterInterface routerIface() {
+        return routerIface;
+    }
+
+    /**
+     * Returns the floating IP of the router event.
+     *
+     * @return openstack floating ip; null if the event is not relevant to
+     * the floating ip
+     */
+    public NetFloatingIP floatingIp() {
+        return floatingIP;
+    }
+
+    /**
+     * Returns the associated port ID of the floating IP.
+     *
+     * @return openstack port id; null if the event is not relevant to the
+     * floating ip
+     */
+    public String portId() {
+        return portId;
+    }
+
+    @Override
+    public String toString() {
+        if (floatingIP == null) {
+            return super.toString();
+        }
+        return toStringHelper(this)
+                .add("time", Tools.defaultOffsetDataTime(time()))
+                .add("type", type())
+                .add("router", subject())
+                .add("externalGateway", exGateway)
+                .add("routerIface", routerIface)
+                .add("floatingIp", floatingIP)
+                .add("portId", portId)
+                .toString();
+    }
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterListener.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterListener.java
new file mode 100644
index 0000000..423bdb4
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterListener.java
@@ -0,0 +1,24 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onosproject.event.EventListener;
+
+/**
+ * Listener for OpenStack router event.
+ */
+public interface OpenstackRouterListener extends EventListener<OpenstackRouterEvent> {
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterService.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterService.java
new file mode 100644
index 0000000..a1a8d30
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterService.java
@@ -0,0 +1,90 @@
+/*
+ * Copyright 2016-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onosproject.event.ListenerService;
+import org.openstack4j.model.network.NetFloatingIP;
+import org.openstack4j.model.network.Router;
+import org.openstack4j.model.network.RouterInterface;
+
+import java.util.Set;
+
+/**
+ * Handles router update requests from OpenStack.
+ */
+public interface OpenstackRouterService
+        extends ListenerService<OpenstackRouterEvent, OpenstackRouterListener> {
+
+    /**
+     * Returns the router with the supplied router ID.
+     *
+     * @param osRouterId openstack router id
+     * @return openstack router
+     */
+    Router router(String osRouterId);
+
+    /**
+     * Returns all routers.
+     *
+     * @return set of openstack routers
+     */
+    Set<Router> routers();
+
+    /**
+     * Returns the router interface with the given ID.
+     *
+     * @param osRouterIfaceId openstack router interface port id
+     * @return openstack router interface
+     */
+    RouterInterface routerInterface(String osRouterIfaceId);
+
+    /**
+     * Returns all router interfaces.
+     *
+     * @return set of openstack router interfaces
+     */
+    Set<RouterInterface> routerInterfaces();
+
+    /**
+     * Returns all router interfaces with the router ID.
+     *
+     * @param osRouterId openstack router id
+     * @return set of router interfaces
+     */
+    Set<RouterInterface> routerInterfaces(String osRouterId);
+
+    /**
+     * Returns the floating IP with the supplied floating IP ID.
+     * @param floatingIpId floating ip id
+     * @return openstack floating ip
+     */
+    NetFloatingIP floatingIp(String floatingIpId);
+
+    /**
+     * Returns all floating IPs.
+     *
+     * @return set of openstack floating ips
+     */
+    Set<NetFloatingIP> floatingIps();
+
+    /**
+     * Returns all floating IPs associated with the router ID.
+     *
+     * @param routerId router id
+     * @return set of openstack floating ips
+     */
+    Set<NetFloatingIP> floatingIps(String routerId);
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterStore.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterStore.java
new file mode 100644
index 0000000..516a357
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterStore.java
@@ -0,0 +1,146 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onosproject.store.Store;
+import org.openstack4j.model.network.NetFloatingIP;
+import org.openstack4j.model.network.Router;
+import org.openstack4j.model.network.RouterInterface;
+
+import java.util.Set;
+
+/**
+ * Manages inventory of OpenStack router states; not intended for direct use.
+ */
+public interface OpenstackRouterStore
+        extends Store<OpenstackRouterEvent, OpenstackRouterStoreDelegate> {
+
+    /**
+     * Creates a new router.
+     *
+     * @param osRouter openstack router
+     */
+    void createRouter(Router osRouter);
+
+    /**
+     * Updates the router.
+     *
+     * @param osRouter updated openstack router
+     */
+    void updateRouter(Router osRouter);
+
+    /**
+     * Removes the router with the supplied ID.
+     *
+     * @param osRouterId openstack router id
+     * @return removed router; null if failed
+     */
+    Router removeRouter(String osRouterId);
+
+    /**
+     * Returns the router with the supplied router ID.
+     *
+     * @param osRouterId openstack router id
+     * @return openstack router; null if not found
+     */
+    Router router(String osRouterId);
+
+    /**
+     * Returns all routers.
+     *
+     * @return set of openstack router
+     */
+    Set<Router> routers();
+
+    /**
+     * Adds a new interface to the router.
+     *
+     * @param osRouterIface openstack router interface
+     */
+    void addRouterInterface(RouterInterface osRouterIface);
+
+    /**
+     * Updates the router interface.
+     *
+     * @param osRouterIface openstack router interface
+     */
+    void updateRouterInterface(RouterInterface osRouterIface);
+
+    /**
+     * Removes the router interface.
+     *
+     * @param osRouterIfaceId openstack router interface id
+     * @return removed router interface; null if failed
+     */
+    RouterInterface removeRouterInterface(String osRouterIfaceId);
+
+    /**
+     * Returns the router interface with the given ID.
+     *
+     * @param osRouterIfaceId openstack router interface port id
+     * @return openstack router interface
+     */
+    RouterInterface routerInterface(String osRouterIfaceId);
+
+    /**
+     * Returns all router interfaces.
+     *
+     * @return set of openstack router interfaces
+     */
+    Set<RouterInterface> routerInterfaces();
+
+    /**
+     * Creates a new floating IP address.
+     *
+     * @param floatingIp openstack floating ip
+     */
+    void createFloatingIp(NetFloatingIP floatingIp);
+
+    /**
+     * Updates the floating IP address.
+     *
+     * @param floatingIp updated openstack floating ip
+     */
+    void updateFloatingIp(NetFloatingIP floatingIp);
+
+    /**
+     * Removes the floating IP with the supplied ID.
+     *
+     * @param floatingIpId floating ip id
+     * @return removed floating ip; null if failed
+     */
+    NetFloatingIP removeFloatingIp(String floatingIpId);
+
+    /**
+     * Returns the floating IP with the supplied ID.
+     *
+     * @param floatingIpId floating ip id
+     * @return openstack floating ip; null if not found
+     */
+    NetFloatingIP floatingIp(String floatingIpId);
+
+    /**
+     * Returns all floating IP addresses.
+     *
+     * @return openstack floating ip; empty set if no floating ip exists
+     */
+    Set<NetFloatingIP> floatingIps();
+
+    /**
+     * Clears the existing routers and floating IPs.
+     */
+    void clear();
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterStoreDelegate.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterStoreDelegate.java
new file mode 100644
index 0000000..c1bf7d9
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackRouterStoreDelegate.java
@@ -0,0 +1,24 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onosproject.store.StoreDelegate;
+
+/**
+ * OpenStack router store delegate abstraction.
+ */
+public interface OpenstackRouterStoreDelegate extends StoreDelegate<OpenstackRouterEvent> {
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupAdminService.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupAdminService.java
new file mode 100644
index 0000000..b781ff6
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupAdminService.java
@@ -0,0 +1,64 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.openstack4j.model.network.SecurityGroup;
+import org.openstack4j.model.network.SecurityGroupRule;
+
+/**
+ * Service for administering the inventory of Openstack security group.
+ */
+public interface OpenstackSecurityGroupAdminService {
+    /**
+     * Creates a security group.
+     *
+     * @param sg security group
+     */
+    void createSecurityGroup(SecurityGroup sg);
+
+    /**
+     * Updates the security group.
+     *
+     * @param sg security group
+     */
+    void updateSecurityGroup(SecurityGroup sg);
+
+    /**
+     * Removes the security group.
+     *
+     * @param sgId security group ID
+     */
+    void removeSecurityGroup(String sgId);
+
+    /**
+     * Creates a security group rule.
+     *
+     * @param sgRule security group rule
+     */
+    void createSecurityGroupRule(SecurityGroupRule sgRule);
+
+    /**
+     * Removes the security group rule.
+     *
+     * @param sgRuleId security group rule ID
+     */
+    void removeSecurityGroupRule(String sgRuleId);
+
+    /**
+     * Removes the existing security groups.
+     */
+    void clear();
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupEvent.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupEvent.java
new file mode 100644
index 0000000..30ad1af
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupEvent.java
@@ -0,0 +1,83 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onosproject.event.AbstractEvent;
+import org.openstack4j.model.network.SecurityGroup;
+import org.openstack4j.model.network.SecurityGroupRule;
+
+/**
+ * Describes OpenStack security group event.
+ */
+public class OpenstackSecurityGroupEvent
+        extends AbstractEvent<OpenstackSecurityGroupEvent.Type, SecurityGroup> {
+
+    private SecurityGroupRule sgRule;
+
+    public enum Type {
+        /**
+         * Signifies that a new OpenStack security group is created.
+         */
+        OPENSTACK_SECURITY_GROUP_CREATED,
+
+        /**
+         * Signifies that the OpenStack security group is removed.
+         */
+        OPENSTACK_SECURITY_GROUP_REMOVED,
+
+        /**
+         * Signifies that a new OpenStack security group rule is created.
+         */
+        OPENSTACK_SECURITY_GROUP_RULE_CREATED,
+
+        /**
+         * Signifies that the OpenStack security group rule is removed.
+         */
+        OPENSTACK_SECURITY_GROUP_RULE_REMOVED,
+    }
+
+    /**
+     * SecurityGroupEvent constructor.
+     *
+     * @param type SecurityGroupEvent type
+     * @param sg SecurityGroup object
+     */
+    public OpenstackSecurityGroupEvent(OpenstackSecurityGroupEvent.Type type, SecurityGroup sg) {
+        super(type, sg);
+    }
+
+    /**
+     * SecurityGroupEvent constructor.
+     *
+     * @param type SecurityGroupEvent type
+     * @param sg security group
+     * @param sgRule SecurityGroup object
+     */
+    public OpenstackSecurityGroupEvent(OpenstackSecurityGroupEvent.Type type, SecurityGroup sg,
+                                       SecurityGroupRule sgRule) {
+        super(type, sg);
+        this.sgRule = sgRule;
+    }
+
+    /**
+     * Returns security group rule.
+     *
+     * @return SecurityGroupRule
+     */
+    public SecurityGroupRule securityGroupRule() {
+        return this.sgRule;
+    }
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupListener.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupListener.java
new file mode 100644
index 0000000..8571ee3
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupListener.java
@@ -0,0 +1,26 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onosproject.event.EventListener;
+
+/**
+ * Listener for OpenStack Security Group events.
+ *
+ */
+public interface OpenstackSecurityGroupListener
+        extends EventListener<OpenstackSecurityGroupEvent> {
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupService.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupService.java
new file mode 100644
index 0000000..98ac3b7
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupService.java
@@ -0,0 +1,57 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onosproject.event.ListenerService;
+import org.openstack4j.model.network.SecurityGroup;
+
+import java.util.Set;
+
+/**
+ * Service for interfacing OpenStack SecurityGroup events and SecurityGroup store.
+ */
+public interface OpenstackSecurityGroupService
+        extends ListenerService<OpenstackSecurityGroupEvent, OpenstackSecurityGroupListener> {
+
+    /**
+     * Returns all security groups.
+     *
+     * @return set of security group
+     */
+    Set<SecurityGroup> securityGroups();
+
+    /**
+     * Returns the security group for the sgId.
+     *
+     * @param sgId security group Id
+     * @return security group
+     */
+    SecurityGroup securityGroup(String sgId);
+
+    /**
+     * Returns whether security group is enabled or not.
+     *
+     * @return true security group is enabled, false otherwise
+     */
+    boolean isSecurityGroupEnabled();
+
+    /**
+     * Sets security group enable option.
+     *
+     * @param option security group enable option
+     */
+    void setSecurityGroupEnabled(boolean option);
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupStore.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupStore.java
new file mode 100644
index 0000000..fcac3eb
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupStore.java
@@ -0,0 +1,71 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.onosproject.openstacknetworking.api;
+
+import org.onosproject.store.Store;
+import org.openstack4j.model.network.SecurityGroup;
+
+import java.util.Set;
+
+/**
+ * Manages inventory of OpenStack security group states; not intended for direct use.
+ */
+public interface OpenstackSecurityGroupStore
+        extends Store<OpenstackSecurityGroupEvent, OpenstackSecurityGroupStoreDelegate> {
+
+    /**
+     * Creates a security group.
+     *
+     * @param sg security group
+     */
+    void createSecurityGroup(SecurityGroup sg);
+
+    /**
+     * Updates the security group with the security group ID with the security group object.
+     *
+     * @param sg new SecurityGroup object
+     */
+    void updateSecurityGroup(SecurityGroup sg);
+
+    /**
+     * Removes the security group with the security group ID.
+     *
+     * @param sgId security group Id
+     * @return SecurityGroup object removed
+     */
+    SecurityGroup removeSecurityGroup(String sgId);
+
+    /**
+     * Returns the security group with the security group ID.
+     *
+     * @param sgId security group ID
+     * @return Security Group
+     */
+    SecurityGroup securityGroup(String sgId);
+
+    /**
+     * Returns all security groups.
+     *
+     * @return set of security groups
+     */
+    Set<SecurityGroup> securityGroups();
+
+    /**
+     * Clears the security group store.
+     */
+    void clear();
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupStoreDelegate.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupStoreDelegate.java
new file mode 100644
index 0000000..8edfdfe
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/OpenstackSecurityGroupStoreDelegate.java
@@ -0,0 +1,24 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.onosproject.openstacknetworking.api;
+
+import org.onosproject.store.StoreDelegate;
+
+/**
+ * OpenStack security group store delegate abstraction.
+ */
+public interface OpenstackSecurityGroupStoreDelegate extends StoreDelegate<OpenstackSecurityGroupEvent> {
+}
diff --git a/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/package-info.java b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/package-info.java
new file mode 100644
index 0000000..731401b
--- /dev/null
+++ b/apps/openstacknetworking/api/src/main/java/org/onosproject/openstacknetworking/api/package-info.java
@@ -0,0 +1,22 @@
+/*
+ * Copyright 2017-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.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * Implements OpenStack L3 service plugin, which routes packets between subnets,
+ * forwards packets from internal networks to external ones, and accesses instances
+ * from external networks through floating IPs.
+ */
+package org.onosproject.openstacknetworking.api;