tom

Added more providers/of modules and javadocs.

Split onos-core feature into onos-api and onos-core.
......@@ -19,14 +19,19 @@
<bundle>mvn:com.sun.jersey/jersey-servlet/1.18.1</bundle>
</feature>
<feature name="onos-core" version="1.0.0"
description="ONOS core components">
<feature name="onos-api" version="1.0.0"
description="ONOS services and model API">
<feature>scr</feature>
<feature>onos-thirdparty-base</feature>
<bundle>mvn:org.onlab.onos/onos-utils-osgi/1.0.0-SNAPSHOT</bundle>
<bundle>mvn:org.onlab.onos/onos-utils-rest/1.0.0-SNAPSHOT</bundle>
<bundle>mvn:org.onlab.onos/onos-api/1.0.0-SNAPSHOT</bundle>
</feature>
<feature name="onos-core" version="1.0.0"
description="ONOS core components">
<feature>onos-api</feature>
<bundle>mvn:org.onlab.onos/onos-core/1.0.0-SNAPSHOT</bundle>
</feature>
......@@ -60,6 +65,8 @@
<bundle>mvn:org.onlab.onos/onos-of-ctl/1.0.0-SNAPSHOT</bundle>
<bundle>mvn:org.onlab.onos/onos-of-provider-device/1.0.0-SNAPSHOT</bundle>
<bundle>mvn:org.onlab.onos/onos-of-provider-link/1.0.0-SNAPSHOT</bundle>
<bundle>mvn:org.onlab.onos/onos-of-provider-host/1.0.0-SNAPSHOT</bundle>
</feature>
</features>
......
......@@ -15,8 +15,8 @@ public interface DeviceProvider extends Provider {
* Triggers an asynchronous probe of the specified device, intended to
* determine whether the host is present or not. An indirect result of this
* should be invocation of
* {@link org.onlab.onos.net.device.DeviceProviderService#deviceConnected(DeviceDescription)} )} or
* {@link org.onlab.onos.net.device.DeviceProviderService#deviceDisconnected(DeviceDescription)}
* {@link org.onlab.onos.net.device.DeviceProviderService#deviceConnected} )} or
* {@link org.onlab.onos.net.device.DeviceProviderService#deviceDisconnected}
* at some later point in time.
*
* @param device device to be probed
......
......@@ -261,7 +261,7 @@
<title>OpenFlow Providers &amp; Controller
</title>
<packages>
org.onlab.onos.net.provider.of:org.onlab.onos.net.provider.of.*:org.onlab.onos.of.*
org.onlab.onos.provider.of.*:org.onlab.onos.of.*
</packages>
</group>
<group>
......
......@@ -16,7 +16,8 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* Device provider which uses an OpenFlow controller to detect devices.
* Device provider which uses an OpenFlow controller to detect network
* infrastructure devices.
*/
@Component
public class OpenFlowDeviceProvider extends AbstractProvider implements DeviceProvider {
......@@ -54,7 +55,7 @@ public class OpenFlowDeviceProvider extends AbstractProvider implements DevicePr
@Override
public void triggerProbe(Device device) {
log.info("Triggerring probe on device {}", device.id());
log.info("Triggering probe on device {}", device.id());
}
@Override
......
<body>
Provider that uses OpenFlow controller as a means of infrastructure device discovery.
</body>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<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/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onlab.onos</groupId>
<artifactId>onos-of-providers</artifactId>
<version>1.0.0-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<artifactId>onos-of-provider-host</artifactId>
<packaging>bundle</packaging>
<description>ONOS OpenFlow protocol host provider</description>
</project>
package org.onlab.onos.provider.of.host.impl;
import org.apache.felix.scr.annotations.Activate;
import org.apache.felix.scr.annotations.Component;
import org.apache.felix.scr.annotations.Deactivate;
import org.apache.felix.scr.annotations.Reference;
import org.apache.felix.scr.annotations.ReferenceCardinality;
import org.onlab.onos.net.Host;
import org.onlab.onos.net.host.HostProvider;
import org.onlab.onos.net.host.HostProviderBroker;
import org.onlab.onos.net.host.HostProviderService;
import org.onlab.onos.net.provider.AbstractProvider;
import org.onlab.onos.net.provider.ProviderId;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* Device provider which uses an OpenFlow controller to detect network
* end-station hosts.
*/
@Component
public class OpenFlowHostProvider extends AbstractProvider implements HostProvider {
private final Logger log = LoggerFactory.getLogger(OpenFlowHostProvider.class);
@Reference(cardinality = ReferenceCardinality.MANDATORY_UNARY)
protected HostProviderBroker providerBroker;
private HostProviderService providerService;
// @Reference(cardinality = ReferenceCardinality.MANDATORY_UNARY)
// protected OpenFlowController controller;
/**
* Creates an OpenFlow host provider.
*/
public OpenFlowHostProvider() {
super(new ProviderId("org.onlab.onos.provider.of.host"));
}
@Activate
public void activate() {
providerService = providerBroker.register(this);
log.info("Started");
}
@Deactivate
public void deactivate() {
providerBroker.unregister(this);
providerService = null;
log.info("Stopped");
}
@Override
public void triggerProbe(Host host) {
log.info("Triggering probe on device {}", host);
}
}
<body>
Provider that uses OpenFlow controller as a means of host discovery and tracking.
</body>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<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/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onlab.onos</groupId>
<artifactId>onos-of-providers</artifactId>
<version>1.0.0-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<artifactId>onos-of-provider-link</artifactId>
<packaging>bundle</packaging>
<description>ONOS OpenFlow protocol link provider</description>
</project>
package org.onlab.onos.provider.of.link.impl;
import org.apache.felix.scr.annotations.Activate;
import org.apache.felix.scr.annotations.Component;
import org.apache.felix.scr.annotations.Deactivate;
import org.apache.felix.scr.annotations.Reference;
import org.apache.felix.scr.annotations.ReferenceCardinality;
import org.onlab.onos.net.link.LinkProvider;
import org.onlab.onos.net.link.LinkProviderBroker;
import org.onlab.onos.net.link.LinkProviderService;
import org.onlab.onos.net.provider.AbstractProvider;
import org.onlab.onos.net.provider.ProviderId;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* Device provider which uses an OpenFlow controller to detect network
* infrastructure links.
*/
@Component
public class OpenFlowLinkProvider extends AbstractProvider implements LinkProvider {
private final Logger log = LoggerFactory.getLogger(OpenFlowLinkProvider.class);
@Reference(cardinality = ReferenceCardinality.MANDATORY_UNARY)
protected LinkProviderBroker providerBroker;
private LinkProviderService providerService;
// @Reference(cardinality = ReferenceCardinality.MANDATORY_UNARY)
// protected OpenFlowController controller;
/**
* Creates an OpenFlow link provider.
*/
public OpenFlowLinkProvider() {
super(new ProviderId("org.onlab.onos.provider.of.link"));
}
@Activate
public void activate() {
providerService = providerBroker.register(this);
log.info("Started");
}
@Deactivate
public void deactivate() {
providerBroker.unregister(this);
providerService = null;
log.info("Stopped");
}
}
<body>
Provider that uses OpenFlow controller as a means of infrastructure link inference.
</body>
\ No newline at end of file
......@@ -18,6 +18,8 @@
<modules>
<module>device</module>
<module>link</module>
<module>host</module>
</modules>
<dependencies>
......