Some files in networking-l2gw/tests/unit
were given execute permission by mistake
in Change-Id: I29020058671348e0734906a71ac3ae0798172a23.
This proposal want to remove the error permission.
Change-Id: I7e6466f8e9a0886e293df3f229d03a49b6fc92cc
Related-Id: I29020058671348e0734906a71ac3ae0798172a23
Partial-Bug: #1259292
This two files were given execution permission
by mistake. This patch removes the error permission.
Change-Id: I15a6b9fc6af23d9fa1348d567daacca9e19fd7ee
Replace assertEqual(None, *) with assertIsNone in tests to have more
clear messages in case of failure.
Trivafix.
Change-Id: If581190485435b5163bc3db264ccd6c0bf1df843
In a scenario, where network is a part of multiple
l2-gateway-connections, retain ucast_macs_remote entries
in ovsdb until the last l2-gateway-connection is deleted
for that network.
Change-Id: I6d63c5ff0c3c9d208612eeec25351977a40820c0
Closes-Bug: 1607399
By removing explicit addCleanup calls.
and also change import '_' from neutronclient.i18n import _
to networking_l2gw._i18n import _.
Change-Id: I2001c0d0b00410188942c02f7b8b43d3d2fd5b22
Closes-Bug: 1608389
The patche does the following:
1. remove nested with calls from unit tests
2. updates tox.ini to enable us to use the \ at the end
of a line
3. All integers in python 3 are long.
4. Python 3 does not support __builtin__. Removed it from the tests.
Now the unit tests pass when running python 3.
This also adds support to tox.
Change-Id: Iacbf0c2c05248819af817109e7dd637f71c82404
Bring the sqlalchemy models in sync with the alembic migrations.
Add the neutron standard model-migration sync test. The test is added
to the unit test env since l2gw does not have a functional job
yet. This requires that l2gw uses the python-db-jobs template in the
gate.
(Also remove downgrades since they are not supported.)
Closes-Bug: #1605675
Depends-On: I3a8ea02b86846e9a8a7d7f2aee9700ca952b0248
Change-Id: Ib73f554d5f0bbfbe25a0f6ad33b23e4584800e21
In DVR mode no host IP is associated with the L3 Agent because
the router is configured on all the Compute Nodes and on the Network Node.
To overcome this problem we look for L3 Agent that is running on the Network Node,
resolve the hostname of the Network Node to get its IP address and use it to
configure the destination IP needed for neutron port location information.
Closes-Bug: 1463784
Change-Id: I2595c714ede896baa7726ceec793de9a7a29e6b2
Some tests used incorrect order assertEqual(observed, expected).
The correct order expected by testtools is
assertEqual(expected, observed).
Co-Authored-By: yan.songming@zte.com.cn
Change-Id: I29020058671348e0734906a71ac3ae0798172a23
Partial-Bug: #1259292
Change-Id: I06912522a1e8ccf7a93357d6ee2ab54e02daaf68
Fix unit test problem
unit test failed due to missing mock.
Change-Id: I656ed3518a763750c37ad995f5016d53b63388ac
whenever l2gateway_agnet.ini is reconfigured to the same ovsdb identifier
but different IP, then we need to clean the mysql db entries from earlier
configured ovsdb_identifier and IP.
For Ex: l2gateway_agent is connected to "ovsdb1:10.10.10.10:6632",
but when you change l2gateway_agent.ini to "ovsdb1:20.20.20.20:6632",
then the mysql entries related to "ovsdb1:10.10.10.10:6632" should be cleaned.
Change-Id: I72cd5a5e2ea27c2a6b37865c3517e614f901aecf
Closes-Bug:1588809
ovsdb server will initiate SSL connection to l2gateway agent, whenever
ovsdb manager table is populated with l2gateway agent IP with SSL.
This patch set will handle the ssl connection in the l2gw agent side.
Change-Id: I63f1f0465fdcbdc9ed6be0d98fb8e5b59e882eb0
Closes-Bug: 1585901
whenever l2gw agent IP:PORT is configured in manager table
of ovsdb server, it has to be configured in l2gateway_agent.ini
so that l2gw agent can listen for the connection request from ovsdb
server for the configured port.
Change-Id: Iac81c41cbac7daf43e72c12f094d6fefe33ce749
Closes-Bug: 1580869
When the update or show l2 gateway api requests specify invalid id,
neutron returns internal server error because _get_l2_gateway method didn't
raises L2GatewayNotFound error.
This commit fixes it so that these api can return 404 code error in the
above case.
Change-Id: I561955a972c7419f96db72be85f9538f9e13c3b2
Closes-Bug: 1535625
for insert/delete vlan_bindings column in physical_port table.
updating the vlan_bindings, which requires the previous data
from neutron db for a port, which is a overhead operation,and also causing
inconsistent entries in ovsdb server.
use mutate operation so that only the vlan_bindings which is generated
in request is inserted/deleted by mutating the vlan_binding column.
so that vlan_bindings in ovsdb is consistent.
Closes-Bug: 1542185
Change-Id: I8e0d3c19f74ae2906236fd71befacc0ff501023a
networking-vsphere, which works for ESXi nodes
does not support l2 population. so choosing
ovs-vapp agent instead of ovs agent to create tunnel
by tunnel sync call, while creating l2-gateway-connection.
Closes-Bug: 1544112
Change-Id: I801e539ccc4f9bdce3b829189c97c53ba84a8f48
If an invalid L2 gateway UUID is passed to _get_l2_gateway method,
it returns None instead of raising L2GatewayNotFound exception.
This leads to an Internal Server Error.
This patch replaces the 'try...except' block with an 'if' statement
because get method of SQLAlchemy Query object returns a None
instead of raising NotFound exception.
Closes-Bug: #1570146
Change-Id: Ib95fdaa4af613800159d89960b8b98c839508eaf
Enhance the L2GW Service Driver framework to embrace
out-of-L2GW-source-tree service drivers.
Co-Authored-By: Vivekanandan Narasimhan <n.vivekanandan@ericsson.com>
Closes-Bug:1532436
Change-Id: Ib56ee8bfd182c031e468c503acb0cd75daea8c40
check for interface type while creating l2-gateway.
it should be list of dict.if not raise an appropriate message.
for ex: request body for l2-gateway-create is as below.
{"l2_gateway": {"name": "gw2", "devices": [{"interfaces": [{"name": "i1"}]}, "device_name": "switch2"}]}'
Change-Id: I65430efa1a3ed4416e649f0377d9dff7fafc5b57
Closes-Bug: 1548361
The patch set fixes a problem where the L2gw agent requires a restart
when a user adds the Management IP of the L2gw agent in the Manager
table of a new OVSDB server.
Closes-Bug:1546891
Change-Id: I39c87f3021fd0091e7f49f8f3d22c67ebffb0306
while retreving the information from port details which belongs to specific host,
we are checking whether ovs agent is running on that host or not. if not,
exception is raised saying ovs agent not found in the host.
Closes-Bug:1515877
Change-Id: I23fccd8751ce791e1c6fd6920a0510c943714126
Commit 87a79256c494c36f2d9597313f430b24c0110161 added shared exceptions
to neutron-lib. This patch makes use of the aforementioned library.
Change-Id: I14b27381c4f4847ce5e95ff43a1efe97a2685505
Since l2gateway binds vxlan(virtual side) to vlan(physical side) segment.
We are extracting only vxlan segment from the virtual network.
Since multi segment network can have multiple segmentation id's belonging
to different network types(vlan, gre, vxlan, etc), we are extracting the
vxlan segment from it.
We are checking for multiple vxlan segments in the network since ovsdb
does not allow multiple vxlan segmentation id's to associate for same
vlan (physical side) while creating l2_gateway_connection.
For Ex: say multi segment network has two vxlan segment id's 1000 and 2000.
If we create a l2_gateway_connection for this network by providing physical
side vlan segment as 500, the bindings should be 1000:500 and 2000:500,
this is not allowed in ovsdb hardware vtep schema.
Closes-Bug:1511639
Change-Id: I5f704eaf40763686aa30320dff7a99a16b6c1772
The patch set provides a framework to support
service drivers so that the south bound implementation
need not be tied to only the L2gw agent communicating
over the RabbitMQ message bus. This will help to support
other types of south bound implementations like OpenDaylight.
Change-Id: I403c7c0f110d4ad95d803640508b78c1539d181f
Closes-Bug: 1478812
Author: Maruti <maruti.kamat@hp.com>
Co-Authored-By: Manjunath Patil <mpatil@hp.com>
call add_port_mac in l2gw_callback for port update event
as a normal call rather than in thread.
Change-Id: I95ebef23dc5d2bfc3d406c0ac0acd7318485973d
Closes-bug:1511651
ovsdb server initiates the connection to l2gw agent with the entries in
manager table in ovsdb hardware vtep schema and with flag 'enable_manager'
set to True in l2gateway_agent.ini.
multiple ovsdb can connect to same l2gatway agent with the l2gw agent ip in
respective manager table.
This patchset addresses the handling of connections from multiple
ovsdb servers.
Change-Id: Iffe6a9e8599ffaed55c3f8b749c4d6f7d0e52c79
Closes-Bug:1495005