sfc.git
7 years agoBump sfc to use yangtools 1.2.0 18/63818/3
Anil Belur [Fri, 29 Sep 2017 02:12:47 +0000 (12:12 +1000)]
Bump sfc to use yangtools 1.2.0

Jira: releng-485

Change-Id: I08a6e4f7cde4cfa0ec1f984d8110b0d23df97703
Signed-off-by: Anil Belur <[email protected]>
7 years agoBump odlparent 2.0.4 to 2.0.5 48/63648/2
Stephen Kitt [Wed, 27 Sep 2017 13:35:53 +0000 (15:35 +0200)]
Bump odlparent 2.0.4 to 2.0.5

Change-Id: I744350ce3067e475ef95eb96b0f40abb9419cf38
Signed-off-by: Stephen Kitt <[email protected]>
7 years agoFix findbugs/sonar violations in sfc-vpp-utils 69/63669/4
Tom Pantelis [Wed, 27 Sep 2017 14:11:04 +0000 (10:11 -0400)]
Fix findbugs/sonar violations in sfc-vpp-utils

- Utility classes should not have public constructors
- Method invokes inefficient new String(String) constructor
- Private method is never called
- Method invokes inefficient Number constructor; use static valueOf instead

Change-Id: I5316b01a63490b44d4bcb6f0fe9a1a5d7b609560
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoAdd SFC shell's command to show Service Nodes 06/63606/2
David Suarez [Wed, 27 Sep 2017 10:36:35 +0000 (12:36 +0200)]
Add SFC shell's command to show Service Nodes

Add SFC shell's command to show Service Nodes, as described in
[1].

Some minor changes in other files to finish the implementation of all
the commands described on the spec.

[1] https://git.opendaylight.org/gerrit/#/c/61059/

Change-Id: I614324f8d4f7e4e8406e4ae9702ab3cb46d17178
Signed-off-by: David Suarez <[email protected]>
7 years agoFix findbugs/checkstyle/sonar violations in sfc-ovs 02/63502/2
Tom Pantelis [Mon, 25 Sep 2017 17:40:52 +0000 (13:40 -0400)]
Fix findbugs/checkstyle/sonar violations in sfc-ovs

- Field isn't final but should be
- Method invokes inefficient new String(String) constructor
- Load of known null value
- Parameter must be non-null but is marked as nullable
- Exception handlers should preserve the original exception
- Utility classes should not have public constructors
- String literals should not be duplicated
- String.valueOf() should not be appended to a String
- Local variable and method parameter names should comply with a naming convention
- Collapsible "if" statements should be merged
- Method parameters, caught exceptions and foreach variables should not be reassigned

Change-Id: Id37c56efb43f609de6883059c063cc3f2b7b438f
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoRefactor SbRestAbstractDataListener 25/63425/4
Tom Pantelis [Thu, 21 Sep 2017 22:22:26 +0000 (18:22 -0400)]
Refactor SbRestAbstractDataListener

Refactored SbRestAbstractDataListener and derived classes to pass
parameters into the ctor instead of via setters. This makes it cleaner
so class fields can be final and avoids null checks elsewhere.

Change-Id: I86cde8471ddb3e3b193520191cef72e02a20056d
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoAdd an API to handle ServiceNode entities 24/63524/2
David Suarez [Tue, 26 Sep 2017 14:05:41 +0000 (16:05 +0200)]
Add an API to handle ServiceNode entities

Add an API to handle ServiceNode entities. This will be firstly used by
the SFC CLI.

Change-Id: Ia55985133b01a398e53e6dae19eb618ee4cf2c80
Signed-off-by: David Suarez <[email protected]>
7 years agoRefactor SbRestAbstractTask 61/63461/2
Tom Pantelis [Fri, 22 Sep 2017 16:36:54 +0000 (12:36 -0400)]
Refactor SbRestAbstractTask

- Change fields to private
- Remove setters and pass params to ctor so field can be final and
  avoid null checks elsewhere
- Expose a method to add to the restUriList

Change-Id: I3d48dd3f2ff04c6e9d52218855de40eee0760659
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoFix findbugs/sonar violations in sfc-sb-rest 23/63423/2
Tom Pantelis [Thu, 21 Sep 2017 21:41:52 +0000 (17:41 -0400)]
Fix findbugs/sonar violations in sfc-sb-rest

- Method ignores exceptional return value
- Consider using Locale parameterized version of invoked method
- Field isn't final but should be (malicious code vulnerability)
- Method uses the same code for two switch clauses
- Redundant nullcheck of value known to be non-null
- Unread public/protected field  (SbRestAbstractTask)
- Field not initialized in constructor but dereferenced without null check

Change-Id: I4f0425b876e6f014d85add0221005cf84d1ddac3
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoBUG9093 Also attempt to use plain Vxlan tunnel 89/63489/1
Jaime Caamaño Ruiz [Fri, 1 Sep 2017 14:33:59 +0000 (16:33 +0200)]
BUG9093 Also attempt to use plain Vxlan tunnel

Give preference to VxlanGpe tunnel type in logical SFF but use standard
Vxlan tunnel if not present. This is because GPE extension might be
globally enabled as a Genius ITM configuration option so that specific
VxlanGpe tunnel types are not used.

Change-Id: I2540ada637b67276977601a6b2dfa418defe872a
Signed-off-by: Jaime Caamaño Ruiz <[email protected]>
(cherry picked from commit c4907b6221e1c3919129eb72d920d85f0d2567e1)

7 years agoFix findbugs/sonar violations in sfc-provider 10/63410/2
Tom Pantelis [Thu, 21 Sep 2017 15:00:03 +0000 (11:00 -0400)]
Fix findbugs/sonar violations in sfc-provider

- Exception handlers should preserve the original exception
- Null value is guaranteed to be dereferenced
- Possible null pointer dereference
- Method parameters should not be reassigned
- Collapsible "if" statements should be merged
- Method ignores exceptional return value
- Comparison of String objects using == or !=
- Consider using Locale parameterized version of invoked method
- Field should be package protected (malicious code vulnerability)
- Write to static field from instance method
- Inefficient use of keySet iterator instead of entrySet iterator
- Load of known null value
- Redundant nullcheck of value known to be non-null
- Useless object created
- Unused local variables should be removed
- Comments should not be located at the end of lines of code

Also enabled findbugs enforcement.

Change-Id: I26fb31995af9349cd5287c77c835342da2c90a84
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoFix findbugs/sonar violations in sfc-genius 88/63388/1
Tom Pantelis [Thu, 21 Sep 2017 02:04:03 +0000 (22:04 -0400)]
Fix findbugs/sonar violations in sfc-genius

Enabled findbugs enforcement. Several violations are
invalid so I had to supress them.

Change-Id: I990b371454b4ed1929e56600c81590e45a6322f0
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoFix findbugs/checkstyle/sonar violations in sfc-scf-vpp 10/63310/2
Tom Pantelis [Tue, 19 Sep 2017 22:24:24 +0000 (18:24 -0400)]
Fix findbugs/checkstyle/sonar violations in sfc-scf-vpp

- Method invokes inefficient new String(String) constructor
- Inefficient use of keySet iterator instead of entrySet iterator
- Should be a static inner class
- Method concatenates strings using + in a loop
- Dead store to local variable

Also enabled findbugs and checkstyle enforcement.

Change-Id: Ie72ec552e6185fa0320fb221d41a95561d228217
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoFix findbugs/sonar violations in sfc-scf-openflow 05/63305/3
Tom Pantelis [Tue, 19 Sep 2017 02:51:27 +0000 (22:51 -0400)]
Fix findbugs/sonar violations in sfc-scf-openflow

- Utility classes should not have public constructors
- Remove unnecessary throws declaration in close()
- Boxing/unboxing to parse a primitive
- Dead store to local variable

Also enabled findbugs enforcement.

Change-Id: I49b6f5de493a5625c02b322d7341ec2ae3688d73
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoFix findbugs/sonar violations in sfc_vpp_renderer 04/63304/2
Tom Pantelis [Tue, 19 Sep 2017 02:27:34 +0000 (22:27 -0400)]
Fix findbugs/sonar violations in sfc_vpp_renderer

- Generic exceptions should never be thrown
- Dead store to local variable

Also enabled findbugs enforcement.

Change-Id: I58465abd21f7a130ddb7a4ff4f09fd65b78af306
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoFix sonar violations in sfc-pot-netconf-renderer 03/63303/2
Tom Pantelis [Tue, 19 Sep 2017 02:09:23 +0000 (22:09 -0400)]
Fix sonar violations in  sfc-pot-netconf-renderer

- Method parameters should not be reassigned
- Unused private fields should be removed

Also enabled findbugs enforcement.

Change-Id: I41a9dec0c59a5a5a6e0653c9788a21dcd61e955a
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoFix findbugs/sonar violations in sfc-openflow-renderer 53/63253/2
Tom Pantelis [Mon, 18 Sep 2017 23:08:33 +0000 (19:08 -0400)]
Fix findbugs/sonar violations in sfc-openflow-renderer

- Method call passes null for non-null parameter
- Method ignores exceptional return value
- Consider using Locale parameterized version of invoked method
- Field isn't final but should be
- Method invokes toString() method on a String
- Inefficient use of keySet iterator instead of entrySet iterator
- Should be a static inner class
- Private method is never called
- Method invokes inefficient Number constructor; use static valueOf instead
- Dead store to local variable
- Write to static field from instance method
- Unread public/protected field
- Field not initialized in constructor but dereferenced without null check
- Useless object created
- Collapsible "if" statements should be merged

Also enabled findbugs enforcement.

Change-Id: If2f867adce5b7a65984c889c0dbb099b7af7ae53
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoFix findbugs/sonar violations in sfc-ios-xe-renderer 52/63252/2
Tom Pantelis [Mon, 18 Sep 2017 21:30:43 +0000 (17:30 -0400)]
Fix findbugs/sonar violations in sfc-ios-xe-renderer

- Suspicious reference comparison of Boolean values
- Dead store to local variable
- Either log or rethrow this exception

Also enabled findbugs enforcement.

Change-Id: Ic497c86357c85deec6ed7279516c36301d8728ab
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoRemove deprecated CheckedFuture 53/62653/4
David Suarez [Mon, 4 Sep 2017 21:05:59 +0000 (23:05 +0200)]
Remove deprecated CheckedFuture

Remove deprecated CheckedFuture.

Change-Id: Ic2eaafd941dcda5511f2586e4e1f4c14d24eaa8e
Signed-off-by: David Suarez <[email protected]>
7 years agoRemove deprecated CheckedFuture 51/62651/3
David Suarez [Mon, 4 Sep 2017 19:32:07 +0000 (21:32 +0200)]
Remove deprecated CheckedFuture

Remove deprecated CheckedFuture.

Change-Id: I32af83be89ccde82e2a510b22ebcd5dc61dd8ffc
Signed-off-by: David Suarez <[email protected]>
7 years agoFix invalid yang revisions 51/63251/1
Tom Pantelis [Mon, 18 Sep 2017 20:48:43 +0000 (16:48 -0400)]
Fix invalid yang revisions

yangtools is no longer being lenient with invalid revisions.

Change-Id: I75fb04a90b15ec0678aa9b749e880a70b2830a99
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoAdjust for mdsal-binding-dom-codec movement 18/62618/3
Robert Varga [Mon, 4 Sep 2017 11:59:18 +0000 (13:59 +0200)]
Adjust for mdsal-binding-dom-codec movement

The component is moving its package name, adjust for that.

Change-Id: I48fc821360b59e36768fae6a8139497e10e3623e
Signed-off-by: Robert Varga <[email protected]>
7 years agoAdd SFC shell's command to show Service Function Types 48/62948/1
David Suarez [Mon, 11 Sep 2017 06:16:20 +0000 (08:16 +0200)]
Add SFC shell's command to show Service Function Types

Add SFC shell's command to show Service Function Types, as described in
[1],

[1] https://git.opendaylight.org/gerrit/#/c/61059/

Change-Id: I5503dc14e4a80c420fe803977fd39fcff6ec4c63
Signed-off-by: David Suarez <[email protected]>
7 years agoMake utility classes final and other minor changes 96/61896/7
David Suarez [Wed, 16 Aug 2017 21:35:20 +0000 (23:35 +0200)]
Make utility classes final and other minor changes

Declare utility classes as "final" to avoid subclassing.

Add qualifiers for constructors.

Change-Id: Ie228927a5f676758b4e1c9386829d8dae9c4aa14
Signed-off-by: David Suarez <[email protected]>
7 years agoRemove deprecated CheckedFuture 50/62650/2
David Suarez [Mon, 4 Sep 2017 19:20:22 +0000 (21:20 +0200)]
Remove deprecated CheckedFuture

Remove deprecated CheckedFuture.

Change-Id: If0a2d3ea887172b74ab41984797511d098c7b9d5
Signed-off-by: David Suarez <[email protected]>
7 years agoRemove unused executor 59/62559/1
David Suarez [Fri, 1 Sep 2017 16:31:19 +0000 (18:31 +0200)]
Remove unused executor

Remove unused executor.

Change-Id: If7ed8908d87e9717fbdc231a0bfb66466cb7d9c9
Signed-off-by: David Suarez <[email protected]>
7 years agoUpdate odlparent to 2.0.4 65/61865/3
Thanh Ha [Wed, 16 Aug 2017 15:19:28 +0000 (11:19 -0400)]
Update odlparent to 2.0.4

Change-Id: I5a5c82c894e3498ccda590e12061b484b2449231
Signed-off-by: Thanh Ha <[email protected]>
7 years agoRemove Executors not used 93/62493/2
David Suarez [Thu, 31 Aug 2017 13:17:05 +0000 (15:17 +0200)]
Remove Executors not used

Remove Executors not used.
Remove some dead code.

Change-Id: Ided648c741c503e3352abb82c68ad7919b1d17e1
Signed-off-by: David Suarez <[email protected]>
7 years agoConvert DataChangeListeners to DataTreeChangeListeners 38/62338/3
Tom Pantelis [Sat, 26 Aug 2017 06:22:49 +0000 (02:22 -0400)]
Convert DataChangeListeners to DataTreeChangeListeners

The DataChangeListener API has been deprecated for a couple releases
with possible removal in Oxygen.

Change-Id: Ic497e09047a41b2e8e5f1b6818fba8298f817589
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoAdd SFC shell's command to show Service Function Paths 84/61584/3
David Suarez [Mon, 14 Aug 2017 07:54:33 +0000 (09:54 +0200)]
Add SFC shell's command to show Service Function Paths

Add SFC shell's command to show Service Function Paths, as described in
[1].

[1] https://git.opendaylight.org/gerrit/#/c/61059/

Change-Id: If11acd10e0ec38de14fee038958ac4a68015db96
Signed-off-by: David Suarez <[email protected]>
7 years agoAdd SFC shell's command to show Service Function Chains 79/61579/5
David Suarez [Mon, 14 Aug 2017 06:53:17 +0000 (08:53 +0200)]
Add SFC shell's command to show Service Function Chains

Add SFC shell's command to show Service Function Chains, as described in
[1],

[1] https://git.opendaylight.org/gerrit/#/c/61059/

Change-Id: Iceadac2c1a39b4c93e950503d5e23924e07e3f39
Signed-off-by: David Suarez <[email protected]>
7 years agoAdd missing relative path 25/61925/2
Stephen Kitt [Thu, 17 Aug 2017 13:08:34 +0000 (15:08 +0200)]
Add missing relative path

Change-Id: I358b05a938f8b4ef812f1174e33b58d434cbba93
Signed-off-by: Stephen Kitt <[email protected]>
7 years agoAdd SFC shell's command to show SFFs 36/61536/3
David Suarez [Fri, 11 Aug 2017 09:28:23 +0000 (11:28 +0200)]
Add SFC shell's command to show SFFs

Add SFC shell's command to show SFFs, as described in [1],

[1] https://git.opendaylight.org/gerrit/#/c/61059/

Change-Id: I3a8197d70fef6073a6713f7fbbe30ff01ae43a0f
Signed-off-by: David Suarez <[email protected]>
7 years agoBump versions by x.(y+1).z for next dev cycle 00/61700/1
Thanh Ha [Mon, 14 Aug 2017 17:37:35 +0000 (13:37 -0400)]
Bump versions by x.(y+1).z for next dev cycle

Change-Id: Ib7c6fc7f5861f48c09c6603c147ad55f322d343d
Signed-off-by: Thanh Ha <[email protected]>
7 years agoBump odlparent 2.0.2 to 2.0.4 56/61356/3
Stephen Kitt [Tue, 8 Aug 2017 16:14:13 +0000 (18:14 +0200)]
Bump odlparent 2.0.2 to 2.0.4

Change-Id: I9c74470018d63d8b693068c7ce7373cabb4cf3ed
Signed-off-by: Stephen Kitt <[email protected]>
7 years agoAdd support for the new SFC shell 01/61401/5
David Suarez [Wed, 9 Aug 2017 07:23:43 +0000 (09:23 +0200)]
Add support for the new SFC shell

Add support for the new SFC shell. This is the first commit of a series
adding all the new CLI commands to the Karaf console to show the
provisioned SFC's model entities as described in [1].

[1] https://git.opendaylight.org/gerrit/#/c/61059/

Change-Id: I04498cbbe23aa0ab3ffb22aba87432217b0fe34b
Signed-off-by: David Suarez <[email protected]>
7 years agoReplace size()==0 by isEmpty() 41/61341/1
David Suarez [Tue, 8 Aug 2017 15:15:19 +0000 (17:15 +0200)]
Replace size()==0 by isEmpty()

Replace size()==0 by isEmpty(). It improves readability and avoid "=0".

Change-Id: Id7c7d52a4c7ad41238b32922fcfca3db3c493fee
Signed-off-by: David Suarez <[email protected]>
7 years agoAdd private constructor to this utility class 76/61076/3
David Suarez [Wed, 2 Aug 2017 21:16:53 +0000 (23:16 +0200)]
Add private constructor to this utility class

Add private constructor to this utility class.

Change-Id: Ifd9a3eff6b23712b7ef2ca3f0d6cc82ffa3b1266
Signed-off-by: David Suarez <[email protected]>
7 years agoJoin and simplify if(s) statements 60/61060/3
David Suarez [Wed, 2 Aug 2017 17:21:39 +0000 (19:21 +0200)]
Join and simplify if(s) statements

Join and simplify if(s) statements

Change-Id: I22a2532f5abf68043906f0cfdea77e6e80db51f6
Signed-off-by: David Suarez <[email protected]>
7 years agoAdd the spec document for the new SFC shell 59/61059/4
David Suarez [Wed, 2 Aug 2017 16:58:11 +0000 (18:58 +0200)]
Add the spec document for the new SFC shell

Add the specification documents for the new feature SFC Command Line
Interface (CLI). This shell will include several commands to show the
provisioned SFC's data model.

Change-Id: I09af7269a327ee6cfe35e824d91e8c0c5a8894f7
Signed-off-by: David Suarez <[email protected]>
7 years agoFix some logs 39/61039/4
David Suarez [Wed, 2 Aug 2017 12:26:59 +0000 (14:26 +0200)]
Fix some logs

Fix some logs to comply with the recommended usage for slf4j.

Change-Id: I6e45bde2cc239ec652f1efb04f5b6523e8bb93eb
Signed-off-by: David Suarez <[email protected]>
7 years agoAdd a readAll method to get all the Service Chains 02/61102/2
David Suarez [Thu, 3 Aug 2017 10:48:45 +0000 (12:48 +0200)]
Add a readAll method to get all the Service Chains

Add a readAll method to get all the Service Chains.

Change-Id: I6f95d23b75c90c848a94e50e13cc18d38c1bb31c
Signed-off-by: David Suarez <[email protected]>
7 years agoAdd a readAll method to get all the Service Function Types. 12/61112/1
David Suarez [Thu, 3 Aug 2017 12:45:42 +0000 (14:45 +0200)]
Add a readAll method to get all the Service Function Types.

Add a readAll method to get all the Service Function Types.

Change-Id: I0028800cc3a87b5eec2102604420da0941124404
Signed-off-by: David Suarez <[email protected]>
7 years agoCleanup 61/61061/1
David Suarez [Wed, 2 Aug 2017 17:38:59 +0000 (19:38 +0200)]
Cleanup

Minor changes to improve code quality and readability.

Change-Id: I4fada8d1e21fef132484b36d6fcf857686330cca
Signed-off-by: David Suarez <[email protected]>
7 years agoImprove the generation of docs within the project 19/61019/1
David Suarez [Wed, 2 Aug 2017 08:00:40 +0000 (10:00 +0200)]
Improve the generation of docs within the project

Add configuration files and static HTML elements that allow to generate
documents with the same look&feel that the ones to be published.

To generate SFC documents just go into the doc directory and type "tox",
the tool will generate an HTML site into the _build directory.

Change-Id: If3e3d9c874f7a64064dbec1d2cded819457f5feb
Signed-off-by: David Suarez <[email protected]>
7 years agoSupport more chain egress methods for logical sff 51/60651/2
Jaime Caamaño Ruiz [Mon, 10 Jul 2017 17:14:59 +0000 (19:14 +0200)]
Support more chain egress methods for logical sff

Some scenarios, like origin and destination of the encapsulated packet
being on the same node, require more flexibility at chain egress.
Support was added to provide the classifier the possibility to handle
the de-encapsulation of the nsh packet and forwarding the original
packet to destination with the help of extra metadata included in the
nsh context.

As before if C1 is 0, packet will be de-encapsulated by SFC and sent
back to dispatcher under the assumption that a different service will
handle the encapsulated packet.

Otherwise, C1 indicates an IP address were the traffic must be sent by
SFC on chain egress. In such cases, introduced in this commit, if C2 is
0, the packet traffic will be sent conserving its original nsh
encapsulation. If C2 is not 0, the packet will be de-encapsulated and
sent through vxlan with C2 as tunnel id, as before.

Also introduced in this commit is the support for C1 to be a local IP
address. The packet will be send either to the dispatcher table if C2 is
0 assuming a chain egress classifier will handle it immediately after,
or to the internal tunnel table if C2 is not 0.

Change-Id: I7ca4f65f3b0142d03399ae096858b010427f8f01
Signed-off-by: Jaime Caamaño Ruiz <[email protected]>
7 years agoConvert sfc-vnfm-tacker to blueprint 97/60697/4
Tom Pantelis [Mon, 24 Jul 2017 17:27:35 +0000 (13:27 -0400)]
Convert sfc-vnfm-tacker to blueprint

Change-Id: I396d7a702207e92c622c322f7f45c22802d177ee
Signed-off-by: Tom Pantelis <[email protected]>
Signed-off-by: Jaime Caamaño Ruiz <[email protected]>
7 years agoImprove the handling of InterruptedException 68/60668/2
David Suarez [Sun, 23 Jul 2017 16:43:22 +0000 (18:43 +0200)]
Improve the handling of InterruptedException

Improve the handling of InterruptedException.

InterruptedExceptions should either be rethrown or the thread should be
re-interrupted by calling Thread.interrupt().

Change-Id: I26a283f9a92d3df66a3e0041a1aab229c7c619e8
Signed-off-by: David Suarez <[email protected]>
7 years agoRemove sfc-rsp-manager 85/60685/2
Tom Pantelis [Mon, 24 Jul 2017 11:30:20 +0000 (07:30 -0400)]
Remove sfc-rsp-manager

This sub-project was added by https://git.opendaylight.org/gerrit/#/c/38222/
over a year ago but is not used and basically only contains a stubbed
CSS Module. Maybe the intent was to imlplement this Module at some point.
If that's the case then we would want to use blueprint and not CSS. Either
way I just removed the entire sub-project.

Change-Id: Ic0e5b2ff6c05d777d4bd6ca17e525a0913e975ca
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoConvert sfc-test-consumer to blueprint 87/60687/2
Tom Pantelis [Mon, 24 Jul 2017 12:36:53 +0000 (08:36 -0400)]
Convert sfc-test-consumer to blueprint

Change-Id: I01767167fc4982803031751273c1349202301e0d
Signed-off-by: Tom Pantelis <[email protected]>
7 years agoMerge "Cleanup minor issues"
Yi Yang [Mon, 24 Jul 2017 01:02:23 +0000 (01:02 +0000)]
Merge "Cleanup minor issues"

7 years agoFix the listener registration 72/60672/1
David Suarez [Sun, 23 Jul 2017 18:46:56 +0000 (20:46 +0200)]
Fix the listener registration

The listener was not properly registered.

Minor changes.

Change-Id: I17931ec1483d517c9c1e15ab63ead4c90a933bf3
Signed-off-by: David Suarez <[email protected]>
7 years agoCleanup minor issues 70/60670/1
David Suarez [Sun, 23 Jul 2017 17:36:55 +0000 (19:36 +0200)]
Cleanup minor issues

Cleanup minor issues.

Change-Id: I63d1761c867735a66de7c8291182921e59ffd788
Signed-off-by: David Suarez <[email protected]>
7 years agoAdd execution permission to test scripts 35/60635/1
Jaime Caamaño Ruiz [Fri, 21 Jul 2017 10:53:57 +0000 (12:53 +0200)]
Add execution permission to test scripts

Change-Id: I39333034d95c59a0a63df46df03f2b72e01cc059
Signed-off-by: Jaime Caamaño Ruiz <[email protected]>
7 years agoAdd support for SFC in only one node in dovs 76/57276/4
Jaime Caamaño Ruiz [Fri, 14 Jul 2017 17:40:35 +0000 (19:40 +0200)]
Add support for SFC in only one node in dovs

In order to be able to test the topology where client, server and SF are
in one node, the support is added in dovs.

Change-Id: I2098607ca3ac2e7b98f885282a6d3532135ef65c
Signed-off-by: Manuel Buil <[email protected]>
Signed-off-by: Jaime Caamaño Ruiz <[email protected]>
7 years agoMigrate the rest of the listeners to use blueprint annotations 83/60583/2
David Suarez [Thu, 20 Jul 2017 07:27:38 +0000 (09:27 +0200)]
Migrate the rest of the listeners to use blueprint annotations

Migrate the rest of the sfc-provider module's listeners to use blueprint
annotations.

Blueprint annotations is the recommended configuration mechanism for
Dependency Injection [1].

Some minor cleanup.

Change-Id: Ib1d7bf0c3dfcb482042934f144263188d43efc04
Signed-off-by: David Suarez <[email protected]>
7 years agoMigrate ServiceFunctionChain listener to use blueprint annotations 28/60328/5
David Suarez [Fri, 14 Jul 2017 10:46:04 +0000 (12:46 +0200)]
Migrate ServiceFunctionChain listener to use blueprint annotations

Migrate ServiceFunctionChain listener to use blueprint annotations.

Blueprint annotations is the recommended configuration mechanism for
Dependency Injection [1].

Some minor cleanup.

[1] https://wiki.opendaylight.org/view/BestPractices/DI_Guidelines

Change-Id: I80f69e4fdf7c57e4448299434423d440d7515ba4
Signed-off-by: David Suarez <[email protected]>
7 years agoBump odlparent from 2.0.0 to 2.0.2 69/60569/1
David Suarez [Wed, 19 Jul 2017 15:05:13 +0000 (17:05 +0200)]
Bump odlparent from 2.0.0 to 2.0.2

Bump odlparent from 2.0.0 to 2.0.2.

Change-Id: I16f10b7603c2492386fff7e6c4b64f3f987900ab
Signed-off-by: David Suarez <[email protected]>
7 years agoMigrate ServiceFunctionForwarder listener to use blueprint annotations 79/60279/1
David Suarez [Thu, 13 Jul 2017 09:48:42 +0000 (11:48 +0200)]
Migrate ServiceFunctionForwarder listener to use blueprint annotations

Migrate ServiceFunctionForwarder to use blueprint annotations. Blueprint
annotations reduce follows the recommended guidelines for DI [1].

Some minor cleanup.

Change-Id: I8a2889a6fc1871be9d4c4019539e030f10d840a4
Signed-off-by: David Suarez <[email protected]>
7 years agoMigrate ServiceFunction listener to use blueprint annotations 32/60132/2
David Suarez [Mon, 10 Jul 2017 12:34:55 +0000 (14:34 +0200)]
Migrate ServiceFunction listener to use blueprint annotations

Migrate ServiceFunction listener to use blueprint annotations. Blueprint
annotations reduce follows the recommended guidelines for DI [1].

Some minor cleanup.

[1] https://wiki.opendaylight.org/view/BestPractices/DI_Guidelines

Change-Id: I296bdb7c6cacc07b8c65209e4cfb881c369d296e
Signed-off-by: David Suarez <[email protected]>
7 years agoAdd a marker file for the project to generate a proper Javadoc 14/60214/2
David Suarez [Tue, 11 Jul 2017 18:51:36 +0000 (20:51 +0200)]
Add a marker file for the project to generate a proper Javadoc

Add the deploy-site.xml marker file that allows the SFC merge job to
generate a proper Javadoc. This Javadoc will be published on [1].

[1] https://nexus.opendaylight.org/content/sites/site/

Change-Id: I4a66cfaa9aaf439bbfa6f7b3c4cc8836b28868e3
Signed-off-by: David Suarez <[email protected]>
7 years agoAdd javax.inject dependency sfc-parent POM 97/60097/1
David Suarez [Fri, 7 Jul 2017 17:11:18 +0000 (19:11 +0200)]
Add javax.inject dependency sfc-parent POM

Adding java.inject to sfc-parent to allow modules to include annotations
(@Singleton, @Inject, etc.).

Minor cleanup: moving modules at the beginning of file to better
identify what the aggregator is building.

Change-Id: Ic8ae00c3396b0f9dba8c72849e158eedc4c571b9
Signed-off-by: David Suarez <[email protected]>
7 years agoAdd blueprint maven plugin to sfc-parent POM 31/60031/1
David Suarez [Thu, 6 Jul 2017 15:11:49 +0000 (17:11 +0200)]
Add blueprint maven plugin to sfc-parent POM

Following the best practices in DI described in [1], this
patch add support to SFC for generating the blueprint xml file directly
from annotations (@Singleton, @Inject, etc.).

The patch adds also support for other OSGi annotations as
@osgiservice by including pax-cdi-api.

[1]
https://wiki.opendaylight.org/view/BestPractices/DI_Guidelines#NEW:_.40OsgiService_.26_.40OsgiServiceProvider_.28pax-cdi-api.29

Change-Id: I3d06169cac7db125f70827c6bd1689b74b102590
Signed-off-by: David Suarez <[email protected]>
7 years agoRemove direct usage of OpenFlowJava models 03/60003/1
Tomas Slusny [Thu, 6 Jul 2017 07:41:53 +0000 (09:41 +0200)]
Remove direct usage of OpenFlowJava models

Remove direct usage of OpenFlowJava models in SfcOpenflowUtils and
replace them with usage of OpenFlowPlugin models.

Resolves: bug 8807
See also: bug 8747

Change-Id: I6c13740e9d2ed60fa0db0a29353b0b199bdb9c8a
Signed-off-by: Tomas Slusny <[email protected]>
7 years agoMerge "Adding blueprint template"
Yi Yang [Thu, 6 Jul 2017 05:17:56 +0000 (05:17 +0000)]
Merge "Adding blueprint template"

7 years agoAdd infrautils version to parent pom 77/59977/1
David Suarez [Wed, 5 Jul 2017 14:26:49 +0000 (16:26 +0200)]
Add infrautils version to parent pom

Add infrautils project version to the sfc parent pom so
that it can be referenced by other other modules.

Change-Id: Ia1cea8ea352b724061b71faaadc78276be8284f6
Signed-off-by: David Suarez <[email protected]>
7 years agoAdding blueprint template 07/58607/7
Brady Johnson [Fri, 9 Jun 2017 12:30:01 +0000 (14:30 +0200)]
Adding blueprint template

- All new features must first have a blueprint.
- This blueprint templates is based on OpenStack blueprints
  and was copied from the Netvirt project.

Change-Id: Id019f22065bdde327a6a4c391f1b8971a9190530
Signed-off-by: Brady Johnson <[email protected]>
Signed-off-by: David Suarez <[email protected]>
7 years agoAdd files to be ignored 91/59791/2
David Suarez [Fri, 30 Jun 2017 14:18:27 +0000 (16:18 +0200)]
Add files to be ignored

Change-Id: Ib4d83e049ba4713524853055cbdc4fd2e9456b4d
Signed-off-by: David Suarez <[email protected]>
7 years agoAdded classifier creation in dovs 95/57295/3
Manuel Buil [Wed, 17 May 2017 16:52:45 +0000 (18:52 +0200)]
Added classifier creation in dovs

To create the classification config we had to use the RestAPI directly.
Using this patch we can use the dovs CLI

Change-Id: I784109c192b22a5590fa3a440fc19a722a023d1c
Signed-off-by: Manuel Buil <[email protected]>
7 years agoStore SFF Openflow table offsets 11/59611/3
Brady Johnson [Thu, 29 Jun 2017 13:16:45 +0000 (15:16 +0200)]
Store SFF Openflow table offsets

- Simple DataObject used internally to specify SFF
  OpenFlow table offsets. To be used primarily to
  pass information from the SFC OpenFlow renderer
  to the sfc-statistics module.

Change-Id: I5c13d081f01e97bc00a3678f33c128f57e347e28
Signed-off-by: Brady Johnson <[email protected]>
7 years agoBump odlparent to 2.0.0 25/59325/1
Brady Johnson [Thu, 22 Jun 2017 08:27:55 +0000 (10:27 +0200)]
Bump odlparent to 2.0.0

- Needed for Karaf 4 migration.

Change-Id: I8e717a7b129433724c5888ff93180d04b7161b27
Signed-off-by: Brady Johnson <[email protected]>
7 years agoMerge "Improving SFC OpenFlow Flow Names and IDs"
Yi Yang [Thu, 22 Jun 2017 02:41:42 +0000 (02:41 +0000)]
Merge "Improving SFC OpenFlow Flow Names and IDs"

7 years agoImproving SFC OpenFlow Flow Names and IDs 30/59230/3
Brady Johnson [Tue, 20 Jun 2017 12:58:39 +0000 (14:58 +0200)]
Improving SFC OpenFlow Flow Names and IDs

- Previously the Flow id was an incrementing counter,
  which makes it difficult to easily retrieve flows
  from the data store by the flow ID.

Change-Id: Ie2a87e2748d05efd29b516aa6e2c126e483fdcd7
Signed-off-by: Brady Johnson <[email protected]>
7 years agoBug 8543: Pop_nsh should be last 52/57752/2
Manuel Buil [Wed, 24 May 2017 09:43:16 +0000 (11:43 +0200)]
Bug 8543: Pop_nsh should be last

pop_nsh action is no the last one and thus the NSH fields are not copied
correctly

Change-Id: I8f0d8429709cf287989eee803fcc334113967a6d
Signed-off-by: Manuel Buil <[email protected]>
7 years agoBug 5995: remove org.json 40/46140/4
Stephen Kitt [Fri, 23 Sep 2016 16:31:50 +0000 (18:31 +0200)]
Bug 5995: remove org.json

Nothing appears to use org.json any more in SFC, remove it.

Change-Id: If7d9e909a5ad7e93c1a1f894bde6df7754cb6dc8
Signed-off-by: Stephen Kitt <[email protected]>
7 years agoMigrating SFC Nitrogen to Karaf4 36/58236/9
Brady Johnson [Mon, 5 Jun 2017 11:19:17 +0000 (13:19 +0200)]
Migrating SFC Nitrogen to Karaf4

- Removing Karaf3 features configuration

Change-Id: I5cfda9d9898b3d0acd909df3cb63b45aadda66c5
Signed-off-by: Brady Johnson <[email protected]>
Signed-off-by: Stephen Kitt <[email protected]>
7 years agoMigrate to odlparent 1.9.0 79/58879/1
Thanh Ha [Tue, 13 Jun 2017 20:28:50 +0000 (16:28 -0400)]
Migrate to odlparent 1.9.0

Change-Id: I473b4304f9ace966bdf64eb17b4d1b4b35d4b9a1
Signed-off-by: Thanh Ha <[email protected]>
7 years agoMigrate to odlparent 1.8.0-Carbon 76/58676/1
Thanh Ha [Sun, 11 Jun 2017 03:55:33 +0000 (23:55 -0400)]
Migrate to odlparent 1.8.0-Carbon

Per request of odlparent project we are downgrading all Nitrogen
projects to use the released odlparent 1.8.0-Carbon to allow for the
odlparent project to start performing semver style releases.

Change-Id: Idaadab64a3c227ba6df9acb50607a77b4fd9e5b2
Jira: RELENG-159
RT: 41406
Signed-off-by: Thanh Ha <[email protected]>
7 years agoFix minor issues 13/57813/3
David Suarez [Thu, 25 May 2017 13:20:28 +0000 (15:20 +0200)]
Fix minor issues

Fix some minor issues like:
- Useless assignments
- Local variables not used
- Missing logging for some exceptions
- Readability issues

Change-Id: Ibf294ef4d8a69a93869a9505291cf9daf17535a9
Signed-off-by: David Suarez <[email protected]>
7 years agoRemove redundant modifier 95/57895/1
David Suarez [Fri, 26 May 2017 09:17:57 +0000 (11:17 +0200)]
Remove redundant modifier

Remove redundant modifier.

Change-Id: I2630144ec06123b223b891f4f21412b6af783999
Signed-off-by: David Suarez <[email protected]>
8 years agoRemove <prerequisites><maven> from pom.xml to avoid WARNING 08/56808/1
David Suarez [Wed, 10 May 2017 21:53:32 +0000 (23:53 +0200)]
Remove <prerequisites><maven> from pom.xml to avoid WARNING

[WARNING] The project ... uses prerequisites which is only intended for
maven-plugin projects but not for non maven-plugin projects. For such
purposes you should use the maven-enforcer-plugin. See
https://maven.apache.org/enforcer/enforcer-rules/requireMavenVersion.html

This is already done in odlparent.

Change-Id: I5837047b6a940c91155e7f8f6871fcbbd335a75b
Signed-off-by: David Suarez <[email protected]>
8 years agoBUG 8367 (2): Avoid certain unicode chars from random test input 82/56782/2
Diego Granados [Wed, 10 May 2017 11:04:56 +0000 (13:04 +0200)]
BUG 8367 (2): Avoid certain unicode chars from random test input

A new subtle, random problem was detected in autorelease. Full
unicode space use in the random test input generation has been
removed (really hard to do well; makes junit fail all the time)
Now, random standard characters / numbers are used instead.

Change-Id: If7b1298f368c6fdffc701173b616c1f83b9def99
Signed-off-by: Diego Granados <[email protected]>
8 years agoBUG 8367. Avoid certain unicode chars from random test input 05/56505/3
Diego Granados [Thu, 4 May 2017 08:18:31 +0000 (10:18 +0200)]
BUG 8367. Avoid certain unicode chars from random test input

Avoid randomly-generated test input from containing certain
unicode characters (in the private-unassigned ranges) which
cause trouble with some regexps internally used by junit
Parameterised test runner

Change-Id: Iaa0fa034f40c7084f5485d70685e985e0b082c9b
Signed-off-by: Diego Granados <[email protected]>
8 years agoBUG 8316: non-NSH packets should be redispatched 72/56172/1
Manuel Buil [Wed, 26 Apr 2017 15:21:51 +0000 (17:21 +0200)]
BUG 8316: non-NSH packets should be redispatched

SFC is the first serviced registered for the SFs interfaces. If packets do not
have NSH, they should be sent back to the dispatcher table so that they can be
processed by other services. However, right now they are dropped in table 83.

Change-Id: I15bb49bfaaf0f1956c3238243cbeed210342d6cc
Signed-off-by: Manuel Buil <[email protected]>
8 years agoComplete the README of dovs 27/55727/6
Manuel Buil [Thu, 20 Apr 2017 12:10:54 +0000 (14:10 +0200)]
Complete the README of dovs

I added the SFC instructions which were not included

Change-Id: I942e3b64c49df440a4a8711267885531ad50087f
Signed-off-by: Manuel Buil <[email protected]>
8 years agoBUG 8249 Correctly handle Logical SFF Chain egress 03/55703/4
Brady Johnson [Thu, 20 Apr 2017 07:40:44 +0000 (09:40 +0200)]
BUG 8249 Correctly handle Logical SFF Chain egress

- If NSH C1 is present, then write C1/C2 to Ipv4TunDst/Vnid
- Minor fix for UT
- When NSH C1 is present, also egress to Vxgpe flow-based tunnel

Change-Id: Ia149c30850c7e55bb7bcd678f73d217ff7231a76
Signed-off-by: Brady Johnson <[email protected]>
8 years agoFix checkstyle problems not detected by the current version 81/55681/1
David [Wed, 19 Apr 2017 22:58:59 +0000 (00:58 +0200)]
Fix checkstyle problems not detected by the current version

This change is required for overall move to new Checkstyle version, see
https://git.opendaylight.org/gerrit/#/q/topic:bumpCheckstyle

Change-Id: I637dd46617ca144f0ed33bd705c6357493b887fe
Signed-off-by: David <[email protected]>
8 years agoBump versions by x.(y+1).z for next dev cycle 21/54721/1
Anil Belur [Tue, 11 Apr 2017 01:45:55 +0000 (11:45 +1000)]
Bump versions by x.(y+1).z for next dev cycle

Change-Id: I3205e3d12d13531d3bd68751d0c49d09892188c6
Signed-off-by: Anil Belur <[email protected]>
8 years agoFix wait for parent interface and device-id 01/54601/1
Jaime Caamaño Ruiz [Mon, 10 Apr 2017 13:45:12 +0000 (15:45 +0200)]
Fix wait for parent interface and device-id

- Do not wait for parent interface if not using ODL.
- Add device-id to neutron ports of guest namespaces, use port uuid as
  value for now.

Change-Id: Ic8fd0b00b6d927e1054cf83e96a85366e9fb1c8d
Signed-off-by: Jaime Caamaño Ruiz <[email protected]>
8 years agoBug 4628: Name sfc-vnfm-tacker configfile 62/54262/1
Vratko Polak [Mon, 3 Apr 2017 12:12:23 +0000 (14:12 +0200)]
Bug 4628: Name sfc-vnfm-tacker configfile

Also, add dependency to feature poms.

Change-Id: Id05a5f8014ef8692925837cabec3ccd286502093
Signed-off-by: Vratko Polak <[email protected]>
8 years agoAdd execution permissions to setup_sh_hhe.sh 25/54025/2
Jaime Caamaño Ruiz [Wed, 29 Mar 2017 10:03:02 +0000 (12:03 +0200)]
Add execution permissions to setup_sh_hhe.sh

Fixes the 'Permission denied' error when bringing up the sfc-docker
vagrant.

Change-Id: Ie0ad555b7c47fb19bf21923a2b59fa19f2262763
Signed-off-by: Jaime Caamaño Ruiz <[email protected]>
8 years agoMigrate features to Karaf4 50/53350/3
Juan Vidal [Tue, 14 Mar 2017 14:23:51 +0000 (14:23 +0000)]
Migrate features to Karaf4

 - Move old features folder to features/features-sfc
 - Create new features4-sfc folder for Karaf4 pom.xml
 - Create module-specific folders with their respective pom.xml files

Bug: 7629 - Karaf 4 migration: provide Karaf 4 sfc features

Change-Id: I7b5126780b1ae463bd416eeecbd0def18fa2a44e
Signed-off-by: Juan Vidal <[email protected]>
8 years agoadd Mininet wrapper to create SFC topologies and add a MAC Chaining demo 85/53985/3
Rafael [Tue, 28 Mar 2017 14:28:22 +0000 (11:28 -0300)]
add Mininet wrapper to create SFC topologies and add a MAC Chaining demo

Change-Id: I373c66eaeb5f045c15b645209e03236a3ff232d1
Signed-off-by: Rafael <[email protected]>
8 years agoadd mac chaining implementation as a new SFC OpenFlow Renderer 95/53695/4
Rafael [Wed, 22 Mar 2017 20:38:43 +0000 (17:38 -0300)]
add mac chaining implementation as a new SFC OpenFlow Renderer

- Fix minor review issues and add unit tests for mac chaining processor
Change-Id: I309f1c641160ea16f945bea84aeabead6d2be8b7
Signed-off-by: Rafael <[email protected]>
8 years agoAlign dovs to latest carbon updates 50/51950/4
Jaime Caamaño Ruiz [Thu, 16 Feb 2017 11:46:20 +0000 (12:46 +0100)]
Align dovs to latest carbon updates

- check parent interface after ovs tap add
- use a segmentation id other than 0

Change-Id: I9a36dbf835c5725daba47d67d01c4c7287161427
Signed-off-by: Jaime Caamaño Ruiz <[email protected]>
8 years agoDeclare private constructors for utility classes 80/53580/3
David [Mon, 20 Mar 2017 21:02:28 +0000 (22:02 +0100)]
Declare private constructors for utility classes

Minor change: Declare private constructors for utility classes and make
those classes final.

Change-Id: I6ac71e1283623c8cf20f045eecea7b8fb7fb3178
Signed-off-by: David <[email protected]>
8 years agoFix minor issues related to types boxing and unboxing 65/53465/1
David [Fri, 17 Mar 2017 08:28:48 +0000 (09:28 +0100)]
Fix minor issues related to types boxing and unboxing

Fix minor issues related to types boxing and unboxing.

Change-Id: I0b26d3f59c5131831e6cedf42b59ab76732df9bc
Signed-off-by: David <[email protected]>
8 years agoRemove duplicate declaration of itm-api in sfc-genius 38/53238/4
Juan Vidal [Mon, 13 Mar 2017 17:07:23 +0000 (17:07 +0000)]
Remove duplicate declaration of itm-api in sfc-genius

Change-Id: I6f3a848c3b79fcc001d6c99df45e8fb665bcc5c0
Signed-off-by: Juan Vidal <[email protected]>
8 years agosfc-vnfm-tacker checkstyle enforcement 77/52877/6
Faseela K [Wed, 8 Mar 2017 04:56:00 +0000 (10:26 +0530)]
sfc-vnfm-tacker checkstyle enforcement

Fix issues related to checkstyle compliance in module
sfc-vnm-tacker:
- Copyright sections
- Line lengths
- Declaration of constants: name, modifiers
- Formatting
- Rename variables
- Move declaration of variables closer to their use
- Exception catching
- printStackTrace()
- Remove unused variables
- Enforcement in pom.xml

Change-Id: Ia6e917833a4f060ae23d83f4aca0e9487b3a0b10
Signed-off-by: Faseela K <[email protected]>
8 years agoadd api changes needed by MAC Chaining implementation 01/52901/6
Rafael [Mon, 6 Mar 2017 17:20:15 +0000 (14:20 -0300)]
add api changes needed by MAC Chaining implementation

Change-Id: I28e47335e3c42efea363de93c442aa67bd636a4a
Signed-off-by: Rafael <[email protected]>