netvirt.git
7 years agoBug 9226: VPN Traffic fails after VM Migration 95/63795/4
Vivekanandan Narasimhan [Thu, 28 Sep 2017 17:39:36 +0000 (23:09 +0530)]
Bug 9226: VPN Traffic fails after VM Migration

Fixes the way we handle prefix-to-interface for VM Migration.

For more information please review the comment lines added in the
patch.

Change-Id: Ib6412f8ef53fcb3c460546332cdd44b2ec19a15d
Signed-off-by: Vivekanandan Narasimhan <n.vivekanandan@ericsson.com>
7 years agoBug 9237 - NPE: InternalToExternalPortMapKey 17/63917/3
Sam Hague [Tue, 3 Oct 2017 18:43:36 +0000 (14:43 -0400)]
Bug 9237 - NPE: InternalToExternalPortMapKey

Change-Id: I40f0e07d11540480163cde2e15ec6e22583e4845
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoBug 9180: Conflicting modification Exception from NAT Module 09/63909/2
karthikeyan [Mon, 25 Sep 2017 12:04:25 +0000 (17:34 +0530)]
Bug 9180: Conflicting modification Exception from NAT Module

Problem Description:
====================
The following runtime exceptions was throwing from NAT module as part of
"adding external router gateway set" in CSIT.

Exception 1:
============
Conflicting modification for path
/(urn:opendaylight:inventory?revision=2013-08-19)nodes/node/node[{(urn:opendaylight:inventory?revision=2013-08-19)id=openflow:264442126811301}]
[{(urn:opendaylight:flow:inventory?revision=2013-08-19)id=81}]/flow/flow[{(urn:opendaylight:flow:inventory?revision=2013-08-19)id=Arp:tbl_81:lport_11:tpa_10.10.10.3}]

Exception 2:
============
Conflicting modification for path
/(urn:opendaylight:inventory?revision=2013-08-19)nodes/node/node[{(urn:opendaylight:inventory?revision=2013-08-19)id=openflow:264442126811301}]
[{(urn:opendaylight:flow:inventory?revision=2013-08-19)id=19}]/flow/flow[{(urn:opendaylight:flow:inventory?revision=2013-08-19)id=fa:16:3e:ce:fd:00.100003.2644421268113
01.19}]

Solution:
==========
When we do router gateway set for external network, below same flows are
getting installed from two different NAT module listeners which is
causing this runtime "Conflicting modification" exceptions.

1) L3_GW_MAC_TABLE (19) -> L3_FIB_TABLE (21) with external router GW MAC
and
External router vpn-id as match criteria.

2) ARP_RESPONDER_TABLE (81) -> EGRESS_LPORT_DISPATCHER_TABLE (220) with
external router GW MAC in ARP Responder flow.

handleRouterGwFlows() method is commented out in ExternalRoutersListener
add() method alone.
Since the same action is taken care by CentralizedSwitchChangeListener
which is listening on DS "odl-nat:napt-switches".

Change-Id: I2dece791d639b243689f24c112bf6250029de019
Signed-off-by: karthikeyan <karthikeyan.k@altencalsoftlabs.com>
Signed-off-by: cgowdru <chetan.arakere@altencalsoftlabs.com>
Signed-off-by: karthikeyan <karthikeyan.k@altencalsoftlabs.com>
7 years agoBUG 7596 - Update to handle change in Neutron Network external attribute 18/61218/10
Vinh Nguyen [Sat, 5 Aug 2017 00:11:53 +0000 (17:11 -0700)]
BUG 7596 - Update to handle change in Neutron Network external attribute

Changes to handle update event when Neutron Network changes
from non-external to external and vice versa

Change-Id: I2c55272dc6e2b8473f2666b39e36b65c7e578cf0
Signed-off-by: Vinh Nguyen <vinh.nguyen@hcl.com>
7 years agoRemove unneeded mdsal and yangtools artifacts 11/63911/1
Sam Hague [Mon, 2 Oct 2017 16:58:49 +0000 (12:58 -0400)]
Remove unneeded mdsal and yangtools artifacts

Change-Id: Idc837885ce8e20cc0e69d79557e8151cd977c368
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoRemove unneeded pom version values 81/63881/1
Sam Hague [Mon, 2 Oct 2017 15:21:31 +0000 (11:21 -0400)]
Remove unneeded pom version values

Change-Id: I3cce922c5bbb60220f977d5f6ceb26baffb5a698
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoUndo incorrect code changes made during merge conflict. 89/63789/2
eupakir [Thu, 28 Sep 2017 06:20:57 +0000 (11:50 +0530)]
Undo incorrect code changes made during merge conflict.

A part of the fix  pushed in by https://git.opendaylight.org/gerrit/#/c/59229
was removed unintentionally in
https://git.opendaylight.org/gerrit/#/c/57978 .
This has been rectified.

Change-Id: I19372961a30c18a454cd359138190e49d5ab7769
Signed-off-by: eupakir <kiran.n.upadhyaya@ericsson.com>
7 years agoBug 9066:Use Single Transaction for DNAT Flow Install and Remove 59/63259/4
karthikeyan [Tue, 29 Aug 2017 09:56:28 +0000 (15:26 +0530)]
Bug 9066:Use Single Transaction for DNAT Flow Install and Remove

Problem Description:
===================
Use one transaction for DNAT flow install and use another single
transaction for Removing the flows from DNAT switch.

As of now each DNAT (Floating-ip) flow installation, it used separate
transaction object for each flow installation.

Solution:
==========
Used single write transaction object for all DNAT(Floating-IP) flows installation on
the switch and used other
write transaction object for removing all DNAT flows on the switch.

Change-Id: Idf8f0c9ce36b20b14ede9a423c574ee21f36d02e
Signed-off-by: karthikeyan <karthikeyan.k@altencalsoftlabs.com>
7 years agoBug 9077: Fix of issue that the existing NW communication failure when new NW is... 15/63015/3
kaoru sueda [Tue, 12 Sep 2017 05:41:06 +0000 (14:41 +0900)]
Bug 9077: Fix of issue that the existing NW communication failure when new NW is created

Issue:
  The existing network communication failed after 1001 NWs were created,
  as some of its ovs flows were overwritten.

Cause of this issue:
  In NW creation, some ovs flows' ID were duplicated. The flow ID of the
  1001th network is duplicated with the flow ID of the 1st NW, resulting
  the flow of the 1st NW being deleted(overwritten).

Fix:
  Avoid duplication by appending flow name.

Change-Id: I657d35d52b3fe452097294e7b3517aacf75f2fac
Signed-off-by: kaoru sueda <k-sueda@zj.nes.jp.nec.com>
7 years agoLower log level for non errors 74/63774/1
Sam Hague [Thu, 28 Sep 2017 12:13:26 +0000 (08:13 -0400)]
Lower log level for non errors

Change-Id: Ifd2993d7dc4ad97281bcc889157d1ca43be671e2
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoBug 9209: PNF learned on external networks to skip local FIB Processing 35/63535/4
Vivekanandan Narasimhan [Tue, 26 Sep 2017 17:41:27 +0000 (23:11 +0530)]
Bug 9209: PNF learned on external networks to skip local FIB Processing

PNFs learned on external network will not have any specific DPNID
tagged to them.  As a result, we need to skip local flow processing
for such entries.

The external subnet gateway ip is now learned via the PNF code.

Change-Id: I43f254b05949f0e13e5555f622cd7f9866d7856d
Signed-off-by: Vivekanandan Narasimhan <n.vivekanandan@ericsson.com>
7 years agoRenamed acl-impl.rst to acl-reflection-on-existing-traffic.rst 70/63270/3
Somashekar Byrappa [Tue, 19 Sep 2017 06:59:16 +0000 (12:29 +0530)]
Renamed acl-impl.rst to acl-reflection-on-existing-traffic.rst

+ Updated index.rst file with the same name.

Change-Id: I002053111689c84ea515d047c6802d32dcf9504d
Signed-off-by: Somashekar Byrappa <somashekar.b@altencalsoftlabs.com>
(cherry picked from commit bf2178cb6ddc29b5293a9cfa51b3a8da6d086c0d)

7 years agoRemove explicit default super-constructor calls 16/63616/2
David Suarez [Wed, 27 Sep 2017 08:31:23 +0000 (10:31 +0200)]
Remove explicit default super-constructor calls

The default constructor is called by default (hence its name), no need
to call it explicitly. Based on this commit [1].

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

Change-Id: Ia7a4ccf88c328aab9feade1252a06e2c94b660ac
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
(cherry picked from commit d95ada0a7de3692f8d732fc2885045c3b2cf3d0b)

7 years agobug-9190: NullPointerException at getIsExternal 83/63583/2
Sam Hague [Tue, 26 Sep 2017 21:54:23 +0000 (17:54 -0400)]
bug-9190: NullPointerException at getIsExternal

Change-Id: I2e95c71594798431259f10631cef514ef410c199
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoLower log level for non errors 05/63605/2
Sam Hague [Tue, 26 Sep 2017 21:51:28 +0000 (17:51 -0400)]
Lower log level for non errors

Change-Id: I7108bb53268bf5d2513b44117d9755cf62c5aaac
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoBug9091 : Removing uncessary MD-SAL Read Operation in NAT 89/63589/2
cgowdru [Tue, 5 Sep 2017 11:24:40 +0000 (16:54 +0530)]
Bug9091 : Removing uncessary MD-SAL Read Operation in NAT

Description : It's been obseved many unnecessary MD-SAL read operations
where done in NAT module. Changes done to pass them as parameters to
calling methods instead reading the same data again which is already
retrieved earlier in it caller methods.

Change-Id: If5efc57a0342caa6acf73b3f17dba033cab77e7c
Signed-off-by: cgowdru <chetan.arakere@altencalsoftlabs.com>
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agobgpmanager: change API of bgpmanager to add VRF IPv4 or IPv6 88/63588/1
Philippe Guibert [Mon, 29 May 2017 09:45:00 +0000 (10:45 +0100)]
bgpmanager: change API of bgpmanager to add VRF IPv4 or IPv6

This change adds a change in IBgpManager API, since it adds afi and safi
parameters to VRF creation and deletion. This information is propagated
to BGP so as to create and delete VPN context tables in function of the
AFI and SAFI settings.
Instead of passing a layerType value, an AddressFamily type is used.
AddressFamily is mapped to internal afi/safi values.
The values are appended or removed to the VRF objects of BGP Manager.
The VRF object is then written to the config DS.
Subsequently, the Quagga will be called upon the various changes in the VRF object.
If the object is added or updated, the Quagga will be called with the appropriate
afi/safi values. If the object is removed, all the afi/safi values are removed from
the Quagga. If the object is added, the afi/safi values are added to the quagga.

Change-Id: Ife754ce561f69dbb67fcdf74308b5153cbde53e6
Signed-off-by: Valentina Krasnobaeva <valentina.krasnobaeva@6wind.com>
Signed-off-by: Noel de Prandieres <prandieres@6wind.com>
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
7 years agoneutronvpn: create ipv4 or ipv6 context 87/63587/1
Philippe Guibert [Wed, 20 Sep 2017 10:03:50 +0000 (11:03 +0100)]
neutronvpn: create ipv4 or ipv6 context

Add ipv4Family and ipv6Family attributes to VPN instance. Add
IpVersionChoice class, which allows to set values for these attributes
in dependency of Ethertype of added/removed to VPN subnet.

Change-Id: If5ea1a0a29d31388d7898b9e6e53bdc4aecb1cbe
Signed-off-by: Valentina Krasnobaeva <valentina.krasnobaeva@6wind.com>
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Signed-off-by: Noel de Prandieres <prandieres@6wind.com>
7 years agoDualstack support for L3VPN - single router Dual stack 85/60185/14
Philippe Guibert [Tue, 11 Jul 2017 12:40:15 +0000 (13:40 +0100)]
Dualstack support for L3VPN - single router Dual stack

According to dualstack specification [0], this commit introduces changes
related to "one router solution" case.

* NeutronPortChangeListener: Create only one VPN interface instance
  for one neutron port. This instance can include a list of IPv4 and/or
  IPv6 subnetMaps, where addresses where allocated for spawned port.

* NeutronvpnManager: in createVpnInterface we no longer use routerId as
  argument, instead we will iterate over all port IP addresses to create
  according adjacencies objects and than, we pass composed adjacencies
  list to writeVpnInterfaceToDs method.

Change-Id: I5f527be0ebea8f1a74e9a790aa9c3fec6291bda7
Signed-off-by: Valentina Krasnobaeva <valentina.krasnobaeva@6wind.com>
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Signed-off-by: Noel de Prandieres <prandieres@6wind.com>
Signed-off-by: Sam Hague <shague@redhat.com>
(cherry picked from commit aea0c1d4aa344551928fab24bcbddc5c170fd087)

7 years agoBug 8953 - IllegalArgumentException: vrfEntry is missing mandatory 84/63484/3
eupakir [Mon, 25 Sep 2017 10:02:06 +0000 (15:32 +0530)]
Bug 8953 - IllegalArgumentException: vrfEntry is missing mandatory
descendant origin

Change-Id: I0978d55f09d0e9b31aa2b74e5cfac68a757c29da
Signed-off-by: eupakir <kiran.n.upadhyaya@ericsson.com>
7 years agolower log levels for non-errors 16/63516/3
Sam Hague [Mon, 25 Sep 2017 22:06:18 +0000 (18:06 -0400)]
lower log levels for non-errors

Change-Id: I417085e3a9547b03ffe2c74285bf8af2746d461e
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoClearBgpCli reads from socket to send/receive from bgpd 17/63517/1
Siva Kumar Perumalla [Mon, 25 Sep 2017 23:41:32 +0000 (05:11 +0530)]
ClearBgpCli reads from socket to send/receive from bgpd
(some previous commit modifed to read from session parameters)

Change-Id: Id0f4e8294e239fee70d6b09d891d50c5c6a9237a
Signed-off-by: Siva Kumar Perumalla <sivakumar.perumalla@ericsson.com>
7 years agoBug 9196 - Maxpath value should be between 1 to 64 in BGP multipath 33/63433/2
Gowri R [Thu, 21 Sep 2017 11:50:39 +0000 (17:20 +0530)]
Bug 9196 - Maxpath value should be between 1 to 64 in BGP multipath

Adding a check to ensure maxpath value for BGP multipath is in the range 1
to 64

Change-Id: I03786726053672d04b8ef552cb16cc45a9c4a840
Signed-off-by: Gowri R <gowri.r@ericsson.com>
(cherry picked from commit 0f1503f59962293a5bcdbe1e2a6adfc9b8afa1a6)

7 years agoBug 8963 - Option to configure EVPN address family 40/63440/2
Yugandhar Reddy Kaku [Tue, 5 Sep 2017 12:27:04 +0000 (17:57 +0530)]
Bug 8963 - Option to configure EVPN address family

evpn can  be configured as neighbor from karaf CLI with command bgp-nbr
In the bgp-nbr command, for supported address families, vpnv4 is added as
it was missing.

Change-Id: I9d8854c9a7a05f1a48836f0ae88c7934b31a14be
Signed-off-by: Yugandhar Reddy Kaku <yugandhar.reddy.kaku@ericsson.com>
7 years agobgpmanager thrift upgrade to 0.9.3 37/63437/1
Siva Kumar Perumalla [Mon, 18 Sep 2017 12:34:32 +0000 (18:04 +0530)]
bgpmanager thrift upgrade to 0.9.3

Change-Id: I5154fc5b3522313b30d647b68ed37dfd9e02f9ca
Signed-off-by: Siva Kumar Perumalla <sivakumar.perumalla@ericsson.com>
7 years agoBUG 8930 - delete Op VPN interface when deleting external network 12/61512/3
Vinh Nguyen [Thu, 10 Aug 2017 19:26:24 +0000 (12:26 -0700)]
BUG 8930 - delete Op VPN interface when deleting external network

Op VPNInterafce is removed in VrfEntryListener when the last
adjacency for the VPNInterface is removed.
The problem is VPN interface for external network doesn't
have any adjacency nor VrfEntry.
As a result, when the external Vpn interface is removed
the Op VpnInstance is not removed as it should.

Fix: Delete the Op VPN interface in VpnInterfaceManager
if the VPN interface to be deleted doesn't have any adjacency

Change-Id: Ice4b9fcb0103c6aff25053cc5b3db3b01311be06
Signed-off-by: Vinh Nguyen <vinh.nguyen@hcl.com>
7 years agoelanmanager: clean up Futures collections 76/63376/3
Stephen Kitt [Mon, 11 Sep 2017 16:29:58 +0000 (18:29 +0200)]
elanmanager: clean up Futures collections

This patch replaces lists of Futures with singleton lists where
possible. It also removes instances of passing such lists around,
using return values instead.

This patch also cleans up the job classes generally: instance fields
are final where possible, unused fields and parameters are removed.

Change-Id: I8db42f96867b61e46eaf229f95d06c7f6b6249f0
Signed-off-by: Stephen Kitt <skitt@redhat.com>
7 years agoBug 9193 - In conntrack SNAT , flows are programmed twice on a router 08/63408/2
Aswin Suryanarayanan [Wed, 20 Sep 2017 18:00:32 +0000 (23:30 +0530)]
Bug 9193 - In conntrack SNAT , flows are programmed twice on a router
g/w set.

Check is added in RouterDpnChangeListener to check if the port added is
th pseudo router interface and prevent the notification.

Fixed an exception caused by not creating VNI pool.

Change-Id: I6f5fd8f6bd35c37346a2d7780eaf0d49b2fe92cb
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
7 years agoLower log levels for non error's 87/63387/3
Sam Hague [Wed, 20 Sep 2017 21:44:04 +0000 (17:44 -0400)]
Lower log levels for non error's

Change-Id: Ia60e0b8bc87182cc2e4ac6611b77b0f421947da9
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoIfMgr clean-up 90/63390/2
Stephen Kitt [Fri, 15 Sep 2017 15:29:05 +0000 (17:29 +0200)]
IfMgr clean-up

* Avoid calling overridable methods in the constructor.
* Initialise fields in the declaration.
* Remove unused parameters.
* Remove null checks after new, new never returns null.
* Remove unnecessary return statements.
* Remove end-of-method null assignments for local variables.
* Use Map methods to simplify processing.
* Fix a couple of invalid null-handling constructs.

Change-Id: I144268785df2b648daa487c1eb8c63877dd13325
Signed-off-by: Stephen Kitt <skitt@redhat.com>
7 years agoRestrict NeutronvpnUtils.read 89/63389/2
Stephen Kitt [Tue, 5 Sep 2017 14:56:22 +0000 (16:56 +0200)]
Restrict NeutronvpnUtils.read

As a first step towards removing NeutronvpuUtils.read, replace all
external uses with SingleTransactionDataBroker.syncReadOptional and
adjust the exception handling accordingly (which also allows us to
clean up a number of disabled Checkstyle warnings).

Change-Id: Ibad4aa194657cdb8c56ccd993c9182dbf4225f02
Signed-off-by: Stephen Kitt <skitt@redhat.com>
7 years agoBUG 8969 - Fix Exeption when clearing external router GW 23/61723/4
Vinh Nguyen [Mon, 14 Aug 2017 22:19:11 +0000 (15:19 -0700)]
BUG 8969 - Fix Exeption when clearing external router GW

When clearing the router GW, the flow entry for router GW
on the NAPT primary switch is also removed.
Exception occurs when we try to delete the router GW
but there is no NAPT primary switch.

Fix: check for existence of NAPT primary switch
before deleting the router GW flow on the switch.
Also downgrade ERROR to DEBUG log level when primary
NAPT switch can not be found since this could
happen when no internal network attaches to the router yet.

Change-Id: I7ebc0d60183954044aeb8a4e8f062b4d227f6c76
Signed-off-by: Vinh Nguyen <vinh.nguyen@hcl.com>
7 years agobug-9190: NullPointerException at getIsExternal 43/63343/2
Sam Hague [Wed, 20 Sep 2017 15:29:16 +0000 (11:29 -0400)]
bug-9190: NullPointerException at getIsExternal

Change-Id: If79a282989206bafe8d6c90e1bc089d820d6f0d2
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoBug 9105: close removeElanInterface transaction 70/63370/2
Stephen Kitt [Tue, 12 Sep 2017 08:54:22 +0000 (10:54 +0200)]
Bug 9105: close removeElanInterface transaction

Cancel the interface transaction if we return early from
removeElanInterface. Initialise the flow transaction after the early
return so we don’t need to handle it specially.

Change-Id: I317925cef806c792038299b74d73f18861e40bd8
Signed-off-by: Stephen Kitt <skitt@redhat.com>
7 years agoElanUtils clean-up: ElanL2GatewayUtils 86/63386/1
Stephen Kitt [Thu, 27 Jul 2017 15:07:26 +0000 (17:07 +0200)]
ElanUtils clean-up: ElanL2GatewayUtils

This patch initialises ElanL2GatewayUtils using BluePrint. This
involves adding static variants to a small number of methods in order
to break the dependency cycle involving ElanInstanceManager,
ElanInterfaceManager, ElanUtils and ElanL2GatewayUtils.

Change-Id: Icf17e0fb7683b871b8246b148d905e51bad4e598
Signed-off-by: Stephen Kitt <skitt@redhat.com>
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoElanUtils clean-up: L2GatewayConnectionUtils 85/63385/1
Stephen Kitt [Thu, 27 Jul 2017 13:48:02 +0000 (15:48 +0200)]
ElanUtils clean-up: L2GatewayConnectionUtils

This turns L2GatewayConnectionUtils into a self-carrying bean, instead
of relying on ElanUtils to initialise it.

Change-Id: I2c5c8330e57a46048651a1f6b656fb34b099afe3
Signed-off-by: Stephen Kitt <skitt@redhat.com>
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoElanUtils clean-up: remove unnecessary references 84/63384/1
Stephen Kitt [Thu, 27 Jul 2017 08:29:38 +0000 (10:29 +0200)]
ElanUtils clean-up: remove unnecessary references

A number of classes reference ElanUtils instances even though they no
longer need them, or they call static methods via an instance. This
patch cleans them up.

Change-Id: I29bf1454e7a56ac474ef9198a48114b0b0447aea
Signed-off-by: Stephen Kitt <skitt@redhat.com>
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoElanUtils clean-up: ElanL2Gateway{Multicast,}Utils 83/63383/2
Stephen Kitt [Tue, 25 Jul 2017 08:09:47 +0000 (10:09 +0200)]
ElanUtils clean-up: ElanL2Gateway{Multicast,}Utils

Extract various utility methods to ElanDmacUtils, ElanEtreeUtils and
ElanItmUtils, so that ElanL2GatewayMulticastUtils’ dependency on
ElanL2GatewayUtils (which needs to be post-filled after
initialisation) can be removed.

Change-Id: Iec71e32ea61ff1789537bcb1e7e35fa3253f8363
Signed-off-by: Stephen Kitt <skitt@redhat.com>
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoElanUtils clean-up: more ElanL2GatewayMulticastUtils 82/63382/2
Stephen Kitt [Mon, 24 Jul 2017 13:05:53 +0000 (15:05 +0200)]
ElanUtils clean-up: more ElanL2GatewayMulticastUtils

Moving installDpnMacsInL2gwDevice from ElanL2GatewayUtils to
ElanInterfaceManager allows ElanL2GatewayUtils’ dependency on
ElanL2GatewayMulticastUtils to be removed.

Change-Id: I1af5c31f516f4dfe7121c16e797339b60a1d03ca
Signed-off-by: Stephen Kitt <skitt@redhat.com>
7 years agoElanUtils clean-up: ElanL2GatewayMulticastUtils 80/63380/3
Stephen Kitt [Mon, 24 Jul 2017 12:40:56 +0000 (14:40 +0200)]
ElanUtils clean-up: ElanL2GatewayMulticastUtils

elanUtils.getInvolvedDpnsInElan is a very simple wrapper around
elanInstanceManager.getElanDPNByName, which isn’t even needed any more
since the latter never returns null. Using the latter directly in
ElanL2GatewayMulticastUtils means we no longer need ElanUtils there,
which simplifies initialisation (although not perfectly yet because of
the loop between ElanL2GatewayMulticastUtils and ElanL2GatewayUtils).

Change-Id: Ie4ef925d5e0c02e5476141430f844dc2b0a0647e
Signed-off-by: Stephen Kitt <skitt@redhat.com>
7 years agoElanUtils clean-up: make read() static 69/63369/2
Stephen Kitt [Mon, 24 Jul 2017 11:36:16 +0000 (13:36 +0200)]
ElanUtils clean-up: make read() static

It turns out no callers use the variant of read() which relies on
ElanUtils’ own broker, so we can drop that and make read() static,
which reduces the requirement for ElanUtils instances.

Change-Id: I75841497b4247abb9f10c216956ba534bc5068ce
Signed-off-by: Stephen Kitt <skitt@redhat.com>
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoBug 8998 - L2GW:Vlan bindings missing on reboot 21/63021/2
eaksahu [Wed, 16 Aug 2017 12:33:48 +0000 (18:03 +0530)]
Bug 8998 - L2GW:Vlan bindings missing on reboot

Vlan bindings are missing upon cluster reboot.
While processing physical switch node add event , its global node
is not available yet.
Enqueued this job to global node add pending job wait list so that
eventually after the global node is added this gets processed.

Handled the tunnel ip change of the physical switch.
When the tunnel ip changes delete old itm tunnels
create new tunnels with new tunnel ip
retrigger the l2gw connection processing to take affect of the
new tunnel ip.

Handled the local ucast macs that are added to the southbound device
while odl is down.
When odl comes up as part of processing its l2gw connections
it pulls the added local ucast macs from the southbound device.

Change-Id: Id6fdbbfe852a6fc0d89f360eb498fece8f00bdb5
Signed-off-by: eaksahu <a.k.sahu@ericsson.com>
7 years agoaclservice: clean up Futures collections 75/63375/2
Stephen Kitt [Mon, 11 Sep 2017 13:28:30 +0000 (15:28 +0200)]
aclservice: clean up Futures collections

This patch replaces lists of Futures with singleton lists where
possible.

Change-Id: I5d3445c488599f28b920a2296e0d2ab439761a43
Signed-off-by: Stephen Kitt <skitt@redhat.com>
7 years agodhcpservice: clean up Futures collections 71/63371/2
Stephen Kitt [Mon, 11 Sep 2017 14:06:46 +0000 (16:06 +0200)]
dhcpservice: clean up Futures collections

This patch replaces lists of Futures with singleton lists where
possible. It also removes instances of passing such lists around,
using return values instead.

This patch also cleans up the job classes generally: instance fields
are final where possible, unused fields and parameters are removed.

Change-Id: Idd1add34a0ac75aaf7ae0afc137904cebfb7e741
Signed-off-by: Stephen Kitt <skitt@redhat.com>
7 years agoBug 8978 - Network deletion issue. 28/63028/2
eaksahu [Fri, 11 Aug 2017 09:47:18 +0000 (15:17 +0530)]
Bug 8978 - Network deletion issue.

Elaninstance after deletion was clearing l2gateway connection
configuration , but was not deleting l2gatewayConnection object itself
from neutron config tree. This leads to reconfiguration of
l2gatewayconnection upon reboot / device reconnect also.
Fixed the above case.
Added way to cancel logical switch deletion , so that if the same
network is reconfgured while deletion is going on , it can be cancelled.
Calling logical switch delete cancel when associating the same network
to l2gw.

Change-Id: I530c4b87becf3043eb8c4ba03226447731b2db0b
Signed-off-by: eaksahu <a.k.sahu@ericsson.com>
7 years agoRemove un-used SynchronousEachOperationNewWriteTransaction 67/63367/1
Michael Vorburger [Wed, 20 Sep 2017 16:16:00 +0000 (18:16 +0200)]
Remove un-used SynchronousEachOperationNewWriteTransaction

replaced by SingleTransactionDataBroker which is now widely adopted

Change-Id: I09c4f64941bdd4398cbda28d339449b43ba8e10a
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
7 years agocleanup sync 15/63315/2
Sam Hague [Tue, 19 Sep 2017 23:19:48 +0000 (19:19 -0400)]
cleanup sync

Change-Id: I6c712e5efa8bd633356327c5aa31c735d91b4509
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agobug 9018 l2gw designated dhcp fix 19/63319/2
K.V Suneelu Verma [Mon, 21 Aug 2017 11:21:27 +0000 (16:51 +0530)]
bug 9018 l2gw designated dhcp fix

Instead of listening for logical switch creation, listen for
mcast mac creation and update the mcast mac to avoid race of updating the
mcast mac.
while updating mcast mac read the existing mac and add designated dhcp tep
ip to the existing locators.

Change-Id: Id4d99471ae0b3be306a5511ee7cea975606deaa3
Signed-off-by: K.V Suneelu Verma <k.v.suneelu.verma@ericsson.com>
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoBug 8973 : DHCP fixes 17/63317/2
Kency Kurian [Thu, 10 Aug 2017 11:45:23 +0000 (17:15 +0530)]
Bug 8973 : DHCP fixes

1. For SR-IOV vm dhcp request:
After controller restart it was found that the DHCP flows were being installed
as drop on the designated DPN.

Added a check to see if the DPN being added is already a designated DPN
then, drop flows need not be installed.

2. Added a null check for gateway ipaddress and also whenver getIpv4Address
is called.

3. Added a null check for l2gwdevice in installRemoteMCastMac.

Change-Id: I2fae322af07b582fa4e5a03522513976dd2c55e5
Signed-off-by: Kency Kurian <kency.kurian@ericsson.com>
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoFix cloud-servicechain YANG 18/63318/2
Stephen Kitt [Wed, 13 Sep 2017 12:28:55 +0000 (14:28 +0200)]
Fix cloud-servicechain YANG

This corrects the YANG revision, which becomes 160711.

Change-Id: I32b619cc29d89c0d3adb06fc264c3f26c04d50c0
Signed-off-by: Stephen Kitt <skitt@redhat.com>
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoBUG 9014 : Remove unnecessary log statements in VPN Engine 14/63314/2
eupakir [Tue, 22 Aug 2017 05:47:52 +0000 (11:17 +0530)]
BUG 9014 : Remove unnecessary log statements in VPN Engine

Change-Id: I501beac66cc8f9ffc44d5f12b22514d7d3b03d22
Signed-off-by: eupakir <kiran.n.upadhyaya@ericsson.com>
(cherry picked from commit 9f924b40e048ec1967f6a7b2c6d32064f1ea3887)

7 years agoRemove aggregator from artifactId 11/63311/2
Sam Hague [Tue, 19 Sep 2017 22:28:33 +0000 (18:28 -0400)]
Remove aggregator from artifactId

Change-Id: Iad35ffa4987ac0ef8d0bb1b5feedb75a3a70fdc3
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agorm it module 09/63309/2
Sam Hague [Tue, 19 Sep 2017 22:17:03 +0000 (18:17 -0400)]
rm it module

Change-Id: I0865195683a45adcef787365c4e91e217eb7e514
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoBug 8965 - L2gw update is not suported 18/63018/2
eaksahu [Wed, 9 Aug 2017 14:22:09 +0000 (19:52 +0530)]
Bug 8965 - L2gw update is not suported

Currently l2gw once created , no update are on that are supported.
With this patch following use case has been supported.
Update existing l2gw vlanbindings
Update existing l2gw with new ports / device .

It takes care of configuring w.r.t associated l2gwconnection .

Change-Id: I37dda9cf366b1fe59ccf95f64f0574448f156d47
Signed-off-by: eaksahu <a.k.sahu@ericsson.com>
7 years agoBug 7380: service-binding exceptions from ACL 47/63247/3
Vivekanandan Narasimhan [Wed, 30 Aug 2017 16:56:32 +0000 (22:26 +0530)]
Bug 7380:  service-binding exceptions from ACL

Exceptions are thrown when ACL tries to bind/unbind
ports that it's not supposed to handle.

The fix ensures that AclInterfaceStateListener
does not create ACLInterfaces for interfaces
that donot have port-security-enabled.

This also addresses issue observed with a scenario where a neutron port
is created with SG
disabled and was later enabled.

Change-Id: I2b7d6468b36fdc43d4ac1a91c16563d8d675ca3f
Signed-off-by: Vivekanandan Narasimhan <n.vivekanandan@ericsson.com>
Signed-off-by: Sam Hague <shague@redhat.com>
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoBug 8953: Fix exceptions raised due to PNF confused with FIP 73/63273/1
Vivekanandan Narasimhan [Mon, 18 Sep 2017 17:08:38 +0000 (22:38 +0530)]
Bug 8953: Fix exceptions raised due to PNF confused with FIP

Both FIP and discovered PNF IP VrfEntries
use an RD value of external-subnet-id and
thereby the below review resulted in FloatingIP (FIP)
processing being done for PNF incorrectly.
This situation happened vide review:
https://git.opendaylight.org/gerrit/#/c/62957/

In here we fix that confusion, by pushing a new
enumeration to clearly distinguish various type
of prefixes within the prefix-to-interface and use
the same in FibManager (VrfEntryListener) to unambiguously
handle processing for such prefixes (or VrfEntries).

Change-Id: I5143c603d96657e7db0db38a955a4a14f0413e0c
Signed-off-by: Vivekanandan Narasimhan <n.vivekanandan@ericsson.com>
7 years agoBug 9026: ACL issue in handling port-create 35/62935/3
Somashekar Byrappa [Tue, 22 Aug 2017 08:10:27 +0000 (13:40 +0530)]
Bug 9026: ACL issue in handling port-create

Problem:
When a VM is booted by creating a port with commands [1] & [2], ACL
service is bound to the interface which shouldn't have happened as [2]
explicitly sets --port-security-enabled False.

+ During [1], ACL bind service is performed as flag
port-security-enabled=True by default.
+ During [2], ACL unbind service should be performed as flag
port-security-enabled=False is set explicitly. This was not happening.

Solution:
During port-update, ACL unbind service was called only during interface
up. Now this is changed to unbind ACL service irrespective of interface
state (up/down).

Also, handled cache update correctly during port-update.

Commands:
[1] neutron port-create net10 --no-security-groups
[2] neutron port-update <port id> --port-security-enabled False

Change-Id: I73d299fc61e02bee8aafe0370cdf0a4874533ee9
Signed-off-by: Somashekar Byrappa <somashekar.b@altencalsoftlabs.com>
Signed-off-by: Vivekanandan Narasimhan <n.vivekanandan@ericsson.com>
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoBug 8953 - IllegalArgumentException: vrfEntry is missing mandatory 41/63041/3
eupakir [Mon, 11 Sep 2017 10:08:12 +0000 (15:38 +0530)]
Bug 8953 - IllegalArgumentException: vrfEntry is missing mandatory
descendant origin.

Change-Id: I8ac129ae16fdb259fc2c54f3230b67038b9a2530
Signed-off-by: eupakir <kiran.n.upadhyaya@ericsson.com>
(cherry picked from commit b061b817877fe1c529bc0e2d3a0c95b9bbef368c)

7 years agoRemove learn mode from aclserivce. 26/63226/1
Aswin Suryanarayanan [Mon, 18 Sep 2017 10:03:16 +0000 (15:33 +0530)]
Remove learn mode from aclserivce.

Change-Id: Ia85ed76bc753dd67d1ecc5efb9b9aa3a6690151c
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
7 years agoFix exception handling in neutronvpn shell 93/63193/2
Michael Vorburger [Wed, 13 Sep 2017 17:56:57 +0000 (19:56 +0200)]
Fix exception handling in neutronvpn shell

see
https://wiki.opendaylight.org/view/BestPractices/Coding_Guidelines#IllegalCatch

motivated by/while reviewing
https://git.opendaylight.org/gerrit/#/c/62711/3/vpnservice/neutronvpn/neutronvpn-impl/src/main/java/org/opendaylight/netvirt/neutronvpn/NeutronvpnManager.java

Change-Id: I8ebc913e66d2fe33ffadf361214bb82263aec149
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
(cherry picked from commit 72bef67d06d2793aee07979d6ef0df7d715115f0)

7 years agoBug 8860 : Populate elantag at time of elanInstance creation 04/63204/1
Abhinav Gupta [Thu, 14 Sep 2017 09:51:42 +0000 (15:21 +0530)]
Bug 8860 : Populate elantag at time of elanInstance creation

This patch eliminates the delay in elantag being available for use by
SubnetRoute Engine.

Change-Id: I0c3e28758c49d5a600f1213b94172fb532c7a77c
Signed-off-by: Abhinav Gupta <abhinav.gupta@ericsson.com>
7 years agoRemove transparent mode from aclservice. 02/63202/1
Aswin Suryanarayanan [Tue, 8 Aug 2017 07:44:16 +0000 (13:14 +0530)]
Remove transparent mode from aclservice.

Depends on https://git.opendaylight.org/gerrit/#/c/60737/ , which adds
port_security disable tests.

Change-Id: Icf83af877cdf9965b24db38573453a6433d7eca6
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
7 years agoBUG-8893 patch port mysteriously deleted 83/62683/9
Josh [Sun, 27 Aug 2017 10:55:09 +0000 (13:55 +0300)]
BUG-8893 patch port mysteriously deleted

This happens sporadically when br-int exists prior to ODL
managing the OVS node. If the event notifying ElanOvsdbNodeListener
of the existence of the br-int bridge happens BEFORE the event
notifying about the OVS node the following occurs:

1. Netvirt gets event for br-int
2. Writes patch ports
3. Netvirt gets event for the ovs node
4. Creates br-int...which already exists and this over-writes the
   patch ports

Fix:
a) clean up code so that br-int is configured with a controller
   and patch ports only once we receive the notification for br-int
   in operational.
b) when receiving a notification for the OVSDB node in operational,
   check if br-int is in operational. If it is not, create it in
   config.
c) when receiving a notification for br-int in operational, check if it
   is also in config. If it is not, copy br-int fields from operational
   to config. The proceed to step (a).

Change-Id: I11739ccc847e65c4179ff1f73493159bd4effcd2
Signed-off-by: Josh <jhershbe@redhat.com>
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoBug 8964 - Neutron test 38/62938/3
Aswin Suryanarayanan [Fri, 8 Sep 2017 11:52:00 +0000 (17:22 +0530)]
Bug 8964 - Neutron test
neutron.tests.tempest.scenario.test_floatingip.FloatingIpSameNetwork.test_east_west
fails

1)Added FIB(Table21) flow  in NON-NAPT switch to send the traffic  to
the SNAT IP to the NAPT switch over the tunnel.
2)Added Tunnel table(Table 36) in NAPT switch to send the to SNAT IP to
the Inbound SNAT(Table 44) table.

table=21, n_packets=49, n_bytes=4802,
priority=42,ip,metadata=0x30d42/0xfffffe,nw_dst=192.168.56.31
actions=set_field:0x186a1->tun_id,group:225001

table=36, n_packets=22, n_bytes=2156, priority=42,ip,tun_id=0x186a1
actions=load:0x30d42->OXM_OF_METADATA[0..23],resubmit(,44)

Change-Id: I829400a1479752dd9963ac8931ca662f4f51bed2
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
7 years agoSpec for Acl change reflection on existing communication 80/60580/20
vinothb [Thu, 20 Jul 2017 18:06:08 +0000 (14:06 -0400)]
Spec for Acl change reflection on existing communication

Change-Id: Id8b2e3c9bf321248a6e55f6830078b4fd6acde14
Signed-off-by: vinothb <vinothb@hcl.com>
7 years agoRemove deprecated CheckedFuture 93/62993/2
David Suarez [Thu, 7 Sep 2017 19:40:03 +0000 (21:40 +0200)]
Remove deprecated CheckedFuture

Remove deprecated CheckedFuture.

Change-Id: I69b6378867f68e18d69a23c25e14780ad305370c
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
(cherry picked from commit bbfc50ca13ba5b8db07ef27db3acfb49bcaaed4e)

7 years agoRemove unused references to DataChangeListener 60/63060/2
Tom Pantelis [Wed, 30 Aug 2017 01:40:15 +0000 (21:40 -0400)]
Remove unused references to DataChangeListener

Change-Id: I78e8c32bd76536fd420d31b6e7b0bd2b026d7a49
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
(cherry picked from commit 7f9a7a608934fd687748a913706181d165e146ce)

7 years agoBug7380:CSIT FIP ping is getting failed for Ext Flat/VLAN Network 37/63037/2
karthikeyan [Thu, 31 Aug 2017 12:50:21 +0000 (18:20 +0530)]
Bug7380:CSIT FIP ping is getting failed for Ext Flat/VLAN Network

Problem Description:
=======================
FIP Ping TC is getting failed for external FLAT/VLAN network on single
node setup.

For Single node setup VXLAN TEP is not at all required for external
network with provider type as FLAT/VLAN.
Current Implementation on FIP handling, it is
expected nextHop IP should not be null before programming FIP local flow
entry L3_FIB_TABLE (21) -> PDNAT_TABLE (25). This validation is not
required for external provider type as FLAT/VLAN networks.

Solution:
==========
NextHopIP validation is already existing in NatUtil.addPrefixToBGP()
method before FIP advertising to BGP. Hence removing unnecessary
validation from VpnFloatingIpHandler.
This will resolve FIP local flow entry L3_FIB_TABLE (21) -> PDNAT_TABLE
(25) installation on corresponding DPN for external FLAT/VLAN network on
Single Node setup (Without VXLAN TEP Configured)

Change-Id: I6653c78733e037310827ffbcd4498097b19a2abf
Signed-off-by: karthikeyan <karthikeyan.k@altencalsoftlabs.com>
7 years agoBug 9136 - Suspected ReadOnlyTransaction leak in QosNeutronUtils 39/63039/1
A Vamsikrishna [Mon, 11 Sep 2017 03:35:07 +0000 (09:05 +0530)]
Bug 9136 - Suspected ReadOnlyTransaction leak in QosNeutronUtils

Description:

Bug 9136 - Suspected ReadOnlyTransaction leak in QosNeutronUtils

Fix:

Fixed ReadOnlyTransaction leak by using try-with-resources statement for automatic resource management.

Change-Id: Ib4e03a425b840427d7133f40d5a72d4bf5f85605
Signed-off-by: A Vamsikrishna <a.vamsikrishna@ericsson.com>
7 years agoBug 7380: service-binding exceptions from ACL 10/62910/1
Sam Hague [Fri, 8 Sep 2017 13:41:25 +0000 (09:41 -0400)]
Bug 7380: service-binding exceptions from ACL

Change-Id: Ifb4d096bb58bfa5e7670a5b0f2b8718067366c5c
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoRemove stateless mode from AclService. 21/62021/5
Aswin Suryanarayanan [Mon, 7 Aug 2017 09:24:36 +0000 (14:54 +0530)]
Remove stateless mode from AclService.

Change-Id: I6307007ef23c4f58e8c543a22550109d8c778ce4
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoMinor code cleanup in QoS 67/62867/2
Arun Sharma [Wed, 6 Sep 2017 17:28:52 +0000 (22:58 +0530)]
Minor code cleanup in QoS

- Corrected log messages
- Renamed QosAlertEosHandler to QosEosHandler because same eos handler
  is used by QoS service as well.

Change-Id: I160f500ba40ed5cfb471d4023adf04c35cbc7bf2
Signed-off-by: Arun Sharma <arun.e.sharma@ericsson.com>
7 years agoCleanup cherry-pick of 61888 48/62848/3
Sam Hague [Thu, 7 Sep 2017 14:39:44 +0000 (10:39 -0400)]
Cleanup cherry-pick of 61888

Change-Id: I475dc18033f85e41414cc9b8c62b27145d015e00
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoBug 9100 : tx leak in DhcpExternalTunnelManager 63/62863/2
Kency Kurian [Wed, 6 Sep 2017 11:43:17 +0000 (17:13 +0530)]
Bug 9100 : tx leak in DhcpExternalTunnelManager

Change-Id: I14a6ff3310214362fcd51cb36a0ceb509b386ee1
Signed-off-by: Kency Kurian <kency.kurian@ericsson.com>
7 years agoReplace <? extends Object> by <?> 64/62864/2
David Suarez [Thu, 17 Aug 2017 07:50:18 +0000 (09:50 +0200)]
Replace <? extends Object> by <?>

Replace <? extends Object> by <?> since they are equivalent.

Change-Id: I548338da4bbc1da2c7b7401f456d08d74cec5111
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
(cherry picked from commit cf20625b79d9e79ed22d617cd1107b2fa0797865)

7 years agoBug 9012 : BGP not connecting to config server 65/62865/2
Vyshakh Krishnan CH [Thu, 31 Aug 2017 05:54:17 +0000 (11:24 +0530)]
Bug 9012 : BGP not connecting to config server

Issue was there with previos commit where config_server_updated flag was
never set to false. Making it to false at correct place now

Change-Id: I5c49bf02dac8cb66033eb8a38d453ac0922cbca9
Signed-off-by: Vyshakh Krishnan CH <vyshakh.krishnan.c.h@ericsson.com>
7 years agoCluster support for netvirt QoS 14/62714/3
Arun Sharma [Tue, 29 Aug 2017 08:41:49 +0000 (14:11 +0530)]
Cluster support for netvirt QoS

-Changed QoS policy configuration change listeners from
 AsyncDataTreeChangeListenerBase to
 AsyncClusteredDataTreeChangeListenerBase so that all nodes receive
 QoS configuration change notifications.

-Rate limit and DSCP marking is done only by QoS entity owner. Other
 nodes just update the cache. This ensures that cache is always in
 sync between all the nodes.

Change-Id: Id2215e4b98cfcb238c437402a02ece640db11413
Signed-off-by: Arun Sharma <arun.e.sharma@ericsson.com>
7 years agovpnmanager DJC enqueueJob without using AbstractDataStoreJob API 57/62757/2
Michael Vorburger [Wed, 12 Jul 2017 21:34:36 +0000 (03:04 +0530)]
vpnmanager DJC enqueueJob without using AbstractDataStoreJob API

because when we moved genius.DJC to infrautils.JC we had concluded that
this method does not need to be exposed publicly, and (at the time) was
only used in 1 place (here).

In order to be able to eventually remove genius.DJC and switch to
infrautils.JC, adjusting this use to be compatible with the new API is a
first step.

Change-Id: Ia025cc542096ce417b35f57cdc723ebc9528ab14
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
(cherry picked from commit b0f59bfd464a34cd216b7ece1090e05df7f747bd)

7 years agoBUG 9003: Fix classifier entry processing order 40/62840/2
Jaime Caamaño Ruiz [Mon, 14 Aug 2017 17:45:56 +0000 (19:45 +0200)]
BUG 9003: Fix classifier entry processing order

Change-Id: Icfafe3ef3a77bd48e3ddcf249f6c1e41b3e57aa5
Signed-off-by: Jaime Caamaño Ruiz <jaime.caamano.ruiz@ericsson.com>
(cherry picked from commit 8c376c716a8ec01eee8fbfa0990aa46fcabd0c6c)

7 years agoBUG 9003: Fix port chain event triggered two times 41/62841/2
Jaime Caamaño Ruiz [Mon, 14 Aug 2017 17:46:29 +0000 (19:46 +0200)]
BUG 9003: Fix port chain event triggered two times

Change-Id: I4dd83824808d3faa2f515901d9171bb8e812d681
Signed-off-by: Jaime Caamaño Ruiz <jaime.caamano.ruiz@ericsson.com>
(cherry picked from commit db101c10d767b236a15acd653eec8fb53094ed46)

7 years agoBUG: Adapt SFC translator to SFC code in Nitrogen 42/62842/1
Manuel Buil [Thu, 10 Aug 2017 14:47:31 +0000 (16:47 +0200)]
BUG: Adapt SFC translator to SFC code in Nitrogen

BUG: 8966

SFC Translator must start using logical SFF otherwise it will not work

Change-Id: Iec8dd6ae757d230464162dd1612bcda3a8fd0f26
Signed-off-by: Manuel Buil <mbuil@suse.com>
Signed-off-by: Jaime Caamaño Ruiz <jaime.caamano.ruiz@ericsson.com>
(cherry picked from commit 3bc2fda73b17db517e34a7efd864ea5af2100dcf)

7 years agoBUG9094 Bind to last SF interface if origin node 81/62781/2
Jaime Caamaño Ruiz [Fri, 1 Sep 2017 15:11:48 +0000 (17:11 +0200)]
BUG9094 Bind to last SF interface if origin node

If the last SF is in one of the possible origin nodes for the
classified traffic, bind the classifier on it's port. This is to be
to handle the possible scenario where origin, last SF and destination
of traffic are on the same node. On this scenario, SFC on last hop will
not de-encapsulate the traffic, instead it will be handed off to the
dispatcher table for the egress classifier function to handle it. To be
able to do this, it needs to be bound to the last SF port.

Change-Id: I97f60e8cc409ea42c830e408b4df91051b50689c
Signed-off-by: Jaime Caamaño Ruiz <jaime.caamano.ruiz@ericsson.com>
(cherry picked from commit 9509d783b6c9fe5a348e0f39e86b8ae72cc53c3f)

7 years agoBUG9095 Capture SFC tunnel traffic for path egress 83/62783/1
Jaime Caamaño Ruiz [Fri, 1 Sep 2017 17:33:55 +0000 (19:33 +0200)]
BUG9095 Capture SFC tunnel traffic for path egress

On scenarios where origin and destination of traffic are on the same
node, but last SF is on a different node, SFc on last hop will not
de-encapsulate the traffic, instead it will the encpsulated traffic
to the node indicated via IP address on NSH C1 metadata.

There an egress classifier function will handle the traffic. In order
to do this, since port binding in tunnel ports is still not being used
and there is no dispatch service on tunnel ports, this egress
classification function needs to take SFC traffic (VNI=0) with priority
to handle the possible chain egress. If chain egress function is not
applied, it will resubmit this SFC traffic to the SFC pipeline.

The egress classifier function is aslo updated to match SFC traffic on
on the specific ending index of each possible path.

Change-Id: I2c6131b727c17e4a36d2b5fb931c84719f4a077b
Signed-off-by: Jaime Caamaño Ruiz <jaime.caamano.ruiz@ericsson.com>
(cherry picked from commit 64160b249a54deb31cac3021a8343b9b03006a83)

7 years agoBUG 9003: Support source-logical-port acl match 56/62756/2
Jaime Caamaño Ruiz [Mon, 14 Aug 2017 14:21:28 +0000 (16:21 +0200)]
BUG 9003: Support source-logical-port acl match

Neutron flow classifier includes acl matches for source and destination
neutron ports. Added support for source port, and updated the model to
also include destination port although not supported yet.

Change-Id: I83f8cc362869d046cdce756b5cbe4b13215b75f0
Signed-off-by: Jaime Caamaño Ruiz <jaime.caamano.ruiz@ericsson.com>
(cherry picked from commit ef7ca0ab0840c1c7a51de172beb178560ec2291d)

7 years agoReplace size()==0 by isEmpty() 55/62755/2
David Suarez [Wed, 9 Aug 2017 15:08:06 +0000 (17:08 +0200)]
Replace size()==0 by isEmpty()

Replace size()==0 by isEmpty(). It improves readability and avoid "=0".
Based on Change-Id: I4bba45bea95a234734079376c7439395ae38e981

Change-Id: Ibbb75b0525695bbf9be572c9042ed0dab4c9c05e
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoCleanup 54/62754/1
David Suarez [Sun, 3 Sep 2017 14:51:16 +0000 (16:51 +0200)]
Cleanup

- Remove dead code
- Final class & private constructor for utility classes
- Return variables directly
- Add method qualifiers
- Join some if statements

Change-Id: I2ca3cc08cbe10e4885510f9fc6bcb7f684e48922
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
(cherry picked from commit 8f82f79603968deefd1e9b80443588c646075381)

7 years agoBug 9035: - NPE at org.opendaylight.netvirt.elan.arp.responder.ArpResponderUtil.getMa... 84/62484/3
vinothb [Thu, 31 Aug 2017 22:55:58 +0000 (18:55 -0400)]
Bug 9035: - NPE at org.opendaylight.netvirt.elan.arp.responder.ArpResponderUtil.getMatchCriteria

Problem Description:
=======================
The following exception was observed from ArpResponderUtil

Error while installing ARP responder flow
java.lang.NullPointerException
at org.opendaylight.netvirt.elan.arp.responder.ArpResponderUtil.getMatchCriteria(ArpResponderUtil.java:178)[307:org.opendaylight.netvirt.natservice-impl:0.5.0.SNAPSHOT]

Solution:
=========
We need to enhance the pre-condition check in ArpResponderUtil before
installing the flow.

Change-Id: I9558080dc41df15164d2b189168c56c83b63c6ac
Signed-off-by: vinothb <vinothb@hcl.com>
7 years agoAdd missing null check 10/62710/2
Sam Hague [Tue, 5 Sep 2017 14:49:59 +0000 (10:49 -0400)]
Add missing null check

Change-Id: Id57c1555339b65b017cbea548022826abe76680f
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoBug:9013 ElanUtils: RPC Call to Get egress actions for interface, OptimisticLockFaile... 40/62740/2
epgoraj [Tue, 29 Aug 2017 10:51:17 +0000 (16:21 +0530)]
Bug:9013 ElanUtils: RPC Call to Get egress actions for interface, OptimisticLockFailedException

Change-Id: Ib9607a217ff51eeedd92ca9c9c7759d352916aa7
Signed-off-by: epgoraj <p.govinda.rajulu@ericsson.com>
7 years agoBug 9085 - CSIT Sporadic failures - 38/62738/1
Aswin Suryanarayanan [Tue, 5 Sep 2017 08:58:41 +0000 (14:28 +0530)]
Bug 9085 - CSIT Sporadic failures -
test_security_groups_basic_ops.TestSecurityGroupsBasicOps.test_cross_tenant_traffic

Fixing the cause for exception.

Change-Id: I54f9812226be346dee771a0722618edbb9558190
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
(cherry picked from commit 72b0e59c0c8599081d039f4ca86f4b5bcd53f37b)

7 years agobgpmanager BgpUtil code clean-up: Make private what can, and rm unused 97/62697/2
Michael Vorburger [Wed, 23 Aug 2017 15:03:49 +0000 (17:03 +0200)]
bgpmanager BgpUtil code clean-up: Make private what can, and rm unused

Change-Id: I484c456e44d2414ef4f03f86b4b1e79d6fcd52bc
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
(cherry picked from commit 37de31012f8f9d7b7faa5b303c8f1000275fb111)

7 years agolower BGPconnect logs to debug level 96/62696/2
Sam Hague [Tue, 22 Aug 2017 11:57:06 +0000 (07:57 -0400)]
lower BGPconnect logs to debug level

Change-Id: Ied9756d8ea082d52bc6719a0fe42a6dcf52c25ce
Signed-off-by: Sam Hague <shague@redhat.com>
(cherry picked from commit 2e71d0ca3a67819827a4de84a48837a52b2cf827)

7 years agoRemove unused NatNodeEventListener 91/62691/1
Faseela K [Sat, 19 Aug 2017 06:29:34 +0000 (11:59 +0530)]
Remove unused NatNodeEventListener

This listener does not have anything else other than debug statements.
This was seen while analyzing the delay in programming default flows
when switches are connected in scaled scenario. While trying to optimize
the number of listeners and heavy operations being done in listener
thread, this came to notice. There is no heavy operation here, but if
the listener is of no use, let us avoid one unnecessary registration.

Change-Id: I87f80b851472dba7364fe16c5d39d8ed775b2d67
Signed-off-by: Faseela K <faseela.k@ericsson.com>
(cherry picked from commit 718e81fc8017332e6fc9e5b7a5d13cdae950863e)

7 years agoBug 6349: try connecting to qthrift only when configured. 62/62662/2
Siva Kumar Perumalla [Tue, 29 Aug 2017 21:22:55 +0000 (02:52 +0530)]
Bug 6349: try connecting to qthrift only when configured.
 - default values are set to invalid host/port.
 - verify whether port/host configured before connecting

Change-Id: I4cd19ad1e9844435f75f08f45962c67d555a7e39
Signed-off-by: Siva Kumar Perumalla <sivakumar.perumalla@ericsson.com>
Signed-off-by: Sam Hague <shague@redhat.com>
7 years agoBug 9034: bgpmanager BgpUtil rm unused pendingWrTransaction 61/62661/2
Michael Vorburger [Wed, 23 Aug 2017 15:25:07 +0000 (17:25 +0200)]
Bug 9034: bgpmanager BgpUtil rm unused pendingWrTransaction

There's no set() for the pendingWrTransaction, so it's.. completely
pointless - and that retry loop in BgpConfigurationManager's
createStaleFibMap() could never have worked anyway, as
BgpUtil.getGetPendingWrTransaction() == 0, always.

Change-Id: I8644a3a9d63c5eff4106c58865cad9969d3990a2
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
7 years agoBug 9012 : BGP reconnect and retry logic to QBGP 60/62660/2
Vyshakh Krishnan CH [Fri, 18 Aug 2017 09:05:15 +0000 (14:35 +0530)]
Bug 9012 : BGP reconnect and retry logic to QBGP

During the internal testing we have observed that for many configs, thrift is not reliable enough and QBGP is not receiving the configs ODL is sending. So as a safer way, introducing retries while sending the configs to QBGP. Also reconnect mechanism in case of any thrift transport exception

Change-Id: I9862d3db093f85399e81207c787528da25445999
Signed-off-by: Vyshakh Krishnan CH <vyshakh.krishnan.c.h@ericsson.com>
7 years agoBug 8996 : BGP EOR and some minor fixes 90/61890/2
Vyshakh Krishnan CH [Wed, 16 Aug 2017 08:23:09 +0000 (13:53 +0530)]
Bug 8996 : BGP EOR and some minor fixes

Today ODL is sending the neigbour config to QBGP at the end of config replay. ie after VRFS and Netwroks. SO after a cluster reboot, neighborship establishment is taking time. A new EOR mechanishm is introducd, so that ODL can send the neighbor first. QBGP will wait for EOR from ODL to send the EOR to neighbor

Also some minor BGP fixes

Change-Id: Ib00827919aa227650ca9d7f345f40a0aed55124d
Signed-off-by: Vyshakh Krishnan CH <vyshakh.krishnan.c.h@ericsson.com>
7 years agoBug9016:Using Single Transaction during NAPT SwitchOver 59/62659/2
karthikeyan [Tue, 29 Aug 2017 08:24:45 +0000 (13:54 +0530)]
Bug9016:Using Single Transaction during NAPT SwitchOver

Problem Description:
====================
When NAPT Switch over happens, multiple transactions were made to remove
SNAT related flows from Primary NAPT switch and reinstalling flow on new
NAPT elected switch.

Optimization needs to be done to make use of single transaction taking
care of removing all SNAT related flows from old NAPT and another single
transaction for installing SNAT flows on new NAPT switch.

Solution:
==========
Used one write transaction object for used to remove all NAPT related
flows from old NAPT switch during NAPT switch over happened. Used other
write transaction object for installing all NAPT related flows on newly
elected NAPT switch. This will reduce the number of transaction object
were used during NAPT switch over happens as well as installing SNAT
related flows during first time as well.

Note:
=====
Have removed ExternalNetworkListener.java class. Since this class was
taken care for installing NAT default flow L3_FIB_TABLE(21)
PSNAT_TABLE(26) on all NAT switches. This same logic was already
implemented in ExternalRoutersListener class. Just to avoid the conflict
modification error, removed ExternalNetworkListener.java class from NAT
Module.

Change-Id: Ic2b54e7acbb01805b9a25fea28017c7353ee59d2
Signed-off-by: karthikeyan <karthikeyan.k@altencalsoftlabs.com>
7 years agoReplace size()==0 by isEmpty() 70/61470/3
David Suarez [Wed, 23 Aug 2017 07:25:20 +0000 (09:25 +0200)]
Replace size()==0 by isEmpty()

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

Change-Id: I4bba45bea95a234734079376c7439395ae38e981
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
7 years agoBug 8882 - With conntrack SNAT communication with PNF fails 58/62658/2
Aswin Suryanarayanan [Thu, 31 Aug 2017 14:25:22 +0000 (19:55 +0530)]
Bug 8882 - With conntrack SNAT communication with PNF fails

Traffic from Non NAPT to PNF was failing, Since from non NAPT switch the
packet came through a tunnel port to NAPT Switch. There it was failing
since the vpn interface does not exist for tunnel port. Hence it fails
to identify the router id.

Now for the tunnel port the external ip associated with router used to
identify the vpnid.

Change-Id: I60081c050ca117c99ba1809efde49d71d0909bdb
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>