417 Commits

Author SHA1 Message Date
pierventre
cdcd91c321 [SDFAB-933] Integrate atomix-3.1.12 and expose demote API
Additionally, this patch adds unit tests for demote and
updates a bunch of testing tools

Change-Id: I6c4046730707fa3ac88bbd2bcaf2f60250baa899
2022-02-15 15:44:51 +00:00
pierventre
b418e111cb [AETHER-1265] Integrate Java profiler in TOST env
- Adds a dockerfile to build ONOS image with profiler agent enabled
- Prevents the overriding of the JAVA_OPTS when using the profiler
- Deploy profiler also in the atomix nodes when using stc

Change-Id: I00d5091428083f44360989c701350b7fead66038
2021-05-14 10:28:49 +00:00
Daniele Moro
a3231bbe5d Add dockerfile to build an ONOS container from the local Bazel output
Change-Id: Ia4fbbe73db2f18ae225cf4dd405b60cd8edb5557
(cherry picked from commit c3d410ab9cc3db9ac0eef07950152df065041777)
2021-04-07 07:59:18 +00:00
pier
7118551205 [AETHER-72][AETHER-75] Update atomix to 3.1.9
Change-Id: I60192953f0ebef6730ad6268b10bbf8a59934156
2021-04-06 10:17:32 +00:00
Thomas Vachuska
50dbbec840 Removed devcell-3 from available cells slaves.
Change-Id: I935ef65f681ccea32c90808a10d11dfbb4a79f37
2020-03-03 09:34:48 -08:00
Eric Tang
58b773d442 ONOS-7932: Create ONOS Dockerfile with ssh service
Rename Dockerfile-onos as Dockerfile-sshd.
Change-Id: I01fae6fcdc092a4a4264639a7e8c27d80c3fad52
2020-01-13 18:39:33 +00:00
Carmelo Cascone
f66f77911c Replace references to old versions of Bazel with 1.0
Change-Id: I2998e0b13ec3f9df4d7ec2a5bccdf46a66d9e065
2019-11-22 06:13:48 +00:00
CyberHasH
2713bb6765 Fix wrong package path generated for BasicConstants when recompile basic pipeline. The package path will generated from output argument if no with-package-path argument specified
Change-Id: I1e864bc08d2aa855e44a9fb2a80e453941eefa8b
2019-11-14 10:05:49 +08:00
Carmelo Cascone
356ab8b479 Support creation of vendor-specific versions of the fabric pipeconf
We provide a new service to facilitate registration of vendor-specific
versions of the Fabric pipeconf (e.g., for Tofino) from third-party
apps. This service is designed such that third-party apps do not need to
depend on internal classes at compile time, such as the behaviour
implementations.

To make this possible, the package structure has been refactored to
separate APIs from implementation.

Change-Id: I487cb806541eb9e6877ebf398a94f057613df8cc
(cherry picked from commit 36d5e7a2337c242e45ee57beacd82bba07a0851d)
2019-10-23 17:54:58 +00:00
Daniele Moro
1edc0bd3fd Added meter support to P4info to java tool
Change-Id: Ic5ff5a680199d78d7f7725ff18dc05d7ce1151c3
2019-08-28 18:24:40 +00:00
Carmelo Cascone
b07f2b5ef3 Attempt at fixing p4-trellis STC scenario
the mininet stdout was clogged with stratum log affecting test result

Change-Id: I0f138d3c32bea14ec175fdc745bda58ac74d1bbc
2019-07-12 14:01:39 -07:00
Carmelo Cascone
fb9926708e Update STC scripts to build stratum_bmv2 with PI dynamic linking
Change-Id: I7c32505e54377510b130340c848a7fc50eb95c0c
2019-07-09 10:36:38 -07:00
Rohan Tibrewal
5ec5000d37 Add zprofile for zsh users conveniences
Change-Id: Id9d2dd3706f760005b7108e57dd9892f4736b1ab
2019-07-03 22:50:40 +00:00
Carmelo Cascone
d72dc52c2e Drop building internal docs
They are causing the Jenkins release job to fail and no one really cares
about those

Change-Id: I6c4bd7923dd85772c6fd678fafb172b875e27b8a
2019-07-01 18:42:00 +00:00
Rohan Tibrewal
5766cc57f7 Update P4VM to use Bazel version 0.27.0
Change-Id: I693b9585555c26830782ab42e90347b981e84daf
2019-06-28 23:49:06 +00:00
Carmelo Cascone
1537e8ea5c Fix stratum-related jenkins job failing
Change-Id: Ide032cfe8d93529f266d2cba3435f75920c96877
2019-06-28 14:30:05 -07:00
Carmelo Cascone
912808dc20 Don't look for JAVA_HOME in bash_profile
The Bazel-provided remote JDK is now used by default to build and run

Change-Id: I0f9b340899dbd1fa59bf78c453df94d28cfded1a
2019-06-27 20:37:07 +00:00
Thomas Vachuska
9ccb5faa32 Added a tool to set default JDK to 11 on test cells.
Change-Id: Ie9b983460afa634a2599ff633c3a0a5673eb91dc
2019-06-25 21:07:14 +00:00
cmo
4ab984b3c7 Fix p4vm script to export ova and tutorial script
- Modify missing command in tutorial-bootstrap.sh
- Modify command order in ova-cleanup.sh
- Modify the way to execute ovs-cleanup.sh in vm

Change-Id: Ib010d07b31d9b06f3c4b04d34b2036c0058ca300
(cherry picked from commit f1a04004363d2c59108ad3ca9277c09ec1a2167a)
2019-06-19 21:04:23 +00:00
Carmelo Cascone
21eb042dba Enforce build with Java 11 for all by default
- 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
2019-06-18 22:26:33 +00:00
Sean Condon
a36f65c29a GUI2 Archetype stage 1
Change-Id: Icb17b5f0e7f0e38370390653a6bb27f4204f4091
2019-05-20 21:03:27 +01:00
Carmelo Cascone
ada7b5b820 New P4 dev and tutorial VM with Ubuntu 18.04
Change-Id: Iacf2ca8f8467dc91e696ace5ed30412f7869110a
(cherry picked from commit 2b8bcbcd3d0e3e66ee2bc681f0f1dfbb0e2a218f)
2019-05-17 20:45:36 +00:00
Yi Tseng
b81121fc21
[ONOS-7982] Remove P4Config
Change-Id: Ie5cb39da2f5aad7b097b7e4819fc3a1ea7129ed2
2019-05-07 18:36:46 -07:00
Carmelo Cascone
4b2ff04ad8 Fix clone session not working for BMv2 built in p4vm
Change-Id: I9e1e2516aa886303b406a9d5ab286c5f22e733d3
2019-04-16 21:19:34 +00:00
Carmelo Cascone
97d36a284e Use specific kernel version in p4vm
There is a known issue with some kernel versions that affects PTF tests:
https://github.com/jafingerhut/p4-guide/tree/master/linux-veth-bug

Change-Id: I207cd7b6c2de72c1a9fd353c931584551889a0d3
2019-04-12 18:59:41 +00:00
Carmelo Cascone
a1ae427895 Bump P4 tools and scapy version used in p4vm
Change-Id: Ief0b6a49fed9cdb945a92bb7b5a1bdfd2a283636
2019-04-12 17:57:42 +00:00
Boyuan Yan
1c27bc7f30 Changes to docker file and cluster creation, complete stc test on single instance, but not yet on multi-instances Alao, we add detailed checking for every step in ODTN testing.
Change-Id: Id074e2db89a8892ed263880cfa670c4861e011b9
2019-04-01 15:26:55 -07:00
Thomas Vachuska
5d80e4579e Eliminated references to deprecated ONOS_NIC environment variable.
Change-Id: I9b709920c1aa2e7c1c4cb1f28f920dd2820b86ba
2019-03-21 23:48:22 +00:00
Thomas Vachuska
97642361e7 Changing how ONOS_APPS value is used and defaulted; cleaned up cell defs.
Change-Id: Ie134bd61024738609ef1a02237c696438eff6024
2019-03-21 23:38:08 +00:00
Ray Milkey
f42f76e955 Handle the case where ONOS_APPS is not defined - needed for Jenkins
Change-Id: I66b08f25ebc9171653ae673ea5c562ecb53bcf8c
2019-03-21 10:04:02 -07:00
Ray Milkey
a79a1113c2 Handle the case where ONOS_APPS is not defined - needed for Jenkins
Change-Id: Ic587ebbb975b7ef285febfffd0e4414db0abc7ab
2019-03-21 09:19:54 -07:00
Ray Milkey
2673aaa4b5 temporary hack to get GUI working with existing cell infrastructure
Change-Id: I65caed2fec5cb6fb3187d32b5690a3c0c11ed199
2019-03-20 10:46:26 -07:00
Sean Condon
bf7ff4f3fa Change GUI and GUI2 to be apps rather than core features
Change-Id: I862e5bdbccc29fd78716159e168e7a14bc5053e1
2019-03-20 14:48:49 +00:00
Carmelo Cascone
34d116cbf9 Fix net-trellis-p4-smoke not working with latest stratum_bmv2
- Fix scenario files to use correct deviceId
- More robust liveness check in bmv2.py
- Use different ports for stratum internal server
- Longer switch startup timeout in bmv2.py
- Ignore number of flow rules when checking summary (make scenario
independent of trellis implementation)

Change-Id: I206e5339d2e78ae9a025caa5ec4862a9d4c24871
2019-03-14 06:10:59 +00:00
DongRyeol Cha
2803d30843 Add ipv6 address supporting for file transfer using scp
Some files's scp does not have supporting for ipv6 address.
So, I have added supporting for ipv6 address using scp.

Change-Id: Ie6db5c6988c708e4cec862f6b671dd64b457a69a
2019-03-13 18:40:15 +00:00
Carmelo Cascone
ab5d41e8ab Add support for enabling/disabling ports for gNMI devices
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
2019-03-07 07:45:32 +00:00
Carmelo Cascone
3977ea4d9e Refactor channel and mastership handling in P4Runtime
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
2019-03-06 19:28:42 +00:00
Carmelo Cascone
25243d671f Missing changes from update install-p4-tools.sh to use P4Runtime v1.0
Change-Id: I89aca8b081bd05f10c6a8ad88322fd132316b581
2019-02-22 22:54:19 +00:00
Ray Milkey
ca840af1bd Fix error in expr call when there is only one node
Change-Id: Ic963df930bb5db368457d53aaa3d8691a28b121f
2019-02-22 18:00:59 +00:00
Carmelo Cascone
a4dc3c12bc Update install-p4-tools.sh to use P4Runtime v1.0
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
2019-02-21 23:24:26 +00:00
Carmelo Cascone
7c82bcf4a7 Add command to install stratum and its deps on a remote node
Also:
- update install-p4-tools.sh to build BMv2 and PI for Stratum, as
they need different configure options when used with Stratum
- improved build times (~4 minutes on cell machines)
- removed support for Ubuntu 14.0 and code related to old gnmi support
via sysrepo

Change-Id: Icf9cf936237e2815dee73bdc4370562f29616a23
2019-02-09 20:06:30 +00:00
Carmelo Cascone
499f320249 Update bmv2.py to run stratum_bmv2 plus various improvements
Also added alias to quickly run mininet with stratum in cell machines
and p4vm

Change-Id: Id10bf8f3de4fe14d77b5efe47b6129a8a28b5a89
2019-02-09 20:06:17 +00:00
Carmelo Cascone
92e7d87cc1 Remove additional_languages from generated .bazelproject file
Which might not be supported in IntelliJ community version

Change-Id: Ica6770a33769a47627bd1b0b871e7086fe1b2933
2019-02-08 23:03:25 +00:00
Carmelo Cascone
9d16ad8fe7 Add script to auto-generate Bazel project file
Which is much faster to sync since it reduces the scope of the IDE
targets to java libraries. Although, it requires one to execute the
script each time a new app/library is added to the source tree.

Example usage:
onos-gen-bazel-project > .bazelproject

Change-Id: Ia2911a323b66554f4c5ea588573343013c3c739b
2019-02-08 10:20:49 -08:00
Carmelo Cascone
4c289b731d New P4RuntimeClient implementation that supports batching and error reporting
The new client API supports batching and provides detailed response for
write requests (e.g. if entity already exists when inserting), which was
not possible with the old one.

This patch includes:
- New more efficient implementation of P4RuntimeClient (no more locking,
use native gRPC executor, use stub deadlines)
- Ported all codecs to new AbstractCodec-based implementation (needed to
implement codec cache in the future)
- Uses batching in P4RuntimeFlowRuleProgrammable and
P4RuntimeGroupActionProgrammable
- Minor changes to PI framework runtime classes

Change-Id: I3fac42057bb4e1389d761006a32600c786598683
2019-02-04 23:12:46 -08:00
Carmelo Cascone
e45902b280 Bumped P4Runtime to v1.0.0
Change-Id: Ie6419e45980a0394ce1e0439831f4b011a4d7487
2019-02-05 00:44:37 +00:00
Ray Milkey
a1f8e193e2 Fix ot command
Change-Id: Ia1fd6d03ae4bfd161aaea1f8f3ce85af4a1e4445
2019-01-23 22:35:24 +00:00
Ray Milkey
8705ccead8 Jacoco coverage support for bazel
Change-Id: Ic94304aa6fed0e18f16cecfdda388d421064d0b6
2019-01-23 09:16:54 -08:00
Charles Chan
9c938f87c9 Clean up Karaf environment variables to avoid issues when switching from ONOS 1.x to 2.x
Note: sourcing bash_profile is still required after switching between branches

Change-Id: I6d8df459f6fab630b5b11695bba728b37074120d
(cherry picked from commit 19ff8e374887de9a123beac58463248a6004c420)
2019-01-22 17:57:13 +00:00
Carmelo Cascone
bcb055e550 Generate tutorial p4vm with a specific ONOS version
Also:
- Updated Bazel version
- Removed non-working code to auto-login user and disable screen saver
- Reduce size by doing a shallow clone of ONOS

Change-Id: Ie6efc3ebd6766164e7051f28dff89046141afa7f
(cherry picked from commit 68a0a00b4f332cb1cc518dc9c76e587d70cb4492)
2019-01-09 00:11:44 +00:00