]> review.fuel-infra Code Review - openstack-build/neutron-build.git/log
openstack-build/neutron-build.git
12 years agoUpdate latest openstack files
Gary Kotton [Mon, 13 Aug 2012 12:33:37 +0000 (08:33 -0400)]
Update latest openstack files

Ensure that the common code is updated with the latest common
code.

Change-Id: I8a8a21fdcf77a2f444fd3c919cca9aa3912e21af

12 years agoAdds the 'public network' concept to Quantum
Salvatore Orlando [Thu, 26 Jul 2012 08:10:02 +0000 (01:10 -0700)]
Adds the 'public network' concept to Quantum

Implements blueprint quantum-v2-public-networks

This patch allows Quantum to handle public networks. It modifies the
API adding a new attribute to the network resource ('shared')
and enhances the policy engine in order to handle the behaviour of
the service wrt shared networks.
Policy.json specifies a default behaviour which can be changed by
the administrator, even at runtime.
Tests added to test_db_plugin validate 'obvious' behaviour - such as
that only the ports belonging to a given tenant should be returned
even when they are queried on a public network.
Tests added to test_policy instead validate the changes added to the
policy engine.

Change-Id: I0087d449a677ed29357cd3cb4d8580bece940fdf

12 years agoMerge "Make dhcp agent configurable for namespace"
Jenkins [Mon, 13 Aug 2012 05:29:31 +0000 (05:29 +0000)]
Merge "Make dhcp agent configurable for namespace"

12 years agoMerge "Linux Agent improvements for L3"
Jenkins [Mon, 13 Aug 2012 05:28:53 +0000 (05:28 +0000)]
Merge "Linux Agent improvements for L3"

12 years agoMerge "normalize the json output of show a given extension."
Jenkins [Mon, 13 Aug 2012 04:54:15 +0000 (04:54 +0000)]
Merge "normalize the json output of show a given extension."

12 years agoMake dhcp agent configurable for namespace
Aaron Rosen [Sun, 12 Aug 2012 00:17:30 +0000 (17:17 -0700)]
Make dhcp agent configurable for namespace

Bug #1035769

Change-Id: I9f0d48a73f059a4985d629c7f0209675f5b01bec

12 years agoLinux Agent improvements for L3
Dan Wendlandt [Sun, 12 Aug 2012 02:42:59 +0000 (19:42 -0700)]
Linux Agent improvements for L3

prereq for bp quantum-l3-fw-nat

- make init_l3 take cidrs, rather than assuming an augmented port object
- make namespace for agent operations optional and allow the namespace
name to be configured.
- allow plug() operation to take an optional bridge parameter indicating
which bridge to plug into
- add namespace support for iptables manager
- make OVS plug() set the IP address, etc. of a device even if it already
exists.

Change-Id: Id4fec9bf7cda30c45b94eccd25e9e54dc5af97b7

12 years agoIn some cases device check causes an exception
Gary Kotton [Sat, 11 Aug 2012 16:58:18 +0000 (12:58 -0400)]
In some cases device check causes an exception

Fixes bug 1035669

Check the stderr in addition to checking the return codes.

Change-Id: I05e469302bc502b540b0c4af5fbd9c712a9bd309

12 years agonormalize the json output of show a given extension.
Yong Sheng Gong [Sat, 11 Aug 2012 23:50:22 +0000 (07:50 +0800)]
normalize the json output of show a given extension.

we should use {'extension':{}} for a given extension query to comply with
our API design.

Change-Id: Id0b04b29bed4be92498c04178e268c31e9a1d635

12 years agomove the correct veth into the netns for the LB
Mark McClain [Sat, 11 Aug 2012 15:29:14 +0000 (11:29 -0400)]
move the correct veth into the netns for the LB

bug 1035649

This fix moves the correct device into the namespace and improves the test
to ensure the proper device was moved.  The previous generic check
failed to catch an error during refactoring.

Change-Id: Ifa2e2bb97dc923549d00b1750c61a22e139647d7

12 years agolinux bridge fixes following v1 code removal.
Dan Wendlandt [Sat, 11 Aug 2012 02:37:34 +0000 (19:37 -0700)]
linux bridge fixes following v1 code removal.

Change-Id: I4ad84421757db271904c8704a12b2e7abdfa8a0e

12 years agoMerge "Remove v1 code from quantum-server"
Jenkins [Sat, 11 Aug 2012 02:56:02 +0000 (02:56 +0000)]
Merge "Remove v1 code from quantum-server"

12 years agofixes typo in ensure_namespace
Mark McClain [Fri, 10 Aug 2012 18:24:17 +0000 (14:24 -0400)]
fixes typo in ensure_namespace

bug 1035425

There was an uncheck branch in ensure_namespace that used the wrong
class name.  This fixes that bug and adds better tests.

Change-Id: I0c22e70938305e180084de4bf9a700aebf512645

12 years agoRemove v1 code from quantum-server
Dan Wendlandt [Fri, 10 Aug 2012 17:37:26 +0000 (10:37 -0700)]
Remove v1 code from quantum-server

bp remove-v1-related-code

Removes API, DB, and test code that is used only for Quantum v1 API,
which is no longer supported.

Includes removal of v1 code for sample, ovs, linuxbridge and ryu plugin.

Nicira and Cisco plugins will be handled outside of this patchset.

Change-Id: Id34dc7229bb7b399b5cfd4602dbc8d5ee4e8de61

12 years agoMerge "Add netns to support overlapping address ranges"
Jenkins [Fri, 10 Aug 2012 16:39:05 +0000 (16:39 +0000)]
Merge "Add netns to support overlapping address ranges"

12 years agoMerge "RPC support for Linux Bridge Plugin and Agent"
Jenkins [Fri, 10 Aug 2012 16:25:23 +0000 (16:25 +0000)]
Merge "RPC support for Linux Bridge Plugin and Agent"

12 years agoAdd netns to support overlapping address ranges
Mark McClain [Fri, 20 Jul 2012 01:37:24 +0000 (21:37 -0400)]
Add netns to support overlapping address ranges

blueprint: dhcp-overlapping-ips

This change uses linux network namespaces to isolate dhcp interfaces so
that tenant network IP address ranges can properly overlap.

Change-Id: Iaa07e7c38d0813d07c3405884e513276e43e2afd

12 years agoMerge "dhcp-agent: Ryu plugin support for dhcp agent"
Jenkins [Fri, 10 Aug 2012 15:53:10 +0000 (15:53 +0000)]
Merge "dhcp-agent: Ryu plugin support for dhcp agent"

12 years agodhcp-agent: Ryu plugin support for dhcp agent
Isaku Yamahata [Fri, 27 Jul 2012 15:27:30 +0000 (00:27 +0900)]
dhcp-agent: Ryu plugin support for dhcp agent

This patch adds Ryu support to dhcp-agent.
fixes bug 1030830
Ryu devstack support is available at https://review.openstack.org/#/c/10117/

Change-Id: I3f5fbe8600b4b674834e317e158bac1856b0349c
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
12 years agofix missing deallocation of gateway ip
Dan Wendlandt [Wed, 8 Aug 2012 22:30:48 +0000 (15:30 -0700)]
fix missing deallocation of gateway ip

bug 1032506

when deleting a port that uses the gateway IP, we were not removing
the IPAllocation entry, which resulted in a depedency issue when we
deleted the port that the IPAllocation entry referenced.

Change-Id: I272a6572c389ef8c12585f4b62204f5877cda078

12 years agoRPC support for Linux Bridge Plugin and Agent
Gary Kotton [Tue, 10 Jul 2012 15:28:08 +0000 (11:28 -0400)]
RPC support for Linux Bridge Plugin and Agent

blueprint scalable-agent-comms

This is the first stage of the blueprint. This adds support to the linux bridge
plugin.

The development followed the design described in:
https://docs.google.com/document/d/1MbcBA2Os4b98ybdgAw2qe_68R1NG6KMh8zdZKgOlpvg/edit?pli=1

Change-Id: I4004c05a63ce49f020c2016c8763e73238b465a7

12 years agoImplementation of bp per-net-dhcp-enable
xchenum [Thu, 26 Jul 2012 00:58:52 +0000 (20:58 -0400)]
Implementation of bp per-net-dhcp-enable

Change-Id: I81c2e6adb02921e8b80f8181a730b1cba9ffa649

12 years agoEnhance Base MAC validation
Gary Kotton [Mon, 6 Aug 2012 13:45:20 +0000 (09:45 -0400)]
Enhance Base MAC validation

Fixes bug 1033520

The base mac will now be validated when the configuration file is read.
In addition to this the following has been done:
1. checks validaity of the base mac - for example it cannot be a multicast MAC
2. adds a framework for attributes tests

Change-Id: Ibffab039ca7ee9e87eb79a7288e86401170bf129

12 years agoUse function registration for policy checks
Kevin L. Mitchell [Thu, 2 Aug 2012 19:09:23 +0000 (14:09 -0500)]
Use function registration for policy checks

The original policy framework allowed new policy checks to be created
through inheritance.  This is somewhat clunky and unnecessary in
Python.  This change refactors policy.py to allow new policy checks
to be registered using an @register() decorator.  One consequence is
that HttpBrain is deprecated.

Care has been taken to ensure backwards compatibility; deprecation
warnings will be emitted for uses of HttpBrain or the inheritance-
based checks.

(Pull-up from openstack-common, with deprecation of HttpBrain.)

Change-Id: I0aa78d1128e55aa7d59558c62128105c01da8f1b

12 years agoExempt openstack-common from pep8 check
Kevin L. Mitchell [Mon, 6 Aug 2012 15:00:17 +0000 (10:00 -0500)]
Exempt openstack-common from pep8 check

The openstack-common project already does its own pep8 checks; we
don't need to duplicate the effort.  This also avoids issues with
pep8 version skew between projects.

Change-Id: I50d6e1b21c743d811e44b415017ca7e19687c9c2

12 years agoMerge "Make 4th octet of mac_range configurable."
Jenkins [Mon, 6 Aug 2012 05:15:22 +0000 (05:15 +0000)]
Merge "Make 4th octet of mac_range configurable."

12 years agoMerge "Replace openvswitch plugin's VlanMap with vlan_ids DB table."
Jenkins [Mon, 6 Aug 2012 01:02:43 +0000 (01:02 +0000)]
Merge "Replace openvswitch plugin's VlanMap with vlan_ids DB table."

12 years agoMake 4th octet of mac_range configurable.
Nachi Ueno [Fri, 3 Aug 2012 01:37:34 +0000 (01:37 +0000)]
Make 4th octet of mac_range configurable.

Fix bug 1022739.
To get OUI per cluster is not realistic. So This commit
make 4th octet of mac_range configurable. By this commit,
the cloud provider can allocate OUI (3 octets)  + 1 extra octet
range (4 octets) for each cluster.

Change-Id: Ibbd27e6e7f16d73dfd3045ed60f63a38b23ea1ed

12 years agoMerge "update DHCP agent to work with linuxbridge plug-in"
Jenkins [Sat, 4 Aug 2012 19:50:19 +0000 (19:50 +0000)]
Merge "update DHCP agent to work with linuxbridge plug-in"

12 years agoReplace openvswitch plugin's VlanMap with vlan_ids DB table.
Bob Kukura [Mon, 30 Jul 2012 18:52:06 +0000 (14:52 -0400)]
Replace openvswitch plugin's VlanMap with vlan_ids DB table.

Fixes bug 1023167.

The openswitch plugin's in-memory VlanMap is replaced with a vlan_ids
DB table similar to that used by the linuxbridge plugin. This will
prevent conflicting VLAN assignments if multiple server replicas are
run, and also sets the stage for phase 2 of the provider-networks BP
implementation that will add support for multiple physical
networks.

Unlike with the current linuxbridge plugin, the contents of the
openvswitch plugin's vlan_ids table are properly updated at startup in
case the vlan_min or vlan_max configuration variables have changed.

A new test_ovs_db test case has been added.

The primary key of the vlan_bindings table is changed from the vlan_id
to the network_id, which is now a foreign key, and network deletion is
now properly handled.

The net_id has been removed from the VlanIdInUse exception, requiring
a minor update to the linuxbridge plugin. The new NoNetworksAvailable
exception, with ResourceExhausted as its base class, is returned when
no more VLANs are available.

Change-Id: I65a2347dea5366cc0d15d98a88f40e42e1a45f4c

12 years agoMerge "Remove unused properties"
Jenkins [Fri, 3 Aug 2012 15:24:08 +0000 (15:24 +0000)]
Merge "Remove unused properties"

12 years agoRemove unused properties
Nachi Ueno [Fri, 3 Aug 2012 06:29:04 +0000 (06:29 +0000)]
Remove unused properties

Fixes bug 1032502.

Change-Id: I63d86788e004ac371e69c238caf38c64ee398955

12 years agoNotification for network/subnet/port create/delete/update.
Yong Sheng Gong [Wed, 25 Jul 2012 14:55:33 +0000 (22:55 +0800)]
Notification for network/subnet/port create/delete/update.
blueprint quantum-notifications

Add host configuration into conf, which is determined by socket.gethostname()
function by default. Host name is part of publiser id, which is in the format
of 'network'.$host.

We add create/update/delete start and end notification for each kind of resource.
By default, the notification do nothing since the notifier driver is no_op_notifier.
We can define it in quantum.conf.

Change-Id: Ibc5eacac7a324584e6ccff120f573444932a88ef

12 years agoMerge "ryu/plugin, agent: unbreak 610017c460b85e1b7d11327d050972bb03fcc0c3"
Jenkins [Wed, 1 Aug 2012 17:19:46 +0000 (17:19 +0000)]
Merge "ryu/plugin, agent: unbreak 610017c460b85e1b7d11327d050972bb03fcc0c3"

12 years agoMake the plugin for test_db_plugin configurable
Salvatore Orlando [Wed, 1 Aug 2012 11:05:17 +0000 (04:05 -0700)]
Make the plugin for test_db_plugin configurable

Bug 1031716

Change-Id: I8dc492eb90d4160a23b3b4ba51feeedba6f852e2

12 years agoMerge "Add classmethod decorator to class methods of providervlan ext."
Jenkins [Mon, 30 Jul 2012 19:38:07 +0000 (19:38 +0000)]
Merge "Add classmethod decorator to class methods of providervlan ext."

12 years agoupdate DHCP agent to work with linuxbridge plug-in
Mark McClain [Thu, 26 Jul 2012 18:42:55 +0000 (14:42 -0400)]
update DHCP agent to work with linuxbridge plug-in

Fixes bug: 1027194

Update the interface driver to use veths instead of tap devices.  This
change is compatible with the netns work.

Change-Id: Ic236f5fdeb79eb36791434999df2b731856de092

12 years agoryu/plugin, agent: unbreak 610017c460b85e1b7d11327d050972bb03fcc0c3
Isaku Yamahata [Mon, 30 Jul 2012 02:51:27 +0000 (11:51 +0900)]
ryu/plugin, agent: unbreak 610017c460b85e1b7d11327d050972bb03fcc0c3

The changeset of 610017c460b85e1b7d11327d050972bb03fcc0c3,
Change-Id of I3bd7701526a950c360d7c2cf14b31045010b46ca
breaks Ryu plugin/agent. This patch unbreaks it.
fixes bug 1030832

"from quantum.common import config as logging_config" was missing for
ryu agent.
"from quantum.openstack.common import cfg" was missing for ryu plugin.
And unused imports is eliminated.

Change-Id: I2cb3b030dff3ea3fe3db0e5672781f031198eee6
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
12 years agoMerge "Make quantum pipeline configurable from quantum.conf."
Jenkins [Sun, 29 Jul 2012 20:53:25 +0000 (20:53 +0000)]
Merge "Make quantum pipeline configurable from quantum.conf."

12 years agoAdd classmethod decorator to class methods of providervlan ext.
Yong Sheng Gong [Sun, 29 Jul 2012 13:16:59 +0000 (21:16 +0800)]
Add classmethod decorator to class methods of providervlan ext.

Change-Id: If26d75b67c4816de0937f9edaa9f55a5bb2197a2

12 years agoOnly delete VLAN information after Quantum network is deleted
Gary Kotton [Sat, 28 Jul 2012 18:08:47 +0000 (14:08 -0400)]
Only delete VLAN information after Quantum network is deleted

Fixes bug 1030271

In the case where a network is deleted and there is a VLAN tag in a
separate table then the tag should only be deleted if the network
is deleted.

Change-Id: I99130f863928abf30a521e9a2b6d1233a274d9c6

12 years agoMake quantum pipeline configurable from quantum.conf.
Akihiro MOTOKI [Thu, 26 Jul 2012 08:48:48 +0000 (17:48 +0900)]
Make quantum pipeline configurable from quantum.conf.

Fixes bug 1029313.

The current api-paste.ini does not provide a way to choose a pipeline:
there is no way to switching a pipeline between keystone-enabled and
noauth pipelines without modifying the pipeline directly.

This commit introduces 'auth_strategy' flag to quantum.conf and
a pipeline used is determined depending on the flag. Supported values for
this flag are 'keystone' (default) and 'noauth' at the moment.

Change-Id: Ieafaf31eaaec2b02727ed5d3bd36c907e50aee5b

12 years agoovs_quantum_plugin should use reconnect_interval in common conf.
Nachi Ueno [Thu, 26 Jul 2012 22:54:18 +0000 (22:54 +0000)]
ovs_quantum_plugin should use reconnect_interval in common conf.

Fixes Bug : 1029680

Change-Id: I5dd2467bc5e287bbb5ff4a2527b9f701375fa376

12 years agoMerge "Fix linuxbridge agent tests"
Jenkins [Thu, 26 Jul 2012 16:26:37 +0000 (16:26 +0000)]
Merge "Fix linuxbridge agent tests"

12 years agoMerge "Enable agents and plugins to use the same configuration file."
Jenkins [Thu, 26 Jul 2012 16:25:20 +0000 (16:25 +0000)]
Merge "Enable agents and plugins to use the same configuration file."

12 years agoadd name into port and subnet.
Yong Sheng Gong [Wed, 25 Jul 2012 23:32:59 +0000 (07:32 +0800)]
add name into port and subnet.

f-3-cli-usability-improvments

The name is optional to create network/port/subnet and is up to user to
decide its uniqueness.

Change-Id: I40c834ed66e2da14a414232c86c9fd4f5c1d9154

12 years agoUpdate openvswitch tunnel unittest
aaronorosen [Wed, 25 Jul 2012 17:35:28 +0000 (13:35 -0400)]
Update openvswitch tunnel unittest

Bug #1029024

Change-Id: Ie37ef0c3355e86f504fa71417921bb828b40e347

12 years agoEnable agents and plugins to use the same configuration file.
Gary Kotton [Tue, 24 Jul 2012 17:15:54 +0000 (13:15 -0400)]
Enable agents and plugins to use the same configuration file.

The change also implements blueprint agent-logging (this
was due to the fact that the existing logging in the agents
did not work with the change)

Devstack support for the above is in
https://review.openstack.org/10267

Notes:
- The service and agent can be run with multiple configuration
  files by using the CLI parameters --config-file <filename>
- The agent now makes use of the logging and debugging flags
  defined in quantum.conf. This follows the standard common
  configuration command line rules.

Change-Id: I3bd7701526a950c360d7c2cf14b31045010b46ca

12 years agoFix linuxbridge agent tests
Gary Kotton [Wed, 25 Jul 2012 13:35:16 +0000 (09:35 -0400)]
Fix linuxbridge agent tests

Agent tests failing missing parameter in setUp

Change-Id: I7c7e029fbf88e0fd62aba821e81a55d3aca02190

12 years agoMerge "Initial V2 implementation of provider extension."
Jenkins [Tue, 24 Jul 2012 21:45:53 +0000 (21:45 +0000)]
Merge "Initial V2 implementation of provider extension."

12 years agoMerge "Update openstack-common files."
Jenkins [Tue, 24 Jul 2012 15:55:41 +0000 (15:55 +0000)]
Merge "Update openstack-common files."

12 years agoMerge "Add v2 API support for the Cisco plugin Blueprint cisco-plugin-v2-api-support"
Jenkins [Tue, 24 Jul 2012 07:34:58 +0000 (07:34 +0000)]
Merge "Add v2 API support for the Cisco plugin Blueprint cisco-plugin-v2-api-support"

12 years agoUpdate openstack-common files.
Gary Kotton [Tue, 24 Jul 2012 06:28:56 +0000 (02:28 -0400)]
Update openstack-common files.

The RPC support requires that the fanout_cast messages enable
the application to set the topic. This was fixed in
https://review.openstack.org/#/c/10125/.

In addition to this the jsonutils.py was updated.

Change-Id: I85b5a3a74f129746528910d12acdd00db39d8626

12 years agoInitial V2 implementation of provider extension.
Bob Kukura [Fri, 15 Jun 2012 14:20:05 +0000 (10:20 -0400)]
Initial V2 implementation of provider extension.

Initial provider extension implementation. Specify vlan_id using the
CLI with admin rights via "net-create --tenant_id <tenant-id>
<net-name> --provider:vlan_id <vlan-id>". Also includes
provider:vlan_id in reply messages for admins. The extension is
supported in the linuxbridge and openvswitch plugins.

Partially implements blueprint provider-networks.

Change-Id: I2fff64c4247b1a3091c28c7a2cd632afda192c3d

12 years agoImplements data-driven views and extended attributes.
Bob Kukura [Mon, 16 Jul 2012 00:45:25 +0000 (20:45 -0400)]
Implements data-driven views and extended attributes.

The quantum/api/v2/views.py module is replaced by is_visible
properties in the RESOURCE_ATTRIBUTE_MAP defined in
quantum/api/v2/attributes.py. Extensions are given the ability to add
extended attribute descriptions to this map during initialization,
allowing extended attributes to be implemented similarly to core
attributes in plugins.

Resolves bug 1023111.

Change-Id: Ic6e224d5d841b6a1d4d1c762d7306adaf91f7a2d

12 years agoAdd v2 API support for the Cisco plugin
Sumit Naiksatam [Wed, 18 Jul 2012 20:30:21 +0000 (13:30 -0700)]
Add v2 API support for the Cisco plugin
Blueprint cisco-plugin-v2-api-support

New meta-plugin which makes use of the Quantum db_plugin and supports
the new v2 API
Changes to the Cisco DB model, now reusing quantum DB for core attributes
Changes to the device sub plugins to access the quantum DB for core
resources' state versus Cisco DB
Addition of fake/dummy drivers to support testing of the device sub
plugins even without actual hardware
New v2 unit tests which exercise the meta-plugin and the device sub
-plugins as well
In general creating new v2 modules such that v1.x code can be deprecated
easily by deleting the older modules. The following files are v2
versions of older modules, only the imports have changed, most of the
other code is the same as from the older modules (already reviewed):
quantum/plugins/cisco/common/cisco_credentials_v2.py
quantum/plugins/cisco/db/network_db_v2.py
quantum/plugins/cisco/db/network_models_v2.py
quantum/plugins/cisco/db/nexus_db_v2.py
quantum/plugins/cisco/db/nexus_models_v2.py
quantum/plugins/cisco/db/ucs_db_v2.py
quantum/plugins/cisco/db/ucs_models_v2.py
quantum/plugins/cisco/nexus/cisco_nexus_plugin_v2.py
quantum/plugins/cisco/ucs/cisco_ucs_inventory_v2.py
quantum/plugins/cisco/ucs/cisco_ucs_plugin_v2.py
quantum/plugins/cisco/segmentation/l2network_vlan_mgr_v2.py

All changes are contained with the Cisco plugin.

(Sumit & Rohit)

Change-Id: Ib82a9f843548c286c84ba63caf5406a773ac85b1

12 years agoEnhance V2 validations to work better for integers and booleans
Gary Kotton [Thu, 19 Jul 2012 12:51:38 +0000 (08:51 -0400)]
Enhance V2 validations to work better for integers and booleans

Fixes bug 1026598

The attributes are now able to cast a input value to a specific type.
At the moment boolean and int are supported.

Change-Id: I568a95bc60f91c3eeae03b305031502d50de9c44

12 years agoMerge "Add quota features into quantum. Blueprint quantum-api-quotas"
Jenkins [Fri, 20 Jul 2012 17:28:12 +0000 (17:28 +0000)]
Merge "Add quota features into quantum. Blueprint quantum-api-quotas"

12 years agoRefactor the test cases so that all the test cases are under one test class.
Yong Sheng Gong [Fri, 20 Jul 2012 02:07:44 +0000 (10:07 +0800)]
Refactor the test cases so that all the test cases are under one test class.

Change-Id: I31c5c51a3f7fa4b7cb068b7b93692411956e62ac

12 years agoAdd quota features into quantum.
Yong Sheng Gong [Wed, 11 Jul 2012 04:01:04 +0000 (12:01 +0800)]
Add quota features into quantum.
Blueprint quantum-api-quotas

We support quota check for creating network, subnet and port.
Change-Id: I943335816308767c7eba084d80b969fcb2e5a8fb

12 years agoMerge "Assume that subclass validates value of UUID"
Jenkins [Thu, 19 Jul 2012 17:16:15 +0000 (17:16 +0000)]
Merge "Assume that subclass validates value of UUID"

12 years agoAssume that subclass validates value of UUID
Gary Kotton [Thu, 19 Jul 2012 10:16:34 +0000 (06:16 -0400)]
Assume that subclass validates value of UUID

Change-Id: I8501d10a798cc90c027bb981c5a3ca5a0ef6e622

12 years agofix bug lp:1025526,update iniparser.py to accept empty value.
Yaguang Tang [Tue, 17 Jul 2012 05:23:00 +0000 (13:23 +0800)]
fix bug lp:1025526,update iniparser.py to accept  empty value.

also,this patch turn off pep8 E125 check,this for now seems to
be unnecessary,it check continuous line split.and update the
latest openstack-common https://review.openstack.org/#/c/9201
which has fix pep8 1.3 issue except for E125 check.

Change-Id: I86e6a3add56a0a2941031a1248f1696667ac56b8

12 years agoEnsures policy file is reloaded only if updated.
Salvatore Orlando [Thu, 19 Jul 2012 00:59:42 +0000 (17:59 -0700)]
Ensures policy file is reloaded only if updated.

Fixes bug 1023649

The fix is 'inspired' (ie: copied) from nova. It is cached in memory unless a
change in policy file is detected. In that case, a reload is triggered.

This patch also adds a set of unit tests for quantum/policy.py, which was
previously not covered.

Change-Id: I337042ae418b518268acd30c26ef02559887a8be

12 years agoProvide way to specify id in models_v2
Aaron Rosen [Tue, 17 Jul 2012 05:59:10 +0000 (01:59 -0400)]
Provide way to specify id in models_v2

Bug #1025127

Change-Id: Ie4112b841c1e42408cdb539c2b87446c596e92ba

12 years agoAdd validity checks to Quantum v2 resources
Gary Kotton [Tue, 17 Jul 2012 08:52:20 +0000 (04:52 -0400)]
Add validity checks to Quantum v2 resources

Fixes bug 1015148

The code enable defining validity checks for input variables. This
is done via callback functions per type. The following types are supported:
    - type:values - checks that data is valid according to a list of values
    - type:mac_address - checks that data is a valid mac address
    - type:ip_address - checks that data is a valid ip address
    - type:subnet - checks that data is a valid cidr
    - type:regex - checks that data matches a regular expression (for
      example checking UUID validity)

Change-Id: Iaa694cbfe3c518a5cd3951271853fe986106e7f5

12 years agoMerge "Ryu plugin support for v2 Quantum API"
Jenkins [Wed, 18 Jul 2012 12:39:38 +0000 (12:39 +0000)]
Merge "Ryu plugin support for v2 Quantum API"

12 years agoMerge "Introduce files from openstack common."
Jenkins [Wed, 18 Jul 2012 06:57:27 +0000 (06:57 +0000)]
Merge "Introduce files from openstack common."

12 years agoAvoid removal of attributes used by policy engine
Salvatore Orlando [Tue, 17 Jul 2012 16:32:16 +0000 (09:32 -0700)]
Avoid removal of attributes used by policy engine

Fixes bug1025150

Ensures that each attribute which is used by the policy engine is not
removed by the plugin when the 'fields' query parameter is specified.
This could be better achieved by not having the plugin perform this
selection, but as it is part of the plugin interface, it's probably better
not to introduce changes which alter it.

Change-Id: I68ab0998b7113f06da5df74ccd44e390640de475

12 years agoRaise proper exception if policy file do not exist
justin ljj [Wed, 11 Jul 2012 05:38:26 +0000 (13:38 +0800)]
Raise proper exception if policy file do not exist

Fixes bug 1022966.

Change-Id: Ia1f9a95eb9e956d0d65efb50e674de18d0552b6e

12 years agoIntroduce files from openstack common.
Yong Sheng Gong [Sun, 15 Jul 2012 00:17:34 +0000 (08:17 +0800)]
Introduce files from openstack common.

Because the openstack common project does not stick to latest pep8 rules,
I have to exclude some bad-ruled files in the tox.ini and run_tests.sh.
However pep8 does not support exclude option in the format quantum/openstack/common,
so I have to exclude some of openstack common files one by one.

Also, I have changed the Qunatum Context to base on the common context.

I does not update the setup.py in our openstack common dir and the one
under quantum top dir, since it should be maintained in a consistent way
across all of openstack projects.

After this introduction, we are ready for notification feature.

Change-Id: I2729c2dc3958835374c88d704e842e613785ec14

12 years agoMerge "fix bug lp:1019230,update rpc from openstack-common."
Jenkins [Mon, 16 Jul 2012 21:42:15 +0000 (21:42 +0000)]
Merge "fix bug lp:1019230,update rpc from openstack-common."

12 years agoMerge "ovs-agent exception non-existent ports"
Jenkins [Sun, 15 Jul 2012 19:37:01 +0000 (19:37 +0000)]
Merge "ovs-agent exception non-existent ports"

12 years agoEnsures API v2 router does not load plugin twice
Salvatore Orlando [Thu, 12 Jul 2012 12:14:39 +0000 (05:14 -0700)]
Ensures API v2 router does not load plugin twice

Fixes bug 1020024

The router will simply use the QuantumManager which stores the instance
of the plugin being used by the Quantum server. Changes to unit tests
are for ensuring plugin instances are recycled across tests.

Change-Id: I339a40ee6fef74d938245e9c50c7ed695d866e3b

12 years agoovs-agent exception non-existent ports
Aaron Rosen [Fri, 13 Jul 2012 23:01:34 +0000 (19:01 -0400)]
ovs-agent exception non-existent ports

Bug #1019491

Change-Id: Ica3aa3f6c81e4fd062b752867487c89515fb9446

12 years agoRyu plugin support for v2 Quantum API
Yoshihiro Kaneko [Fri, 13 Jul 2012 07:15:23 +0000 (16:15 +0900)]
Ryu plugin support for v2 Quantum API

blueprint update-ryu-plugin-for-v2

Ryu plugin using the v2 Quantum API.

Change-Id: I9d42b3aee4b51edbc0b80d8f8372f65eb47df9af

12 years agoAdd option sql_max_retries for database connection.
justin ljj [Mon, 9 Jul 2012 03:11:09 +0000 (11:11 +0800)]
Add option sql_max_retries for database connection.

Fixes bug 1019728

also add unit tests for linux bridge plugin config

Change-Id: Ibfea9bac87ba36f301671a35de81577debcd460e

12 years agoMerge "Create DHCP agent tap device from port ID"
Jenkins [Thu, 12 Jul 2012 17:17:55 +0000 (17:17 +0000)]
Merge "Create DHCP agent tap device from port ID"

12 years agoEnable quantum agents to work with global cfg.CONF
Gary Kotton [Sun, 8 Jul 2012 12:05:46 +0000 (08:05 -0400)]
Enable quantum agents to work with global cfg.CONF

This implements blueprint global-config-support

A common configuration parse function is used by the service and the agent.

In the case of the service, when loading the plugin, the configuration file
will be appended to the existing cfg.CONF (this was originally created when
quantum.conf was loaded).

In the case of the agent a global cfg.CONF will be created.

This task is a prerequisite for the RPC integration into Quantum.

Change-Id: I24ef4a804578502bcce484f44dc55c8fe2aa913e

12 years agoCreate DHCP agent tap device from port ID
Gary Kotton [Wed, 11 Jul 2012 11:45:49 +0000 (07:45 -0400)]
Create DHCP agent tap device from port ID

Fixes bug 1022806

Change-Id: If29ffdc35d02f8e18789173f250c1eab28a258fc

12 years agoMerge "Fix some syntax errors."
Jenkins [Tue, 10 Jul 2012 20:35:06 +0000 (20:35 +0000)]
Merge "Fix some syntax errors."

12 years agoMerge "Validate that network_id in port/subnet POST belong to the same tenant"
Jenkins [Tue, 10 Jul 2012 19:37:52 +0000 (19:37 +0000)]
Merge "Validate that network_id in port/subnet POST belong to the same tenant"

12 years agoFix some syntax errors.
Adam Gandelman [Tue, 10 Jul 2012 01:09:18 +0000 (18:09 -0700)]
Fix some syntax errors.

Some syntax errors slipped in with a previous pep8 cleanup to this file.
These errors currently prevent distro packages from installing.

Fixes bug 1023066.

Update: * Proper pep8 indentation.
        * Wrap in paranthesis instead.

Change-Id: I257fbc7f0d8287ac648f2ad23caa7536388486d3

12 years agofix bug lp:1019230,update rpc from openstack-common.
Yaguang Tang [Fri, 6 Jul 2012 16:21:17 +0000 (00:21 +0800)]
fix bug lp:1019230,update rpc from openstack-common.

Change-Id: I498e578affef4fa9df6c50cd7284ebd7e3f9a64e

12 years agoMerge "implement dhcp agent for quantum"
Jenkins [Mon, 9 Jul 2012 20:55:56 +0000 (20:55 +0000)]
Merge "implement dhcp agent for quantum"

12 years agoFix v2 API policy checks when keystone is in use.
Dan Wendlandt [Sun, 8 Jul 2012 19:34:22 +0000 (12:34 -0700)]
Fix v2 API policy checks when keystone is in use.

bug 1022032.  There were significant errors in how
the policy framework was being invoked, but existing
tests did now show them, since they always invoked the
API with no keystone context.  This patch fixes those
issues and add a significant amount of test coverage
simulating API calls with keystone enabled.

As part of this patch, we also needed to add a tenant-id
attribute to the subnet object.  Furthermore, we
changed the API validation code to prevent tenant-id from
being changed with a PUT, since changing it after creation
could invalidate some of the create checks we're planning
on adding (e.g., that a port is being created on a network
owned by the same tenant).

Change-Id: I6da61f0d4ac3b259aa0afcd42cfa8e6ec1a9b035

12 years agoimplement dhcp agent for quantum
Mark McClain [Wed, 27 Jun 2012 18:15:53 +0000 (14:15 -0400)]
implement dhcp agent for quantum

blueprint: quantum-dhcp

This change adds an agent to manage DHCP for Quantum networks

Change-Id: If3c62965550dc0b0a7982b01d3468e2e07e2b775

12 years agoCorrects imported modules in Cisco and Ryu according to latest nova packages.
Soheil Hassas Yeganeh [Fri, 6 Jul 2012 22:27:29 +0000 (18:27 -0400)]
Corrects imported modules in Cisco and Ryu according to latest nova packages.

Change-Id: I58b6d4356b071624c725b4dd0d98a60592ef0b45

12 years agoValidate that network_id in port/subnet POST belong to the same tenant
Juliano Martinez [Thu, 5 Jul 2012 02:32:59 +0000 (23:32 -0300)]
Validate that network_id in port/subnet POST belong to the same tenant

Bug 1014989

Change-Id: I17b619c502afb35fe0829e41a7d0f997d60998fa

12 years agoVerify CIDR overlaps among networks' subnets.
Salvatore Orlando [Thu, 5 Jul 2012 01:20:43 +0000 (02:20 +0100)]
Verify CIDR overlaps among networks' subnets.

Make sure CIDR for subnets in a given network do not overlap each other.

Fixes bug 1021106

Change-Id: I212a734ad59bbba86876d372a2f559f21ac60835

12 years agoAddress problems with foreign keys with subnet and network deletion
Gary Kotton [Wed, 4 Jul 2012 10:54:10 +0000 (06:54 -0400)]
Address problems with foreign keys with subnet and network deletion

This also fixes bug 1020879 and bug 1020847

Change-Id: Ib68f9357ed65f35e56d17577b83fabe8f96388cf

12 years agoAdd 'allocation_pools' to Quantum v2 API subnets.
Salvatore Orlando [Thu, 28 Jun 2012 09:22:36 +0000 (10:22 +0100)]
Add 'allocation_pools' to Quantum v2 API subnets.

This changeset adds a new parameter, 'allocation_pools' to the 'subnet'
resource of the Quantum v2 API.
Allows for creating and validation of subnets with multiple allocation pools.
This commit only deals with POST verb (subnet creation).
PUT verb (subnet update) will be dealt with in a subsequent commit.

This is the first commit for fixing bug #1016308

Change-Id: Ic356dcb5dcfa46af8ecc7e598529881f8bcbbeed

12 years agoDelete IP allocation range for subnet when deleting subnet
Gary Kotton [Tue, 3 Jul 2012 17:11:31 +0000 (13:11 -0400)]
Delete IP allocation range for subnet when deleting subnet

Fixes bug 1020563

Change-Id: I034e490825603ab71662a0bbad9b325f419a9e43

12 years agoFix linux bridge plugin to be consistent with naming rules
Gary Kotton [Tue, 3 Jul 2012 10:34:20 +0000 (06:34 -0400)]
Fix linux bridge plugin to be consistent with naming rules

Fixes bug 1020468

Change-Id: I4a84e6c89c450032a791b9f91bc5e4dac6c9f647

12 years agov2 support for the linux bridge plugin
Gary Kotton [Thu, 28 Jun 2012 10:26:10 +0000 (06:26 -0400)]
v2 support for the linux bridge plugin

blueprint lb-api-v2-support

Plugin support for the linuxbridge using the v2 API

1. The core_plugin in quantum.conf must be set to:
quantum.plugins.linuxbridge.LinuxBridgePluginV2.LinuxBridgePluginV2
2. By default the agent is v2. A configuration file entry 'target_v2_api'
in the section 'AGENT' can be set as False to support v1.

Change-Id: I2e196859c13b28e535c6ec394ec3f5bc907bf019

12 years agoMerge "Ensure that subnet_id is on correct network."
Jenkins [Mon, 2 Jul 2012 21:49:32 +0000 (21:49 +0000)]
Merge "Ensure that subnet_id is on correct network."

12 years agoMerge "Check if interface exists in bridge prior to adding."
Jenkins [Mon, 2 Jul 2012 21:49:00 +0000 (21:49 +0000)]
Merge "Check if interface exists in bridge prior to adding."

12 years agoOVS plugin support for v2 Quantum API
Aaron Rosen [Fri, 29 Jun 2012 01:17:16 +0000 (18:17 -0700)]
OVS plugin support for v2 Quantum API

blueprint: ovs-api-v2-support

This commit allows the ovs_quantum_plugin to work with the v2 api.

change-Id: I9e332a799f6bee8a90755f961fbb9711a1ecdaca

12 years agoCheck if interface exists in bridge prior to adding.
Gary Kotton [Sun, 1 Jul 2012 07:06:07 +0000 (03:06 -0400)]
Check if interface exists in bridge prior to adding.

This fixes bug 1019730. The fix for bug 1000406 ensures that return
values of shell commands are checked. The command
    utils.execute(['brctl', 'addif', bridge_name, interface],
                   root_helper=self.root_helper)
would cause an exception if there was more than one attachment
on the network. The reason for this was the interface already existed
on the bridge.

Change-Id: I8a1f6cc7be930c04ce302d7f87814b9bd5bed129

12 years agoEnsure that subnet_id is on correct network.
Gary Kotton [Sun, 1 Jul 2012 10:46:29 +0000 (06:46 -0400)]
Ensure that subnet_id is on correct network.

Fixes bug 1019759.

Change-Id: I7a732ebf404c6fddaf6f06798411adbadd8ebb3f