Aaron Rosen [Wed, 5 Jun 2013 00:19:07 +0000 (17:19 -0700)]
Change lazy='dynamic' to 'joined' in models_v2
Previously several models were defined with lazy='dynamic'. This would
then cause Ports.fixed_ips (or w/e was specified as dynamic) to be defined
as a AppenderQuery object and when accessed would query for the result.
Therefore in get_ports() for example, when fixed_ips was accessed
in _make_port_dict() we would be issuing an addition query to the database
to lookup the fixed_ips information.
This patch changes update_port/subnet() so that it keeps track of what
changed so it does not have to query the db for values it should already
know about.
This patch also adds a unit test for update_subnet() adding host routes
where there was missing code coverage.
Akihiro MOTOKI [Mon, 20 May 2013 20:07:05 +0000 (05:07 +0900)]
Improve test coverage in NEC plugin
blueprint nec-plugin-test-coverage
This commit adds the following changes in unit tests.
- Unit tests to check communications with the controller in NEC plugin
- Unit tests for nec plugin agent
- Improve coverage of OFC drivers
- Mock the client to talk with the external controller in db.
This patch ensure subnet is loaded only once from the database.
Also, the port is now loaded from the database only if the
corresponding NVP logical port is found.
Kevin Benton [Tue, 4 Jun 2013 23:18:58 +0000 (16:18 -0700)]
Adds support for the Indigo Virtual Switch (IVS)
Implements: blueprint ivs-interface-driver
Adds the IVS VIF type to portbindings.py.
Adds the VIF interface class to allow agents to bind to VIF switches.
Adds support to the BigSwitch plugin to request the IVS VIF type on nova compute nodes.
Adds unit tests for new interface class and changes to BigSwitch plugin.
Aaron Rosen [Thu, 6 Jun 2013 22:06:24 +0000 (15:06 -0700)]
Add support for protocol numbers
This patch adds support for passing in protocol numbers into the API.
For example, 1 instead of ICMP. This allows all protocols besides
just TCP/UDP/ICMP to be used. This patch includes changes to support
this for the NVP Plugin. Existing plugins using securitygroups_rpc_base
and OVSHybridIptablesFirewallDriver require no change to leverage this.
This commit adds an API extension for NVP where the
NVP supported mac learning feature can be switched
on/off for a specific port. The attribute can be
True or False or omitted altogether.
Lorin Hochstein [Tue, 4 Jun 2013 13:42:00 +0000 (09:42 -0400)]
Add extra details in BigSwitch config
Add some details to some of the BigSwitch configuration options.
The doc team will soon be generating documentation for configuration
options by extracting it directly from the source code help strings,
which is one of the motivations for adding this detail.
This fix adds a rollback of the OVS plugin update_port operation
following a failure to update the port in the Cisco Nexus sub-plugin.
Also, this fix removes an unneccessary call to the Nexus sub-plugin's
update_network method within the Cisco plugin model layer's
update_network method (as well as the associated argument setup).
The Nexus sub-plugin's update_network is a no-op, so there's no
need to call it.
Lorin Hochstein [Sun, 26 May 2013 20:42:21 +0000 (16:42 -0400)]
Sphinx-ify QuantumPluginBaseV2 docstrings
The quantum.quantum_plugin_base_v2 module had some good docstrings,
but there was no corresponding sphinx code that would generate
docs from them. There were also some syntax issues with the
sphinx markup in the docstrings.
This change adds sphinx directives so these docs will be auto-
generated. It also modifies the docstrings in the QuantumPluginBaseV2
methods so they are parsed by the Sphinx documentation generator
without any errors.
If this patch is accepted, a "Plugin API" link to these docs
will appear at
Aaron Rosen [Fri, 31 May 2013 02:33:55 +0000 (19:33 -0700)]
Add L3 resources to policy.json
This patch adds the l3 resources to policy.json. I tested changing the
rule to rule:admin_only for all the resources added and they were
enforced as expected.
Zhenguo Niu [Thu, 30 May 2013 05:36:22 +0000 (13:36 +0800)]
Rename requires files to standard names.
Rename tools/pip-requires to requirements.txt and tools/test-requires
to test-requirements.txt. These are standard files, and tools in the
general world are growing intelligence about them.
This fix changes the command being sent to the Nexus switch for
enabling a VLAN on an interface such that the 'add' keyword is
included only when there are prior VLANs already enabled on that
interface.
Bob Kukura [Fri, 5 Oct 2012 15:50:39 +0000 (11:50 -0400)]
Initial Modular L2 plugin implementation.
The Modular L2 Plugin uses drivers to support separately extensible
sets of network types and of mechanisms for accessing networks of
those types. This is an initial implementation that has been tested
with the openvswitch and linuxbridge agents, and should also work with
the hyperv agent. See quantum/plugins/ml2/README for details.
Salvatore [Wed, 15 May 2013 13:05:30 +0000 (15:05 +0200)]
Control resource extension process defining required extensions
Blueprint l3-ext-gw-modes
The resource extension process is slightly altered so that an
API extension can specify which extensions should be processed before
its attributes can be processed. This is needed to ensure the
l3-ext-gw-mode API extension sets up correctly validators and other
attributes for the external_gateway_info attribute
This patch introduces an API extension for enabling or disabling
source/destination NAT on the router gateway interface, and implements
support for this extension in the l3 agent, which has also been
refactored in order to ensure SNAT rules are applied (or removed)
in a single place in the process_router routine.
The patch therefore enables the extension on all plugins which
leverage this agent.
In this patch the validate_boolean function is re-introduced, as it
used for validating a field of the external_gateway_info dict.
The resource extension process is also slightly changed so that an
API extension can specify which extension should be processed before
its attributes can be processed. This is needed to ensure the
proper validator for external_gateway_info is installed.
Ryu Ishimoto [Mon, 25 Feb 2013 16:34:46 +0000 (01:34 +0900)]
Make MidoNet plugin code more testable
Refactor plugin.py and midonet_lib.py to improve unit testing of
the MidoNet plugin. Make all the tests pass in the plugin except
those that test features that are not currently supported by the
plugin, which are IPv6 and multiple subnets per network.
Consolidate the mocking code in mock_lib.py to be shared by
plugin.py and midonet_lib.py.