2396 Commits

Author SHA1 Message Date
Carmelo Cascone
1e8843f8e3 ONOS-7251 ONOS-7264 Support for clone to CPU action in fabric.p4
Clone to CPU is available only for packets processed via multicast
groups. Can be changed in the future when implementation for clone
session APIs is available in PI and P4 targets.

Also:
- compile "fabric-full" profile and generate constants from it
- use interpreter to map logical ports to data plane port IDs

Change-Id: I7db30c08dcf69ed9c870748cce8a797bbd5d6f78
2018-07-25 14:44:32 +00:00
Carmelo Cascone
58136816ab ONOS-7739 Support for P4Runtime multicast programming
Design doc: https://docs.google.com/document/d/13rkQlwr49M-uxQQEuxCMP7BFEPY2gtQ850Hn3gUfesU/edit#heading=h.lzdayib259sq

Change-Id: Ief00bec89fe5a9784b0ee13fdaafa3ae58ab654f
2018-07-20 18:16:17 +00:00
jaegonkim
cbe1c5ed4b [ONOS-7681] IntentCleanup.resubmitPendingRequest() can not generate pendingMap PUT event, and IntentData processing does not happen.
Change-Id: I4bcaf21581d72e9715443f9089a2940bffdc6df0
2018-07-10 23:09:22 +00:00
Jordan Halterman
dae1160e3c Implement lazy iterators/streams for ConsistentMap
Change-Id: Id643726441c99186667c104cfdd1dab95b06cf87
2018-07-09 22:04:41 +00:00
Jordan Halterman
d04e344cd5 Implement service for mastership-based remote Java proxies
Change-Id: I36228fcc79b73550fbf5d6cbbc8b24e01d869957
2018-07-09 18:27:10 +00:00
Jordan Halterman
b8cace7ec9 Implement service for registering, managing, and operating on remote Java proxies over the cluster communication service
Change-Id: I4576e3554cfad08747eed847b73fe695e219f3b8
2018-07-09 17:25:11 +00:00
Charles Chan
eded688740 Set R-bit in neighbor advertisement if replying as a router
Change-Id: Ic51140cf7ab88064df0bc87fb4d1fbc976ce7bc7
2018-07-06 11:19:50 -07:00
Georgios Katsikas
40ecef3be0 New Device type for commodity servers
This device type is now advertized by the server
device driver. Also, the ONOS UI maps this new device
type to a glyph.

Change-Id: Ib4147676474b43202bbdff595a0fa0520b70fe91
Signed-off-by: Georgios Katsikas <katsikas.gp@gmail.com>
2018-07-06 17:38:42 +00:00
Carmelo Cascone
158b8c4f6b More improvements and bugfixes in P4Runtime subsystem
Most notably, we fix a bug in which some nodes were not able to find
pipeconf-specific behaviors for a given device. The problem is not
completelly solved but it's mitigated.

There's a race condition caused by the fact that the GDP updates the cfg
with the merged driver name before advertising the device to the core.
Some nodes might receive the cfg update after the device has been
advertised. We mitigate the problem by performing the pipeline deploy
(slow operation) after the cfg update, giving more time for nodes
to catch up. Perhaps we should listen for cfg update events before
advertising the device to the core?

Also:
- NPE when getting P4Runtime client
- Detect if a base driver is already merged in pipeconf manager
- Longer timeouts in P4Runtime driver and protocol (for slow networks)
- Configurable timeout in P4Runtime driver and GDP
- NPE when adding/removing device agent listeners in P4Rtunime handshaker
- Various exceptions due to race conditions in GDP when disconnecting
devices (by serializing disconnect tasks per device)
- NPE when cancelling polling tasks in GDP
- Refactored PipeconfService to distinguish between driver merge,
pipeconf map update, and cfg update (now performed in the GDP)
- Fixed PipeconfManagerTest, not testing driver behaviours
- Use Guava striped locks when possible (more memory-efficient than maps,
and with strict atomicity guarantees w.r.t. to caches).

Change-Id: I30f3887541ba0fd44439a86885e9821ac565b64c
2018-07-06 08:13:44 +00:00
Laszlo Papp
f50057c986 Add a device upgrade behaviour interface
Change-Id: I43c362a302d3517dda8990e40214ce048b813412
2018-07-02 18:04:00 +00:00
Jordan Halterman
0a2bd45ad2 Add atomic mastership/term/backups method to MastershipService
Change-Id: I18c3aeaa5101c9ce08ff38fffd70eaec903a0f3e
2018-06-29 19:45:22 +00:00
Carmelo Cascone
e5b2872eb6 Improve scalability of P4Runtime subsystem
The P4Runtime client was hanging (deadlock) on a master arbitration
request. As such, all other requests (e.g. table write) were waiting
for the client's request lock to become available.

Apart from fixing those deadlocks, this patch brings a number of
improvements that all together allow to run networks of 100+ P4Runtime
devices on a single ONOS instance (before only ~20 devices)

Includes:
- Asynchrounous mastership handling in DevicHandshaker (as defined in
the P4Runtime and OpenFlow spec)
- Refactored arbitration handling in the P4RuntimeClient
to be consistent with the P4Runtime spec
- Report suspect deadlocks in P4RuntimeClientImpl
- Exploit write errors in P4RuntimeClient to quickly report
channel/mastership errors to upper layers
- Complete all futures with deadlines in P4Runtime driver
- Dump all tables in one request
- Re-purposed ChannelEvent to DeviceAgentEvent to carry also mastership
response events
- Fixed IntelliJ warnings
- Various code and log clean-ups

Change-Id: I9376793a9fe69d8eddf7e8ac2ef0ee4c14fbd198
2018-06-29 13:59:27 +00:00
nitinanand
f14dccdc03 [ONOS-7704] device memory/cpu stats for pica8 switch using Switch_Inventory DB
Change-Id: I1956d06ab373119da59561252f5b35561f8f5619
2018-06-28 15:56:40 +00:00
Esin Karaman
971fb7fd1f ONOS-7251 - Initial implementation of fabric.p4 L2 broadcast feature.
Thrift client cherry-picked from the commit dd5792ac9ee38a702c3128a34224852b5c284687

Change-Id: I989f2b2074485a892195889a7c976b518510da88
2018-06-28 13:34:47 +00:00
Saurav Das
137f27f0e7 Bugfix in routing logic to avoid null groups; Improvement in group handling.
Two main changes for the bug-fix:
    - avoid doing a full-reroute in the event of link failure as this will leave behind stale state in stores
      if event has been preceded by mastership change leading to the nuking of the ecmpSpg for one of the
      link's devices; instead do a rehash
    - when full-reroute is attempted, do it only once, with a complete nuke of the next-obj store

Improvement in group handling allows for a max number of retries for a group that failed to be added.
Earlier behavior was to try only once, and if it fails, it gets removed from the group-store. Now it
is removed after a couple of retries - so total 3 attempts to program the group.

Change-Id: I54ca8203cef779463522b01353540d12f8be3c91
2018-06-20 17:48:32 +00:00
Andreas Pantelopoulos
194164153f Disable host learning feature.
This patch gives us the ability to disable
host learning in certain ports via the ports
configuration.

We have the following cases :
        - Discover a host with no learning configuration, this
          results to learned host (missing config assumes learning is on)
        - Discover a host with learning configuration set to false,
          do not learn that host.
        - Update the learning configuration of a CP to false. Then,
          fetch all host at that location, if these hosts are not
          configured statically at this location, remove them

Change-Id: I2a05ce5f9a890bb4049fd7856f95d78f467e3330
2018-06-15 21:43:39 +00:00
Carmelo Cascone
6af4e17c53 Bumped supported revisions of P4 tools
Includes:
- Use new P4Runtime "v1" package names
- Removed VALID match
- New table entry priority spec (1 is min priority, not 0)
- Fixed p4c-bm2-ss to include arch flag
- Re-compiled P4 programs with more recent p4c (with updated p4info)

Change-Id: I05908f40eda0f0c755009268fd261fb8bcc9be35
2018-06-15 19:04:30 +00:00
Jordan Halterman
8c57a09e4d Refactor DistributedPacketStore to store packet requests in a ConsistentMultimap
Change-Id: Ia4a93c47fee726009673e99609b2f8800807e675
2018-06-13 22:18:00 +00:00
FrankWang
2674e45220 Introduce Pi Register model to PI Framework
Change-Id: I7fae87d5b5ed5fff34b3addfc148cee6fc98137c
2018-06-13 13:00:50 +00:00
Jordan Halterman
3b1373715b Change DefaultRouteTable primitive to cached multimap.
Change-Id: I4b29f95894a5f761a59bebbd9aa6ea778a128f22
2018-06-11 17:01:57 -07:00
Jordan Halterman
5e884353e2 Implement event-based streaming iterator for ConsistentMultimap primitive
Change-Id: I4f41876f91ec752cb3d6ac0fd352ff6e8798dfd6
2018-06-11 17:01:57 -07:00
FrankWang
ea70de3094 [ONOS-7602]Implement support for P4Data in PI framework and P4Runtime southbound
Change-Id: I9c0c76fb29b8c3aa36f39bde62e825f0f0094253
2018-06-08 09:04:50 +00:00
Andrea Campanella
1e5734480f [ONOS-7584] Adding Capability of re-connecting to a P4Runtime Device.
Also addresses ONOS-7359

Change-Id: I47ec4ed429af82feb225ab5ac180b94c91366a53
2018-06-08 02:14:33 +00:00
Charles Chan
ff79dd9169 Implement host probing retry with major refactoring
- Implement probe retry
- Switch to typical core/provider design pattern for HostProbingService
  and as a result decoupling the dependency between SR and HostLocationProvider

Change-Id: I33a15af580677ea376b421ac3e26f9821dcca844
2018-06-06 16:57:33 -07:00
Ray Milkey
0bcdfd1e59 reformat bazel files to use Google coding standards
Change-Id: I320f0ca7ccb1b2247ccdd9fa58fefca7dad8a16f
2018-05-23 14:07:19 -07:00
Ray Milkey
7dac7dadf5 Initial builds using bazel
Change-Id: I38123b396a2ffda5f36cdca43f3ad1fa67a7ab52
2018-05-23 20:38:54 +00:00
Yi Tseng
8d355132da [ONOS-7605] Unable to modify groups on BMV2
Change-Id: I797366ac152dccac75f8ed82b62abe6e5da6dd3e
2018-05-22 18:57:19 +00:00
hiroki
b0bc9da0b5 Add fromString method to connect point
Change-Id: If90b7582b554896250571b9290fd639dfb7057d5
2018-05-21 17:27:32 +00:00
Yuta HIGUCHI
e7e71a8f9f Update checkstyle to 8.10
- fix issues detected
  - YANG custom registrator should be subject to checkstyle
  - fix Java 8 syntax related violations

Change-Id: I0fc52c6612a40d851fd9bc3bf019621776b1f92a
2018-05-21 16:00:21 +00:00
Thomas Vachuska
5b38dc079c Extending DeviceProvider interface to include triggerDisconnect method.
- extended interface with default method implementation
- modified DeviceManager to exploit the new provider feature
- refactored a number of device providers to use the new method
    instead of relying on indirect DEVICE_REMOVED events

Change-Id: Ib315357ef06463012fcf26bbe937c8cdccbf3a94
2018-05-15 16:03:05 +00:00
Thomas Vachuska
164ecf6019 Adding mechanism for device subsystem & providers to trigger device
reconnect in support of ONOS-7645 (device driver change)

- added device listener to OpenFlowDeviceProvider to properly disconnect switch
- removed device listener from OpenFlowControllerImpl
- augmented DriverManager to consult NetworkConfigService as a primary source

Change-Id: I1aa8e9cc7e81ff3af7a72145f4e51f3e32022806
2018-05-09 17:51:20 +00:00
Thomas Vachuska
f131e590f0 Partial fix for ONOS-6767.
- pruning removed annotation tombstones
- processing netcfg only on master node
- swapping priority of processing of geo/grid coordinates

Change-Id: Icade1032f94ea774136d863d388402c79094c5a7
2018-05-07 22:01:58 +00:00
Ray Milkey
2eb9167f47 Improve coverage for primitives
DefaultAtomicCounterMap
DefaultAtomicCounter
DefaultConsistentTreeMap

Change-Id: I15ec01290377aa15ab5351065c33bf50e124b8a6
2018-05-07 20:13:13 +00:00
Yuta HIGUCHI
10b5357dc9 Fix minor comment fixes
Change-Id: I23c880a5b42fba5f319cca17d59fc2f601befef9
2018-05-04 22:00:06 +00:00
Charles Chan
846459217f Implement default method for isConfigured
Change-Id: I30058a186d92b291f0334834fbe3679e30fd247c
2018-05-01 16:27:52 -07:00
Saurav Das
9a55429ae1 Adding a component config to take down single homed host ports when all uplinks are lost.
In addition:
   - handle port updates that may be lost if mastership changes at same time
   - fix javadoc in DeviceService

Change-Id: I032909e8ab9564cf9c978b1d66abd3ab32c814d7
2018-05-01 15:49:55 -07:00
Charles Chan
971d7ba29e Move some functions from segment routing manager to interface service/manager
Change-Id: I7185cf70f7e5d723a63ac35296b8916558560c35
2018-05-01 15:41:49 -07:00
Jonghwan Hyun
800d9d0770 [ONOS-7624] Implement egress pipeline programming
- Implemented logic to handle double-tagged host in segmentrouting application.
- Added 'DummyVlanId' to segmentrouting application to keep track of dummy vlan for L3L2Unfiltered group chain and egress tables.
- Implemented L2Unfiltered group and Egress pipeline programming support in OFDPA pipeline.
- Added EGRESS flag to the forwardingObjective to program Egress tables.
- Fixed bugs when handling double-tagged ARP request, to get correct vlan id and reply with double-tagged packet.
- Fixed bugs in BasicHostConfig, to set the value of 'outerTpid' to 0x8100 if it is not specified.
- Fixed build(ARP/ICMP/ICMP6)reply to build double-tagged reply if corresponding request is double-tagged.

Change-Id: I1fdc30b55827c3f73fad9e854bcaa5fb23f7bcd0
2018-04-26 15:32:17 +00:00
Jon Hall
7d77fe1bb2 Fix typos
Change-Id: Ic20df648fbc3546da20122deaa95f018b9d29f47
2018-04-26 08:23:18 +00:00
Charles Chan
33f4a91efa Implement flow objective queue command
- View flow objecitve queus and caches
- Refactor flow objecitve service and remove deprecated method

Change-Id: I6bbd209a351e0d87c5ee518038b33f72dcb3058a
2018-04-23 14:29:13 -07:00
Carmelo Cascone
4efa498fab Simplify creation of PiActionParam from primitive types
Change-Id: I52053cbe60c4cba3746de1cbf67b16a47ce053bc
2018-04-18 23:33:09 +00:00
Thomas Vachuska
c616e17aff Fixing GUI to respond to server-side layout changes.
Change-Id: Ida1052d6bec4a92d29774ede47942410db189732
2018-04-18 15:56:17 +00:00
Ray Milkey
1657032c03 Fix handling of several error cases in the application REST API
Change-Id: I5a18374834b01e7b79b8f874356bf5f76168b66e
2018-04-17 10:26:54 -07:00
Thomas Vachuska
345b0c7ad2 Fixing host configuration.
Change-Id: I34d4d29c0043bb72197d140060da7e02e8ec5d43
2018-04-16 20:24:16 +00:00
Ray Milkey
bca9049101 Starting snapshot 1.14.0-SNAPSHOT
Change-Id: I97bab4e31d2b701f015289eae29d0c58a4937685
2018-04-13 12:47:31 -07:00
Andreas Pantelopoulos
fdcfe53150 ONOS extensions for use of egress tables.
This patch depends on 17671 onos-loxi patch. When we make
the new loxi release we need to change the prebuild
openflowj in lib/BUCK to that of the actual release number.

It provides support for programming l2 unfiltered groups,
the egress vlan table and the egress tpid table.

Depends-On: I3cea6ed2234147c8dbe440ae1701856a60706e7c
Change-Id: I7525f5856300eac25548b5219a5dffed12b291ad
2018-04-12 19:02:17 +00:00
Carmelo Cascone
0316b96ff2 Simplified string representation of PI flow rules
For easier consumption in UI or CLI

Change-Id: I01c5119194b44581a45b7ec78b1b58ce2a8a01f0
2018-04-12 01:01:47 +00:00
Jordan Halterman
042597f678 Allow duplicate event sinks to be registered to allow retries of component activation.
Change-Id: I892f0efc45239c7399224c3754b640256a9205e9
(cherry picked from commit a255470be96ef72f5a72e1bd80d9744bf5f4cea0)
2018-04-11 22:22:45 +00:00
Carmelo Cascone
255125d9fc No need to map table counters in PI pipeline interpreter
This is related to ONOS-7595. In a recent P4Runtime update, it has been
made explicit that tables can support at most 1 direct counter. Hence,
the pipeline interpreter no longer needs to provide a mapping between a
table and one of potentially many counters. If needed, such mapping can
be derived from the pipeline model (i.e. the p4info)

Change-Id: Ibdece52f35a4d187ab9dbeb90f5527b6285e9788
2018-04-11 21:24:48 +00:00
Carmelo Cascone
81929aa0cf Bumped supported commit of P4Runtime and BMv2
Includes fixes for:
- ONOS-7593: Support for indirect resource Index type
- ONOS-7595: Removed ID from direct resources
- P4Runtime requires unset bits to be 0 in ternary field matches
- Incorrect parsing of flow rule byte counters
- Full entity names in P4Info with top-level control block (fixed only
	for basic.p4, other programs need to be re-compiled and PI IDs in
	respective pipeconf changed)

Change-Id: Ia19aa949c02e363a550e692915c6d6516a2d13d7
2018-04-11 19:04:45 +00:00