Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

If an application needs to deliver artifacts, such as feature definitions or OSGi bundles which are not available in a public object repository such as Maven central, it can be packaged into an application .oar (ONOS Application aRchive) package file, which is a ZIP file that contains the above app.xml descriptor as well as any other artifacts organized using repository structure hierarchy. The following describes the structure of the application package file:

  • app.xml - application descriptor
  • m2/<groupId>/<artifactId>/<version>/<featuresRepo>
  • m2/<groupId>/<artifactId>/<version>/<artifact>
  • ...

Currently, The application package files can be produced using onos-maven-assembly-plugin, but in the near future plugin quite easily. The pom.xml file needs to include onos-maven-plugin will offer capability to easily produce properly structured application package filesplugin in its build section and if the base module directory contains app.xml file, the plugin will build the application .oar file and this file will be installed into M2 repository during Maven install phase. See the Maven example below.

CLI Commands

Administrators can interact with the inventory of applications using the following console commands:

  • apps - lists all installed applications
  • app install <mvn-url> ... - installs applications by downloading from the specified URLs (not implemented yet)
  • app activate <app-name> ... - activates all specified applications
  • app deactivate <app-name> ... - deactivates all specified applications
  • app uninstall <app-name> ... - uninstalls all specified applications 

...

  • onos-app install <app.xml or app.zip> ... - installs application by uploading the specified app.xml or application package file
  • onos-app install! <app.xml or app.zip> ... - installs and activates applications by uploading the specified app.xml or application package file
  • onos-app reinstall <app-name> <app.xml or app.zip> ... - re-installs application by uploading the specified app.xml or application package file
  • onos-app reinstall! <app-name> <app.xml or app.zip> ... - re-installs and activates applications by uploading the specified app.xml or application package file
  • onos-app activate <app-name> ... - activates the specified application
  • onos-app deactivate <app-name> ... - deactivates the specified application
  • onos-app uninstall <app-name> ... - uninstalls the specified application

Maven Example

...

The following snippet shows the required onos-maven-plugin configuration. ONOS built-in and sample application modules inherit this configuration from the ONOS root pom, but external applications, need to include this configuration in their POM hierarchy or they need to inherit from ONOS root POM:

Code Block
<plugins>
    ...
    <plugin>
        <groupId>org.onosproject</groupId>
        <artifactId>onos-maven-plugin</artifactId>
        <version>1.4-SNAPSHOT</version>
        <executions>
            <execution>
                <id>app</id>
                <phase>package</phase>
                <goals>
                    <goal>app</goal>
                </goals>
            </execution>
        </executions>
    </plugin>
    ...
</plugins>

Builtin Sample and Test Applications

The following list describes the inventory of all builtin drivers, providers and the various sample and test applications:

  • org.onosproject.drivers - Builtin device drivers
  • org.onosproject.openflow - OpenFlow protocol southbound providers
  • org.onosproject.bgprouter - BGP router application, features
  • org.onosproject.config - Network configuration application
  • org.onosproject.demo - Flow throughput test application
  • org.onosproject.election - Master election test application
  • org.onosproject.fwd - Reactive forwarding application using flow subsystem
  • org.onosproject.intentperf - Intent performance test application
  • org.onosproject.metrics - Performance metrics collection
  • org.onosproject.mobility - Host mobility application
  • org.onosproject.null - Null southbound providers for testingorg.onosproject.openflow - OpenFlow protocol southbound providers
  • org.onosproject.optical - Packet/Optical use-case application
  • org.onosproject.proxyarp - Proxy ARP/NDP application
  • org.onosproject.sdnip - SDN/IP use-case application

...