Dan Prince [Mon, 25 Mar 2013 17:47:50 +0000 (13:47 -0400)]
Enable exception format checking when testing.
Updates our new exception base class to enable exception
format checking. This should help enforce that we pass
the correct kwargs to exceptions when testing.
Isaku Yamahata [Mon, 18 Mar 2013 21:56:15 +0000 (06:56 +0900)]
netns: ip netns exec <name> kill doesn't make sense
It seems confusing netns with pidns.
Although 'ip netns exec' doesn't make sense,
'ip netns exec <netns> kill <pid>' itself success as expected.
But as side effects, dentry of /proc/<pid>/ns/net becomes young,
which increases the possibility to fail to delete netns. That's not good.
Aaron Rosen [Thu, 21 Mar 2013 01:19:04 +0000 (18:19 -0700)]
Fix race condition in dhcp agent
This patch fixes a race condition that can happen in the dhcp agent when
a subnet is created and then a host route is then immediately added to that
subnet following a subnet.update.end notification. The race condition occurs
in refresh_dhcp_helper() where self.enable_dhcp_helper() gets called twice
since the first call had not completed self.cache.put(network). This same race
condition can also occur in the other events so lockutils.synchronized() is
added to synchronize those code segments as well.
adding parameter to configure QueuePool in SQLAlchemy
This patch introduces the parameter sqlalchemy_pool_size.
The parameter is used to configure the QueuePool, created
in configure_db(). At the moment the configuration of the
pool is only possible when using eventlet's db_pool for
MySQL (sql_dbpool_enable = True).
This patch removes extra colons from policy.json.
Also, it fixes some checks in the nicira plugin which were not
passing correctly the target resource for the policy engine.
Paul Michali [Mon, 18 Feb 2013 13:57:14 +0000 (08:57 -0500)]
Add bulking support for Cisco plugin
For each bulk request, the Cisco plugin will handle the call,
and, through the base class method, convert them into a series of
non-bulking calls wrapped in a transaction (emulated bulking).
Those non-bulking requests will all be forwarded to the Cisco
model (VirtualPhysicalSwitchModelV2), which will either handle
the request locally (as in create_port), or delegate the request
to the OVS plugin (OVSQuantumPluginV2).
As a result, the model should not receive any bulking calls.
However, the model was set up to delegate any bulk calls to the
OVS plugin (which would act like the existing code, in case we
decide later to pass along any bulk calls). An alternative would
be to raise an exception, if a bulk call was made to the model.
Prior to this change, all bulking calls were forwarded from the
Cisco plugin to the model plugin, which would would delegate
(directly or indirectly) to the OVS plugin. The OVS plugin would
turn the request into a transction of non-bulking calls.
The effective difference proposed is that the create_port will now
create the port in OVS and then create the network in the Nexus
plugin.
The Nexus plugin does not currently handle bulking so this commit
is implementing emulated (versus native) bulking.
This patch has been updated with latest from upstream (Havana).
Alessio Ababilov [Mon, 18 Mar 2013 16:48:30 +0000 (18:48 +0200)]
Allow tests in TestDhcpAgentEventHandler run independently
Tests in TestDhcpAgentEventHandler depend on dhcp_confs
option that is defined in quantum.agent.linux.dhcp. We have
to register the option in order to allow independent testing.
Zhongyue Luo [Thu, 7 Mar 2013 08:11:31 +0000 (16:11 +0800)]
Resolves ryu plugin unittest errors
Removed obsolete DATABASE value tests in ryu/test_defaults.py
Added fake_ryu client in test_ryu_security_group.py
Imported quantum.plugins.ryu.db.models_v2 in test_ryu_plugin.py
Dan Wendlandt [Wed, 13 Mar 2013 05:36:35 +0000 (22:36 -0700)]
First havana commit.
This commit indicates that the master branch has moved on to
representing the "havana" release. The previous commit will be use to
start the milestone-proposed branch for grizzly.
All future changes for grizzly must first be merged
into master, and then back-ported to a grizzly milestone-proposed branch
(or once grizzly is released, the stable/grizzly branch).
If the entry for the mapping between a quantum and a NVP port identifier
is not found in the Quantum DB, search the port on NVP, and, if found,
add the mapping entry.
This ensures upgraded folsom databases keep working with Grizzly code.
Aaron Rosen [Sun, 10 Mar 2013 21:09:28 +0000 (14:09 -0700)]
port_security migration does not migrate data
The port security migration previously created the correct table structure but
it did not migrate the old data into this table. This patch adds code that
copies the id fields from networks and ports into portsecuritybindings
and networksecuritybindings tables.
One thing to note is that in grizzly when a port is created on a network that
has port_security_enabled=True, the port will also be created with
port_security_enabled=True. But since ports in NVP were not previously
created with the mac/ip security address pairs we have to set existing ports
and networks port_security_enabled value to be False. One could easily
write a script to set these values to True after applying this migration.
Roman Podolyaka [Tue, 5 Mar 2013 16:53:51 +0000 (18:53 +0200)]
Fix detection of deleted networks in DHCP agent.
The DHCP-agent uses an in-memory networks cache to find out which networks must
be deleted and which ones must be updated. In a case of agent restart the networks
cache is empty and it's not possible to cleanup DHCP-processes serving networks
which were deleted while the DHCP-agent was down. The proposed fix fills the networks
cache when the agent starts using a list of networks which have existing config files.
Several plugins added l3 support in the grizzly release. This means that
when upgrading from the folsom data model, the relevant data model changes
should be applied.
In order to do so this patch refactors the initial migration in order
to be able to reuse the upgrade_l3 and downgrade_l3 routines.