Leftover in the flow stats creates duplicate flow stats entry.
These entries were considered as flows not in the store and thus removed
Additionally adds further guards during the processing of the stats and
updates unit tests
Change-Id: I242009f560660fb572a633f153edf9798256bfd0
Leftover in the flow stats creates duplicate flow stats entry.
These entries were considered as flows not in the store and thus removed
Additionally adds further guards during the processing of the stats and
updates unit tests
Change-Id: Iba07996e1413c54374b7a4ce7efd21109b429eeb
- Restarting the dispatcher during idle events
- Checking, during idle events, if the backlog can be drained
- Reducing the interval of idle events
Does not change the behavior of the state machine
Change-Id: I1721d8fad37e4e833d0fdfd12d51dc51a06559d0
- Removed hard-coded Ipv4Address and replaced with the generic
IpAddress wherever necessary
- Added support of AFI = 2 (IPv6) in MPReachNlri and MPUnreachNlri
- Added a new config parameter for IPv6 in BGP Config. This allows
AFI = 2 to be sent in BGP Open messages
- Skipped TLV 1170 and 1173, which were causing exceptions
Change-Id: I76e69021b1d2687754bbf700681070051e347942
BgpNodeMultitopologyId TLV is called by BgpLinkLSIdentifier. In parseLinkDescriptors
method of BgpLinkLSIdentifier, length is read and then, in switch-case statement, the
control goes to BgpAttrNodeMultiTopologyId.java , where read() method again tries to
read the length. This is the root cause of the BGPParseException in certain BGP packets.
This has been fixed by passing the length from BgpLinkLSIdentifier to
BgpAttrNodeMultiTopologyId. And ofcourse, the same change had to be implemented in other
TLVs which included BgpAttrNodeMultiTopologyId.wq
Change-Id: I662d5f7007e8c92a863fb63ca9ebc7ba2038811a
The ovs vswitchd manual said that the stp enable column name is stp_enable.
But onos's implementation is stpenable. Please refers to following document.
http://www.openvswitch.org//ovs-vswitchd.conf.db.5.pdf
Change-Id: I10973a7c880d27ccef63b9f2e6730272b4280124
Process OF messages through 8 queues. Output queue for messages
controlled per OF Agent with help of message classifiers.
Queues can be configured through component configuration mechanism
for "org.onosproject.openflow.controller.impl.OpenFlowControllerImpl"
component.
Classifiers can be configured through NetworkConfig API in the following
form:
{
"devices": {
"of:0000000000000001": {
"classifiers": [{
"ethernet-type":"LLDP",
"target-queue":0
},{
"ethernet-type":"BDDP",
"target-queue":0
},{
"ethernet-type":"0x1234",
"target-queue":1
}]
}
}
}
Where "target_queue" is queue number from 0 to 7 (7 is default queue),
"ethernet_type" is a type of a packet either in "0xFFFF" from or enum
name as defined in the "org.onlab.packet.EthType.EtherType" enum.
Change-Id: I0512ef653d90c36f00289014872170c1a8aa5204
This change make it possible to build ONOS in a host system without JDK
installed, or ignoring the one installed, instead relying exclusively on
the "remote" JDK provided by Bazel. The JDK version, along with the
toolchain configuration (language source and target values), are checked
in as part of the build files (tools/build/bazel/BUILD), thus enabling
deterministic builds that are less dependent of the host environment.
To allow this, this change replaces all references to JDK-related tools
expected to be on the host PATH, such as the jar command, with their
counterpart from the remote JDK (now a sandboxed relative path). This is
achieved by:
* Creating a new "jdk_genrule" macro that exposes the remote JDK bin
directory to the PATH visible by the genrule command. This is used
for all genrule targets invoking for example `jar`;
* Modifying custom Starlak rule implementations by replacing
invocation to JDK tools with a path from the remote one.
* Renaming the onos/lib directory to onos/deps as it clashes with
the Bazel-provided JDK's lib directory (that for some strange reason
is resolved on the ONOS workspace)
Finally, this change is reflected on the Dockerfile which now builds
ONOS from an Ubuntu image with no JDK installed.
Change-Id: Ie7d990cfce6fef00ddb4ffffe4c6205b8530fb47
- Build with JDK11 and language levels (source and target) are now
enforced in .bazelrc, which depends on our own Java toolchain (defined
in tools/build/bazel/BUILD)
- Easymock bumped to v4.0.2 with support for Java 11 (minor API changes)
- The minimum required Bazel version is now 0.27.*
Change-Id: I0bb6dfe7fc1ea134b5a53dd249c369d58259688c
Includes:
- Bump protobuf to 3.8.0 and grpc-java to 1.21.0 (along with transitive
dependencies such as Netty)
- Add jaxb_api at compile time when needed (removed in JDK 11)
- Bump Bnd to 4.1 (adds support for Java 11)
To build with JDK 11, uncomment lines in .bazelrc.
Tested with Bazel 0.26.0.
Change-Id: Ib8e0c7310eacf97328762606e57c01e4834e5565
Without waiting for the next pipeconf watchdog periodic probe.
To support this, this patch extends the PiPipeconfService to advertise
pipeconf registration events.
Change-Id: Ib44f1813bd37083c666a5e7980de320ce469c2d2
This prevents loading potentially large amount of data in memory when
doing pipeconf reconciliation, as well as unregistering a pipeconf while
devices are using it (since we no longer need to access the
target-specific extensions to generate the device data blob)
Change-Id: Ib54123ce49a931ff88d93c991244d4086e5d7de0
Clone sessions can now be created by defining groups with new type CLONE
The PI framework has been refactored to abstract commonality between
multicast groups and clone sessions as both are managed as part of the
P4Runtime packet replication engine (PRE).
Change-Id: I2f23c629b7de1931d5cab96ec76aef26130ce418
Force reset of gRPC connection backoff when probing for reachability.
This allows provider to attempt reconnection when needed, instead of
depending on the channel backoff timer.
Improved checkup task in GDP to better handle mastership
flapping observed when reconnecting devices.
Change-Id: I473fb14160b2eb744a483de431b91f9f6bcdab95
- Push ports before device is marked online
- Do not notify role NONE on device disconnection (otherwise the
DeviceManager won't mark the device as offline if there's not a master)
- Detect changes in the pipeconf extensions when reloading a pipeconf
Change-Id: I1779987da1269ec98c71b2ccda7bb579be5bf3f0
This change introduces a refactoring of the gRPC protocol subsystem that
allows the creation of a gRPC chanel independently of the client, while
allowing multiple clients to share the same channel (e.g. as in Stratum
where we use 3 clients).
Moreover, we refactor the P4RuntimeClient API to support multiple
P4Runtime-internal device ID using the same client. While before the
client was associated to one of such ID.
Finally, we provide an abstract implementation for gRPC-based driver
behaviors, reducing code duplication in P4Runtime, gNMI and gNOI drivers.
Change-Id: I1a46352bbbef1e0d24042f169ae8ba580202944f
The P4RuntimeClient implements a deferring mechanism to avoid becoming
master when it shouldn't, i.e. when the requested election ID is bigger
than the master one on the device, but it was not asked to be master.
We rely on a distributed primitive to make sure all nodes are aware of
the latest master election ID on the device. In case we lose primitive
update events, this patch adds a maximum timeout after which the
MasterArbitrationUpdate message is always sent.
Change-Id: I98669dac3fc79173b9e98f41e11a4d08901c6cb1
- Do not read counters with table entries for Barefoot drivers
- If driver behavior setup fails, log which operation we are aborting
- Remove unnecessary setup steps in Stratum-related drivers
- Always get clients by their key in gRPC-based drivers
- Log when P4Runtime group operation fails because of missing group in
store
- Fix polling of table entry counters for P4Runtime driver
Change-Id: Ic9bf19b76d8cb5a191aec24852af4410fea8b998
This is a temporary workaround to the inability of p4c to
correctly interpret P4Runtime-defined @max_group_size annotations.
Change-Id: If2799786c135b2eb5b6a3b4c6d6022350d37237e
- catch errors in the cfgdef tool and abort compilation if a mismatch
is seen
- Fix mismatches in the code discovered by the tool
Change-Id: Icd9a15eb9312bba6c2208b0b2a684062fcdc19c3
This change also includes:
- Refactoring of gNMI protocol+driver to take advantage of the recent
changes to the gRPC protocol subsystem (e.g. no more locking, start RPC
with timeouts, etc.).
- Fixed Stratum driver to work after GeneralDeviceProvider refactoring
- Updated bmv2.py to generate ChassisConfig for stratum_bmv2
- Fixed portstate command to use the same port name as in the store
Change-Id: I0dad3bc73e4b6d907b5cf6b7b9a2852943226be7
This is achieved by optimistically updating the P4Runtime mirror using
the write request (instead of waiting for a response) and by serializing
building write requests for the same device.
This change requires updating the P4Runtime protocol classes to expose
the content of the write request.
It also includes:
- force member weight to 1 when reading groups (some server
implementation still fails to be compliant to the spec)
- remove unused operation timeout handling in GDP (now all RPCz have a
timeout)
Change-Id: Ib4f99a6085c1283f46a2797e0c883d96954e02e9
This (big) change aims at solving the issue observed with mastership flapping
and device connection/disconnection with P4Runtime.
Channel handling is now based on the underlying gRPC channel state. Before,
channel events (open/close/error) were generated as a consequence of P4Runtime
StreamChannel events, making device availability dependent on mastership. Now
Stream Channel events only affect mastership (MASTER/STANDBY or NONE when the
SteamChannel RPC is not active).
Mastership handling has been refactored to generate P4Runtime election IDs that
are compatible with the mastership preference decided by the MastershipService.
GeneralDeviceProvider has been re-implemented to support in-order
device event processing and to reduce implementation complexity. Stats polling
has been moved to a separate component, and netcfg handling updated to only
depend on BasicDeviceConfig, augmented with a pipeconf field, and re-using the
managementAddress field to set the gRPC server endpoints (e.g.
grpc://myswitch.local:50051). Before it was depending on 3 different config
classes, making hard to detect changes.
Finally, this change affects some core interfaces:
- Adds a method to DeviceProvider and DeviceHandshaker to check for device
availability, making the meaning of availability device-specific. This is needed
in cases where the device manager needs to change the availability state of a
device (as in change #20842)
- Support device providers not capable of reconciling mastership role responses
with requests (like P4Runtime).
- Clarify the meaning of "connection" in the DeviceConnect behavior.
- Allows driver-based providers to check devices for reachability and
availability without probing the device via the network.
Change-Id: I7ff30d29f5d02ad938e3171536e54ae2916629a2
Unproprer issuing of Device_UNREGISTERED event was causing incorrect device
removal during session re-establishment.
Unconsistent state in ports and links resulted.
Change-Id: Ie07d9077ff0b197a1cb8936b1f307807fae34aeb
Includes also various improvements to the p4vm scripts, such as:
- Choose to build VM with Ubuntu 16.04 or 18.04 (experimental)
- Allow users to specify version of protobuf and grpc to use
- Avoid building protobuf and grpc if already installed in the system
- Install Bazel 0.22
Also:
- Remove check for invalid group member weights (now PI always returns
members with weight 1)
- Re-compiled all P4 programs and fixed missing padding in controller
packet headers
Change-Id: I0e672fcebbaba63354c749f0c774af251f3cbc6c