]> review.fuel-infra Code Review - openstack-build/heat-build.git/log
openstack-build/heat-build.git
12 years agoMerge "scheduler: Simplify DependencyTaskGroup interface"
Jenkins [Wed, 19 Jun 2013 09:49:45 +0000 (09:49 +0000)]
Merge "scheduler: Simplify DependencyTaskGroup interface"

12 years agoMerge "Support cloud-specific suffixes to server status."
Jenkins [Tue, 18 Jun 2013 23:22:17 +0000 (23:22 +0000)]
Merge "Support cloud-specific suffixes to server status."

12 years agoMerge "Cleanup the doc strings in heat/rpc/client.py"
Jenkins [Tue, 18 Jun 2013 23:05:34 +0000 (23:05 +0000)]
Merge "Cleanup the doc strings in heat/rpc/client.py"

12 years agoMerge "API support for Environments"
Jenkins [Tue, 18 Jun 2013 23:05:27 +0000 (23:05 +0000)]
Merge "API support for Environments"

12 years agoMerge "Make template_format.parse usable by environments"
Jenkins [Tue, 18 Jun 2013 23:05:19 +0000 (23:05 +0000)]
Merge "Make template_format.parse usable by environments"

12 years agoMerge "Remove unused parameter.user_parameters()"
Jenkins [Tue, 18 Jun 2013 23:05:12 +0000 (23:05 +0000)]
Merge "Remove unused parameter.user_parameters()"

12 years agoMerge "Use the Environment from within the engine"
Jenkins [Tue, 18 Jun 2013 23:05:10 +0000 (23:05 +0000)]
Merge "Use the Environment from within the engine"

12 years agoMerge "Add a Fn::Split function to aid provider templates"
Jenkins [Tue, 18 Jun 2013 21:03:56 +0000 (21:03 +0000)]
Merge "Add a Fn::Split function to aid provider templates"

12 years agoMerge "suppress and log API internal exceptions"
Jenkins [Tue, 18 Jun 2013 20:18:19 +0000 (20:18 +0000)]
Merge "suppress and log API internal exceptions"

12 years agoSupport cloud-specific suffixes to server status.
Monty Taylor [Mon, 17 Jun 2013 21:34:33 +0000 (17:34 -0400)]
Support cloud-specific suffixes to server status.

Some clouds, *cough*HP*cough* append extra data to their
status strings. Such as: BUILD(scheduling) or BUILD(networking).
We don't really want to be on the hook for keeping a list of those,
but if we just grab the bit in front of the parenthetical, we should
be able to tell state sensibly, even when people are being weird.

Change-Id: Idaf079d6090db50c9041f398a257b427d63ff48d

12 years agoMerge "scheduler: Improve task descriptions in debug logs"
Jenkins [Tue, 18 Jun 2013 18:12:46 +0000 (18:12 +0000)]
Merge "scheduler: Improve task descriptions in debug logs"

12 years agoautoscaling fix LoadBalancer reload static resolve
Steven Hardy [Mon, 17 Jun 2013 14:54:51 +0000 (15:54 +0100)]
autoscaling fix LoadBalancer reload static resolve

Since https://review.openstack.org/#/c/31083/ we're using the
Resource.update() method to update the LoadBalancer, which requires
the resource snippet to be statically resolved (as is done in
parser.Stack for stack updates)

Fixes bug #1191705

Change-Id: Id2017a912472ddb48245682c5b6392cbcb9e4c60

12 years agoReturn None for physical resource name during validation
Zane Bitter [Tue, 18 Jun 2013 08:41:40 +0000 (10:41 +0200)]
Return None for physical resource name during validation

During template validation, the resources have not been stored in the
database. Therefore any resources that return self.physical_resource_name()
in either FnGetRef() or FnGetAtt() would cause assertions whenever either
of those functions were called during validation. Instead, return None from
physical_resource_name() in this phase, as we do for other data that is not
available yet during validation.

Fixes bug #1191931

Change-Id: I1a5b17557ae1ca2600fb930e74eb5248c82e0326

12 years agoStandardise resource names in Invalid Attribute errors
Zane Bitter [Tue, 18 Jun 2013 08:25:52 +0000 (10:25 +0200)]
Standardise resource names in Invalid Attribute errors

These should always refer to the resource name in the template (i.e.
logical resource name), and never the physcial resource name (since these
errors necessarily occur during validation, before any physical resource is
created).

Change-Id: I6cf6625cf32a90acb27adc6348695c086dc5e119

12 years agoMerge "Add InstanceId property to EIP resource"
Jenkins [Tue, 18 Jun 2013 03:11:00 +0000 (03:11 +0000)]
Merge "Add InstanceId property to EIP resource"

12 years agosuppress and log API internal exceptions
Liang Chen [Fri, 7 Jun 2013 15:01:02 +0000 (23:01 +0800)]
suppress and log API internal exceptions

add a context manager to handle exceptions generated by API
implementation methods or their decorators

Fixes bug #1187881

Change-Id: I4bd75e1e13f8327aaf2283380bf165a57a11ed8c

12 years agoMerge "engine : abstract state-transition logic"
Jenkins [Tue, 18 Jun 2013 01:05:13 +0000 (01:05 +0000)]
Merge "engine : abstract state-transition logic"

12 years agoMerge "Convert Resource to separate action/status"
Jenkins [Tue, 18 Jun 2013 01:05:09 +0000 (01:05 +0000)]
Merge "Convert Resource to separate action/status"

12 years agoAdd a Fn::Split function to aid provider templates
Angus Salkeld [Tue, 18 Jun 2013 00:15:41 +0000 (10:15 +1000)]
Add a Fn::Split function to aid provider templates

This needed to convert a parameter in CommaDelimedList into
a property of type List.

part of blueprint provider-resource
Change-Id: Id77a2c6be47427360a2be89ca1fea3c097807bac

12 years agoMerge "Initial Environment class and test"
Jenkins [Mon, 17 Jun 2013 17:01:50 +0000 (17:01 +0000)]
Merge "Initial Environment class and test"

12 years agoAdd InstanceId property to EIP resource
Jeff Peeler [Mon, 17 Jun 2013 16:19:49 +0000 (12:19 -0400)]
Add InstanceId property to EIP resource

This also changes the InstanceId property for an EIPAssociation
to not be required, which was necessary for testing and is inline
with AWS documentation.

Change-Id: I49dd506309fe6a38df6727bca7f6bbebd45fba3f
Fixes: bug #1164864
12 years agoscheduler: Simplify DependencyTaskGroup interface
Zane Bitter [Thu, 13 Jun 2013 18:03:27 +0000 (20:03 +0200)]
scheduler: Simplify DependencyTaskGroup interface

Instead of passing a function that takes one argument and returns a task
that takes no arguments, simply pass a task that takes one argument.

Change-Id: I73d5f137d5db492c09e6887f80e7e759734c211f

12 years agoscheduler: Improve task descriptions in debug logs
Zane Bitter [Mon, 17 Jun 2013 15:42:04 +0000 (17:42 +0200)]
scheduler: Improve task descriptions in debug logs

Tasks that were simply defined as ordinary functions (not methods) were
identified by their repr() in the logs, which is only really desirable as a
last resort and for objects (where the __call__() method is the task). Use
the function name instead.

Change-Id: Ie34a3602deb968979118b0961bcddf226cf5983f

12 years agoCleanup the doc strings in heat/rpc/client.py
Angus Salkeld [Mon, 3 Jun 2013 03:05:27 +0000 (13:05 +1000)]
Cleanup the doc strings in heat/rpc/client.py

Change-Id: Ia760937f729a1aa17d84c48054cb143bf6891bfd

12 years agoAPI support for Environments
Angus Salkeld [Mon, 17 Jun 2013 04:39:19 +0000 (14:39 +1000)]
API support for Environments

Support "Environment" section in the create/update body.
We the roll up the parameters and the environment and send
that as json using the rpc "params" argument. So no changes
to the rpc layer are needed. The engine knows how to deal
with both formats in the Environments class.

blueprint envirnonments
Change-Id: I6d6085d5c052a5f9115ecd46891b00d2fad4d1db

12 years agoMake template_format.parse usable by environments
Angus Salkeld [Thu, 13 Jun 2013 02:24:02 +0000 (12:24 +1000)]
Make template_format.parse usable by environments

(environments don't want template sections)

blueprint environments
Change-Id: I68ac0b8fb0889d245ace4d0ea8d298460c4c1b1a

12 years agoUse PhysName for testing Swift container names
Zane Bitter [Mon, 17 Jun 2013 10:24:50 +0000 (12:24 +0200)]
Use PhysName for testing Swift container names

Change-Id: Icc000a9235fcd9ee810581b932ded73319decfee

12 years agoFix bizarre Swift DeletionPolicy unit tests
Zane Bitter [Mon, 17 Jun 2013 10:24:50 +0000 (12:24 +0200)]
Fix bizarre Swift DeletionPolicy unit tests

If something shouldn't be called... don't tell the mocks to expect it to be
called. We will get UnexpectedMethodCallError if it is.

Change-Id: I61a7b77cb273b42177a37efa98fc62fd69770545

12 years agoUse physical_resource_name() for Swift containers
Zane Bitter [Mon, 17 Jun 2013 10:24:50 +0000 (12:24 +0200)]
Use physical_resource_name() for Swift containers

This returns names which are of the same form, but which are based on the
resource id (and hence are stable).

Change-Id: Id091bdef74e07fc0df0e6e4914dae8af8b29384c

12 years agoRemove unused parameter.user_parameters()
Angus Salkeld [Thu, 30 May 2013 01:51:17 +0000 (11:51 +1000)]
Remove unused parameter.user_parameters()

blueprint environments
Change-Id: I21246a62f82064120d6ebd4c5e1c607f43df55bc

12 years agoUse the Environment from within the engine
Angus Salkeld [Fri, 14 Jun 2013 10:56:02 +0000 (20:56 +1000)]
Use the Environment from within the engine

at this point the concept only exists in the engine, the
api and client changes will come in later patches.

blueprint environments
Change-Id: I3e208bb72a04bf275bead2aec89006cf680b501b

12 years agoUse physical resource names with a short_id
Zane Bitter [Mon, 17 Jun 2013 10:24:49 +0000 (12:24 +0200)]
Use physical resource names with a short_id

The short_id is a random, but stable, 12-character alphanumeric ID.

This will allow two resources of the same name to exist concurrently. That
is necessary for resources to be replaced during an update without
interruption.

Change-Id: If32904a47c6f8fb651e317ce91f2a04f6eadcc0b

12 years agoInitial Environment class and test
Angus Salkeld [Thu, 13 Jun 2013 03:59:08 +0000 (13:59 +1000)]
Initial Environment class and test

This implements the "resource-registry" and "parameters" section
I am holding off on the "properties" section until we really
know we need it.

blueprint environments
Change-Id: Ib6e9e5cd1c68c255dc048bdde21a6b3e1dc54243

12 years agoMerge "Remove unused python-memcached from requirements."
Jenkins [Mon, 17 Jun 2013 00:39:34 +0000 (00:39 +0000)]
Merge "Remove unused python-memcached from requirements."

12 years agoengine : abstract state-transition logic
Steven Hardy [Mon, 10 Jun 2013 15:27:18 +0000 (16:27 +0100)]
engine : abstract state-transition logic

Refactor to abstract the handle_create/check_create_complete
logic, so it can be reused without lots of duplication for
other action transitions

Prompted by review comments from:
https://review.openstack.org/#/c/31982/2/heat/engine/resource.py
related to blueprint: stack-suspend-resume

Change-Id: Idb18913ef6ff700b63d5ec6d340d2353fc2294b7

12 years agoConvert Resource to separate action/status
Steven Hardy [Fri, 14 Jun 2013 10:02:09 +0000 (11:02 +0100)]
Convert Resource to separate action/status

Next step in decoupling action/status

This adjusts the Resource DB columns, model and class to be consistent
with Event, and split action/status.  This also modifies the both APIs
to join the action/status to avoid changing the API (we can't change
the CFN one anyway and it's desirable to avoid breaking compatibility
with the ReST API, or needing a version bump for this simple change)

Change-Id: I02b56eb14045a058e67b9764d386530d555c339e

12 years agoStore stacks in the database when running unit tests
Zane Bitter [Fri, 14 Jun 2013 10:31:23 +0000 (12:31 +0200)]
Store stacks in the database when running unit tests

If stacks are not stored in the database before they are create()'d,
anything that refers to a stack (e.g. Resources and Events) cannot be added
to the database either, and we get numerous errors in any output logs.

Change-Id: Icd1012455d413aad617486c138fd4507e391bc7b

12 years agoUnit tests: Create User for testing AccessKey
Zane Bitter [Fri, 14 Jun 2013 10:31:22 +0000 (12:31 +0200)]
Unit tests: Create User for testing AccessKey

An AccessKey resource is not independent of its associated User resource,
which must be present in the same stack. Consequently, we need to create a
real User resource that is a member of the same stack in order to test the
AccessKey in a realistic environment.

Change-Id: I4b732c93fe9823552baf65c3f9c87c8ebab061a4

12 years agoMerge "Make resource ids UUIDs in the database"
Jenkins [Fri, 14 Jun 2013 09:59:13 +0000 (09:59 +0000)]
Merge "Make resource ids UUIDs in the database"

12 years agoMerge "Gate on H703"
Jenkins [Fri, 14 Jun 2013 08:53:26 +0000 (08:53 +0000)]
Merge "Gate on H703"

12 years agoMake resource ids UUIDs in the database
Zane Bitter [Thu, 13 Jun 2013 18:03:26 +0000 (20:03 +0200)]
Make resource ids UUIDs in the database

Change-Id: I3068e9e818f19994cc3aaecc34845d0d6aac0dfb

12 years agoUnit tests: Don't use mox to stub uuid.uuid4()
Zane Bitter [Thu, 13 Jun 2013 18:03:26 +0000 (20:03 +0200)]
Unit tests: Don't use mox to stub uuid.uuid4()

The wait condition unit tests require a fixed stack ID, but we don't want
to permanently stub out uuid4, since there are other potential uses of
uuids. Instead, just do it for that one operation.

Change-Id: Ib8b7107a5750caf67aa8905377c2755bf405fa3f

12 years agoMerge "allow using image uuid for instance resource"
Jenkins [Thu, 13 Jun 2013 14:52:15 +0000 (14:52 +0000)]
Merge "allow using image uuid for instance resource"

12 years agoMerge "fix an CFN API and AWS error mapping"
Jenkins [Thu, 13 Jun 2013 12:50:52 +0000 (12:50 +0000)]
Merge "fix an CFN API and AWS error mapping"

12 years agoConvert Events to separate action/status
Steven Hardy [Thu, 13 Jun 2013 10:19:32 +0000 (11:19 +0100)]
Convert Events to separate action/status

First step in decoupling action/status in Resource

This adjusts the Event DB columns, model and class to split
action/status, but in order to be backwards compatible we set the action
to None, which means we can do the right thing in the CFN API, and
resource_status still maps correctly to what is expected in
python-heatclient (which will need to change after the Resource
action/status split happens)

Change-Id: I261d47d2a3fdb3cdc2a8aaf6c159763f4636f633

12 years agoMerge "Use Python 3.x compatible except construct"
Jenkins [Thu, 13 Jun 2013 05:32:43 +0000 (05:32 +0000)]
Merge "Use Python 3.x compatible except construct"

12 years agoallow using image uuid for instance resource
Liang Chen [Fri, 7 Jun 2013 02:12:30 +0000 (10:12 +0800)]
allow using image uuid for instance resource

make the instance resource accept image uuid for its ImageId
properties in addition to unique image name.

Fixes bug #1186410

Change-Id: Iae7705e73fe223d80e85d261a04f88f8c5207487

12 years agofix an CFN API and AWS error mapping
Liang Chen [Wed, 12 Jun 2013 13:47:05 +0000 (21:47 +0800)]
fix an CFN API and AWS error mapping

StackExists should return AlreadyExists, not InvalidParameterValue

Fixes bug #1188473

Change-Id: Ia969cddc1b61caa13f4f70bcc29f3160595a779b

12 years agoRemove unused python-memcached from requirements.
Steve Baker [Wed, 12 Jun 2013 01:58:27 +0000 (13:58 +1200)]
Remove unused python-memcached from requirements.

Change-Id: I6da8607203d15275a05faa7f7ccc570c31f86762

12 years agoUse Python 3.x compatible except construct
Dirk Mueller [Wed, 12 Jun 2013 20:55:03 +0000 (22:55 +0200)]
Use Python 3.x compatible except construct

Python 3.x deprecated excecpt x,y. Use except x as y,
which works with any Python version >= 2.6

Change-Id: I264049ee41e75bcedea86adf7c2011c343f47ddb

12 years agoAdd bin/heat-manage to flake8 checks
Dirk Mueller [Wed, 12 Jun 2013 20:54:05 +0000 (22:54 +0200)]
Add bin/heat-manage to flake8 checks

Change-Id: I917e5b0aa571f2fced7df6a4818f32ce4b5f1561

12 years agoGate on H703
Dirk Mueller [Tue, 11 Jun 2013 18:17:18 +0000 (20:17 +0200)]
Gate on H703

Fix fallout by avoiding multiple positional arguments.

Change-Id: Ie25f7b9041fa5df85a244cb237124440bb7d8e32

12 years agoMerge "scheduler: Fix an issue with wrappertasks and exceptions"
Jenkins [Wed, 12 Jun 2013 14:10:23 +0000 (14:10 +0000)]
Merge "scheduler: Fix an issue with wrappertasks and exceptions"

12 years agoMerge "Fix various Sphinx errors/warnings"
Jenkins [Wed, 12 Jun 2013 10:56:52 +0000 (10:56 +0000)]
Merge "Fix various Sphinx errors/warnings"

12 years agoscheduler: Fix an issue with wrappertasks and exceptions
Zane Bitter [Wed, 12 Jun 2013 10:48:25 +0000 (12:48 +0200)]
scheduler: Fix an issue with wrappertasks and exceptions

Using a 'for' loop on a generator is incompatible with calling throw() on
it, because the latter causes the generator to advance to the next yield.
Consequently, ignoring an exception from a subtask in the parent task would
cause the next subtask to be skipped.

This issue does not affect any existing code to date.

The inner and outer loops should each be equivalent to the definition of
"yield from" (http://www.python.org/dev/peps/pep-0380/#formal-semantics) in
PEP 380, with the following simplifications:
 - Assume that the throw() and close() methods exist
 - Don't support send()
 - Don't support return values (these are Python 3-only feature)

Change-Id: Ie29e68d4505f667f408b67b365c37511f73372fe

12 years agoMerge "Remove explicit distribute depend."
Jenkins [Wed, 12 Jun 2013 09:15:47 +0000 (09:15 +0000)]
Merge "Remove explicit distribute depend."

12 years agoMerge "Fix H702 errors and enable them"
Jenkins [Wed, 12 Jun 2013 08:37:25 +0000 (08:37 +0000)]
Merge "Fix H702 errors and enable them"

12 years agoMerge "Key error when auth in standalone mode"
Jenkins [Wed, 12 Jun 2013 07:54:30 +0000 (07:54 +0000)]
Merge "Key error when auth in standalone mode"

12 years agoFix H702 errors and enable them
Angus Salkeld [Tue, 11 Jun 2013 22:43:37 +0000 (08:43 +1000)]
Fix H702 errors and enable them

 - Formatting operation should be outside of localization method call

Change-Id: Icedbb98e46a52b53db7143a4111da13466a26847

12 years agoMerge "Add descriptions of the pep8 checks"
Jenkins [Tue, 11 Jun 2013 22:46:59 +0000 (22:46 +0000)]
Merge "Add descriptions of the pep8 checks"

12 years agoRemove explicit distribute depend.
Monty Taylor [Tue, 11 Jun 2013 18:39:32 +0000 (11:39 -0700)]
Remove explicit distribute depend.

Causes issues with the recent re-merge with setuptools. Advice from
upstream is to stop doing explicit depends.

Change-Id: If390cdf328b361d0f76315083f3e6da97bbe4b2f

12 years agoKey error when auth in standalone mode
Andrew Plunk [Tue, 11 Jun 2013 15:18:10 +0000 (10:18 -0500)]
Key error when auth in standalone mode

Fix a key error caused from the response of authing
in stand alone mode. The keystone docs indicate that
the schema for a response user name is ['user']['name']
rather than ['user']['username'].

Change-Id: I9ac94feeef8f9f2dedaa3842f64a3491e701e199

12 years agoengine : remove GreenletExit workaround
Steven Hardy [Mon, 10 Jun 2013 12:34:57 +0000 (13:34 +0100)]
engine : remove GreenletExit workaround

Both heat and oslo now require the version of greenlet containing
the fix (greenlet>=0.3.2) so we no longer need this workaround

Change-Id: I42af8e020f08480dda08f4b4879c2840e741ea59

12 years agoMerge "Adds possible topdir to python search path"
Jenkins [Tue, 11 Jun 2013 11:40:42 +0000 (11:40 +0000)]
Merge "Adds possible topdir to python search path"

12 years agoAdd descriptions of the pep8 checks
Angus Salkeld [Tue, 11 Jun 2013 03:05:51 +0000 (13:05 +1000)]
Add descriptions of the pep8 checks

Change-Id: Ida2be020b8ed7ea047e11c4b8fa2f5154a444977

12 years agoMerge "Return empty string when Fn::Select target is None."
Jenkins [Tue, 11 Jun 2013 00:30:14 +0000 (00:30 +0000)]
Merge "Return empty string when Fn::Select target is None."

12 years agoMerge "Add Fn::Replace template function."
Jenkins [Tue, 11 Jun 2013 00:30:11 +0000 (00:30 +0000)]
Merge "Add Fn::Replace template function."

12 years agoFix various Sphinx errors/warnings
Dirk Mueller [Mon, 10 Jun 2013 21:49:40 +0000 (23:49 +0200)]
Fix various Sphinx errors/warnings

Change-Id: If34202291b5605302baf47c210b07ffc4ffad094

12 years agoMerge "Initial mariadb support"
Jenkins [Mon, 10 Jun 2013 10:24:01 +0000 (10:24 +0000)]
Merge "Initial mariadb support"

12 years agoMerge "Use Python 3.x compatible octal literals"
Jenkins [Mon, 10 Jun 2013 10:23:02 +0000 (10:23 +0000)]
Merge "Use Python 3.x compatible octal literals"

12 years agoMerge "raise an UnknownUserParameter exception when receiving an unknown param"
Jenkins [Mon, 10 Jun 2013 09:21:17 +0000 (09:21 +0000)]
Merge "raise an UnknownUserParameter exception when receiving an unknown param"

12 years agoUse Python 3.x compatible octal literals
Dirk Mueller [Mon, 10 Jun 2013 07:46:34 +0000 (09:46 +0200)]
Use Python 3.x compatible octal literals

Python 3.x deprecated the 0700 construct. 0o700
works with any version of Python (>= 2.6 tested)

Change-Id: I47fcb79804b75437e6cf4ce966fbfdc05fce26cd

12 years agoAdds possible topdir to python search path
Jianing YANG [Mon, 10 Jun 2013 07:45:43 +0000 (15:45 +0800)]
Adds possible topdir to python search path

Change-Id: Ide47656071c6d17482b1e4ec0727ce316033e702
Fixes: bug #1189354
12 years agoReturn empty string when Fn::Select target is None.
Steve Baker [Sun, 9 Jun 2013 23:44:45 +0000 (11:44 +1200)]
Return empty string when Fn::Select target is None.

This can happen when a resource is not in the required state
to resolve its FnGetAtt.

Change-Id: I4d104b3577fbd94b920ff172c00d60914d7acd45

12 years agoAdd Fn::Replace template function.
Steve Baker [Wed, 5 Jun 2013 01:41:36 +0000 (13:41 +1200)]
Add Fn::Replace template function.

This is implemented with python str.replace

For yaml templates, this should be used as a better alternative to
Fn::Join: ['', [...]]

For json templates, the following common pattern:
"Fn::Join": ["", ["line 1\n", ... "line 2\n"]]
could now become more maintainable as:
"Fn::Replace": [{...}, "Fn::Join": ["\n", ["line 1", ... "line 2"]]]

Implements blueprint template-string-function
Implements blueprint bash-environment-function

Change-Id: Ie4817b1d98dd6d6390e086da9b582d33415a0d9f

12 years agoInitial mariadb support
Attila Fazekas [Sat, 8 Jun 2013 20:38:04 +0000 (22:38 +0200)]
Initial mariadb support

mariadb only differs in the package name from the mysql,
an already installed mariadb should not cause hangup in a
devstack installation.

Fixing Bug 1184722

Change-Id: I3b9d02b703e49044999ff1b9f1195ffcaf1d0cec

12 years agoraise an UnknownUserParameter exception when receiving an unknown param
Liang Chen [Wed, 5 Jun 2013 08:41:14 +0000 (16:41 +0800)]
raise an UnknownUserParameter exception when receiving an unknown param

add some validation logic to Parameters, so that when an invalid param
is passed in an exception will be raised.

Fixes bug #1186790

Change-Id: I8aece556d8fc5cd5533f4baf041e345bdc5722ec

12 years agoEnable H403
Dirk Mueller [Fri, 7 Jun 2013 13:44:23 +0000 (15:44 +0200)]
Enable H403

Fix the only two places where it triggered alongway.

Change-Id: Ib76e0e072c2d51a9c782f37d5f5df964f2db968f

12 years agoget rid of no-op __init__ methods
Christopher Armstrong [Thu, 30 May 2013 20:54:25 +0000 (20:54 +0000)]
get rid of no-op __init__ methods

There were a lot of __init__ methods that simply called their super()
with nothing else.

Change-Id: I6771912adf81f145d09f950c57d219bd77789822

12 years agoMerge "Make autoscale not dependent on loadbalancer impl."
Jenkins [Thu, 6 Jun 2013 12:59:22 +0000 (12:59 +0000)]
Merge "Make autoscale not dependent on loadbalancer impl."

12 years agoMerge "Rename functions which should not be run as tests."
Jenkins [Thu, 6 Jun 2013 09:37:18 +0000 (09:37 +0000)]
Merge "Rename functions which should not be run as tests."

12 years agoMerge "Fix instance creation when a network with no subnet is used"
Jenkins [Thu, 6 Jun 2013 09:07:04 +0000 (09:07 +0000)]
Merge "Fix instance creation when a network with no subnet is used"

12 years agoMerge "flake8 F812 list comprehension redefines fix."
Jenkins [Thu, 6 Jun 2013 08:46:56 +0000 (08:46 +0000)]
Merge "flake8 F812 list comprehension redefines fix."

12 years agoRename functions which should not be run as tests.
Steve Baker [Thu, 6 Jun 2013 03:34:45 +0000 (15:34 +1200)]
Rename functions which should not be run as tests.

These function names confuse some test runners which results in them
incorrectly being run as tests.

Change-Id: I0780c7d6dcea5019771b42fa5ffb2ebe215c1e20

12 years agoflake8 F812 list comprehension redefines fix.
Steve Baker [Thu, 6 Jun 2013 03:30:40 +0000 (15:30 +1200)]
flake8 F812 list comprehension redefines fix.

This warning is given from the following version of flake8
2.0 (pep8: 1.4.5, mccabe: 0.2.1, pyflakes: 0.6.1)

Change-Id: Ic2ac3be2b76aa2d9e8d0f306d1579b195a998b68

12 years agoOnly call FnGetAtt if resource is in acceptable state.
Steve Baker [Tue, 4 Jun 2013 04:40:12 +0000 (16:40 +1200)]
Only call FnGetAtt if resource is in acceptable state.

This will give resource type authors some certainty on what error
checking their FnGetAtt methods will require.

Fixes bug: #1184794

Change-Id: Iec456075c14cd609cf9607f07bce23e4c6b33c0c

12 years agoMake Fn::GetAtt add a dependency
Zane Bitter [Fri, 31 May 2013 10:52:30 +0000 (12:52 +0200)]
Make Fn::GetAtt add a dependency

This will ensure that resources which get attributes from other resources
are not created until the latter resources are available.

An audit of all the templates in the heat-templates repo revealed that in
only one case did this cause a circular reference, and it was the template
that appeared to be incorrect (it has since been fixed).

Change-Id: Ibd51acdda55c24f665c5ca887040f3564d952c0e

12 years agoUse - instead of . for physical_resource_name delim.
Steve Baker [Wed, 5 Jun 2013 21:41:44 +0000 (09:41 +1200)]
Use - instead of . for physical_resource_name delim.

Avoiding using . means that instance hostnames are unique within the stack
(and within the tenant).

This solves 2 real-world use cases:
- tripleo issue, as described in bug: #1184713
- OpenShift template resorts to setting the hostname to ec2_instance_id

This may have an impact on users who are scripting to assume . delimiting,
however this will only affect newly created stacks after this change is
deployed.

Fixes bug: #1184713

Change-Id: I5a8eb358ea9c52162eb9263b9f9e6dcf750d787b

12 years agoMake autoscale not dependent on loadbalancer impl.
Andrew Plunk [Wed, 5 Jun 2013 19:54:41 +0000 (14:54 -0500)]
Make autoscale not dependent on loadbalancer impl.

Autoscale was calling reload on a resource, which is not part of the
resource interface. Autoscale has been modified to use update.

Change-Id: Ifb17c9def7e560d96e26308db67b4ee3f93a2b9f

12 years agoUse a physical name matching class in unit tests
Zane Bitter [Wed, 5 Jun 2013 08:15:56 +0000 (10:15 +0200)]
Use a physical name matching class in unit tests

This gives us the flexibility to change the format of the physical resource
name.

Change-Id: Ie36453345149291fe04d89b52d7966816e03cda6

12 years agoMerge "Add Fn::Select template function"
Jenkins [Wed, 5 Jun 2013 04:20:58 +0000 (04:20 +0000)]
Merge "Add Fn::Select template function"

12 years agoMerge "For Fn::Join, replace None items with an empty string."
Jenkins [Wed, 5 Jun 2013 02:20:41 +0000 (02:20 +0000)]
Merge "For Fn::Join, replace None items with an empty string."

12 years agoAdd Fn::Select template function
Angus Salkeld [Tue, 4 Jun 2013 23:37:19 +0000 (09:37 +1000)]
Add Fn::Select template function

It also knows how to lookup keys in dict's too.
The strings can be a serialized json blob too.

blueprint fn-select
blueprint fn-mapselect
Change-Id: Ie40afa47c1f0a699abb852bc22388f3f675172e6

12 years agoFix instance creation when a network with no subnet is used
Simon Pasquier [Tue, 4 Jun 2013 14:42:50 +0000 (16:42 +0200)]
Fix instance creation when a network with no subnet is used

It is possible with OpenStack Networking to create a network with no
subnet attached to it.
When creating an instance associated to such a network, the engine would
raise a 'list index out of range' exception because the instance has no
IP address on the network.
The issue would also happen with a loadbalancer referencing the same
type of instance.

Change-Id: I6122efb90877d8020added44aee8802eb8a80297
Fixes: bug #1187023
12 years agoMerge "Relax lxml version requirements."
Jenkins [Tue, 4 Jun 2013 09:35:43 +0000 (09:35 +0000)]
Merge "Relax lxml version requirements."

12 years agoFor Fn::Join, replace None items with an empty string.
Steve Baker [Tue, 4 Jun 2013 05:25:42 +0000 (17:25 +1200)]
For Fn::Join, replace None items with an empty string.

Currently, attempts to join lists with None items results in an error.

This change is required for the next attempt to fix bug: #1184794

Change-Id: Ib599eeb21b7325ff797768100f1556a424a8bde9

12 years agoRelax lxml version requirements.
Steve Baker [Tue, 4 Jun 2013 02:45:59 +0000 (14:45 +1200)]
Relax lxml version requirements.

This was preventing devstack from starting on Fedora 18 due to the
package python-lxml-3.2.1-1.fc18.x86_64 being too new.

This change is aligns the lxml rule with the requirements project.

Change-Id: Idd3697596dcefb830d60f8e44171b8c50e78178a

12 years agotests : fix cut/paste test name shadowing
Steven Hardy [Mon, 3 Jun 2013 22:57:33 +0000 (23:57 +0100)]
tests : fix cut/paste test name shadowing

Fix test class duplication

Change-Id: I4ff21b60ad6c70d8d4563db54c9afd83f59d6957

12 years agoMerge "Handle metadata updates during stack creation"
Jenkins [Mon, 3 Jun 2013 18:31:11 +0000 (18:31 +0000)]
Merge "Handle metadata updates during stack creation"

12 years agoMerge "Log at DEBUG level in unit tests"
Jenkins [Mon, 3 Jun 2013 08:23:51 +0000 (08:23 +0000)]
Merge "Log at DEBUG level in unit tests"