24 Commits

Author SHA1 Message Date
Brian O'Connor
bfc02ecd22 Bumping snapshot version to 1.8.0-SNAPSHOT
Change-Id: I4ca57b277d8ac814b8a10b107d995cb1cc4d499d
2016-09-16 17:41:55 +00:00
Brian O'Connor
b19fc86f82 Bumping version back to 1.7.0-SNAPSHOT
Change-Id: I1df9d0f12cd7ec7597499d41cacebdbe75899556
2016-09-16 00:12:21 -07:00
Brian O'Connor
338bc0cf19 Bumping pom versions to 1.7.0-rc2 and fixing some maven issues
Change-Id: I6169420328333d0916452aa92efbfa961d72e9c4
2016-09-16 00:11:45 -07:00
Brian O'Connor
0a4e6742b8 Copyright update
Change-Id: I534d938da3820f6fb814aed3bb4a0855fa41ddd5
2016-09-16 06:48:34 +00:00
Carmelo Cascone
728b1cd9cd Fixed stack overflow bug when using BMv2 table entry service
Similarly to ONOS-4206, due to a bug in kryo, a non-registered class
(Date in this case) was causing such a problem.

Change-Id: I993f4b41d4deaa617065b29086a49d834832eca8
2016-06-29 21:03:38 +00:00
Carmelo Cascone
fbc577b3e9 Various BMv2 bugfixes
Change-Id: Ia5a2a1c86b8a90ad68ddb92980377f6308e200d2
2016-06-28 23:43:07 +00:00
Carmelo Cascone
0ec92f1977 Implemented convenient builders of BMv2 extension selectors and
treatments. 

Match and action parameters can now be built from primitive data types
(short, int, long or byte[]) which are then casted automatically
according to a given BMv2 configuration. Also, simplified demo
applications code / structure.

Change-Id: Ia5bebf62301c73c0b20cf6a4ddfb74165889106f
2016-06-28 23:22:29 +00:00
Carmelo Cascone
6256d01c1c Fixed deadlock in BMv2 device context service
Also minor refactoring of synchronized blocks.

Change-Id: Ifea25208ca4f1839bb3f21ba5b5ecfb2441baa35
2016-06-28 23:04:51 +00:00
Carmelo Cascone
ee4cd7e406 Improved consistency for BMv2 flow rules handling
Change-Id: I3a4798af3f35f135e8162385a1bf7fc059028307
2016-06-28 22:41:23 +00:00
Brian O'Connor
1b2aea88c0 Removing gratuitous relativePath from pom.xmls
The default value for relativePath is: ../pom.xml

Change-Id: I1f5e5e6bfa1e91fcddae4f8cb8ab0c00c276e6b0
2016-06-16 07:05:31 +00:00
Carmelo Cascone
25f1888414 Various bmv2 changes to reflect onos-bmv2 v1.0.0 (onos1.6 cherry-pick)
Most notably:
- Updated repo URL and commit ID to official onos-bmv2 fork
- Removed ugly string-based table dump parser, now there's
	a proper API to retrieve table entries (added support in
	Bmv2DeviceAgent)
- Removed unused arguments in packet-in API

Change-Id: I5ff0948eb8fec5283a085913496c187e7b278d8d
2016-06-16 01:30:12 +00:00
Carmelo Cascone
0831efb0b5 Various changes in BMv2 driver and provider modules (onos1.6 cherry-pick)
Driver notable changes:
- Implemented new behaviors, removed deprecated ones
- Removed flow rule translator classes (now under protocol module)
- Improved FlowRuleProgrammable: now it uses BMv2TableEntryService
	to lookup/bind flow rules with BMv2 table entries, retrieves flow
	statistics, better exception handling when adding/replacing/removing
	table entries.
- Improved PacketProgrammable: better exception handling and logging

Provider notable changes:
- Bmv2DeviceProvider: detects and notifies device configuration
	changes and reboots to Bmv2DeviceContextService, added support for
	periodic polling of port statistics
- Bmv2PacketProvider: implemented workaround for OutboundPackets with
	flood treatment

Change-Id: I79b756b533d4afb6b70025a137b2e811fd42a4e8
2016-06-16 00:48:51 +00:00
Brian O'Connor
e642f7cf7b Bumping version to 1.7.0-SNAPSHOT
Change-Id: Id105bf08ecbdac6d4e214ae035b4220aea90f29f
2016-05-23 18:35:29 -07:00
Carmelo Cascone
f8cf288d75 Added ability to poll flow counters in BMv2
Also fixed few minor things here and there.

Change-Id: Ib5e6a92de46870f52510cd6fad0cef8da022bb62
2016-05-12 12:24:02 -07:00
Carmelo Cascone
feb7edb2d5 Fixed bug due to wrong priority in BMv2.
In BMv2 0 is the highest priority, while it is the lowest for ONOS.

Change-Id: Iedb66598f293bf456cf4d206e19c0ff632edfd2c
2016-05-11 15:34:22 +00:00
Carmelo Cascone
a2f510ebba Improve flow rule polling consistency with bmv2
Change-Id: Iee5e7d7bee8f16505fe4d2acf48e65775bb2a524
2016-05-11 15:26:35 +00:00
Carmelo Cascone
d4e7a77b91 Removed hardcoded model from BMv2 driver
Now it uses the model stored in device annotations. Also refactored flow
rule translator classes to reflect this change.

Change-Id: I46541bcc2ab5a267eef4becb6250b9a99684056a
2016-05-10 16:57:36 +00:00
Carmelo Cascone
e9121640ff ONOS-4410 Implemented PacketProgrammable and Pipeliner behaviors in the
BMv2 driver

Also other minor fixes / refactorings

Change-Id: I2205890b76471e8e8490beccd6b36e5358f8d407
2016-05-09 21:13:24 +00:00
Carmelo Cascone
37d5dbf8b6 ONOS-4118 Added synchronization and resiliency to Bmv2ThriftClient
Due to the multi-threaded nature of drivers, calls to a Bmv2ThriftClient
could result in a race condition if not properly synchronized. Also,
once open, transport session might close due to several reasons. Now the
client calls are synchronized and automatically wrapped in a try/catch
that tries to re-open the session for fixed number of times before
giving up.

Change-Id: I5dcdd5a6304406dc6d9d3a0ccf7f16cdbf3b9573
2016-05-04 17:21:32 +00:00
Carmelo Cascone
2954f135bc Translator-based Bmv2 flow rule driver
Removed old parsing logic. Now it uses Bmv2FlowRuleTranslator to
translate ONOS flow rule into Bmv2 model-dependent table entries.

Change-Id: I1febc23b334acade027e806c8a8c266acc061277
2016-04-26 11:46:30 -07:00
Carmelo Cascone
b7388bd8a9 ONOS-4044 Implemented ONOS-to-Bmv2 flow rule translator
In Bmv2, tables, header fields and actions all depend on the packet
processing model configuration (Bmv2Model) currently deployed on the
device. For this reason, translation is needed from protocol-aware ONOS
FlowRule objects into properly formatted, protocol-independent
Bmv2TableEntry objects. Translation is based on a TranslatorConfig that
provides a mapping between ONOS types and Bmv2 model-dependent types.

Change-Id: I620802c2024b5250867dc6b1b988b739177f582a
2016-04-26 11:46:30 -07:00
Carmelo Cascone
aa8b6297a3 Various Bmv2 protocol refactorings in preparation of the flow rule
translator (ONOS-4044)

- Added new classes for different match parameters (exact, ternary, lpm,
  valid)
- Divided api package in two sub-packages, model (previously under
  drivers) and runtime (old api package)
- Improved Bmv2ThriftClient caching and table entry handling

Change-Id: I23c174cf3e8f9f6ecddb99c2d09dc531e8f1c73f
2016-04-26 11:46:30 -07:00
Carmelo Cascone
5899c13b9c ONOS-4175 Implemented BMv2 configuration model parser
Such a model is used to define the way BMv2 should process packets
(i.e. it defines the device ingress/egress pipelines, parser, tables,
actions, etc.) and can be generated (i.e. JSON) by compiling a P4
program using p4c-bm.

Change-Id: Ic08df68bed5a0261cb50b27dc7dbfe9d35e1fb71
2016-04-26 11:46:29 -07:00
Carmelo Cascone
2ea177bb70 ONOS-3961 ONOS-4285 Implemented BMv2 drivers and protocol
Provides Thrift-based implementation for FlowRuleProgrammable and
PortDiscovery behaviours.

Change-Id: Ibbf8720d92301bcd23c5c583d156f464015ff1ef
2016-04-26 18:43:51 +00:00