add missing licence header

Change-Id: I95d883c7c58ecba925bc6fa41d7a9491b18a55fa
When updating the metadata load the stack with the stored context

bug 1144996
Signed-off-by: Angus Salkeld <asalkeld@redhat.com>

Change-Id: I2b0547f4867f19f8319e2c4b79ac325ae8cd6bd8
Test coverage for NestedStack, and fix FnGetRefId

NestedStack now has 100% coverage. resource_id is now set during create
instead of evaluated during FnGetRefId

Fixes: Bug #1131534
Change-Id: I21966acc711a801d28a8a22c377758d2363dd096
Merge "When updating the metadata load the stack with the stored context"
Allow instance NetworkInterfaces to be list of str or dict

It should be possible to specify NetworkInterfaces of an instance either
as an array of strings or as an array of dicts.

The following should now be possible:
This will define nics in the order specified by DeviceIndex
"NetworkInterfaces" : [
  { "NetworkInterfaceId" : {"Ref" : "controlXface"}, "DeviceIndex" : "0" },
  { "NetworkInterfaceId" : {"Ref" : "controlXface2"}, "DeviceIndex" : "1" },
],

This will define nics in the order specified by list position
"NetworkInterfaces" : [{"Ref" : "controlXface"}, {"Ref" : "controlXface2"}],

Mixing the 2 forms is supported but the resulting order is not defined.

Amazon documentation is ambigious about which form is actually supported
http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-instance.html#cfn-ec2-instance-networkinterfaces
http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/quickref-ec2.html#cfn-template-snippets-eni
Fixes: Bug #1096013

Change-Id: Id387d2e750cbe533a9b8a1fedc49d5bcf690fbcf
heat engine : Ensure properties validation is caught

Rework usage of properties.validate() so that we always
catch the error and set the resource state to failed when
a properties validation error occurs

fixes bug 1146529

Change-Id: I4c5b24cc29a19a5170852aa7626031f9612b3272
Merge "Test coverage for NestedStack, and fix FnGetRefId"
Merge "heat engine : Ensure properties validation is caught"
make parsed template snapshots before updating

This is to make sure that as the update progresses and dependant
resources are modified/replaced that we compare the original
dynamic data with the current.

bug 1134258
Change-Id: Ia4e474e914aa9e99e5e569c4f2276beb55798421
heat engine : Loadbalancer template watch reference should be Ref

Replace hard-coded reference to latency_watcher with Ref, otherwise
the name is not fully qualified for the nested stack and the engine
fails to lookup the watchrule

ref bug 1133510

Change-Id: If0352726ee89e2c8b78beb9436be36b811f1e1cd
heat engine : watchrule quietly discard unused metric data

Some cfn-push-stats options try to send multiple metrics to a
watch, which won't work with our simplified CW implementation
which expects exactly one Metric associated with each watch
(since that's all you can define via the template)
So quietly discard any metric data we aren't interested in.

ref bug 1133510

Change-Id: I5159611b96c501ff2d8e6e605cbd3d4ae5f77e48
Allow REST stack lookup by ARN

This uses the same approach as the cfn api, which assumes the stack
name is an arn, before falling back to an identify_stack call.

Change-Id: I64e9826fa58e05863e9459d3aab041a8d7997405
Fixes: Bug #1131759
Switch to oslo.config

The oslo-config package has been renamed. Switch to the new
version.

Change-Id: I6a0fa803b0076bc5338c996e21bbcef54e1d75cd
Merge "make parsed template snapshots before updating"
fakes: remove some duplicate methods

My pyflakes is complaining...

Change-Id: I1c846377ac56d5cbf941b51e48a7baacecc926fe
Merge "Switch to oslo.config"
Merge "Allow REST stack lookup by ARN"
Merge "Allow instance NetworkInterfaces to be list of str or dict"
Convenience method to look up resource by FnGetRefId

This assumes that no resource will raise an error when FnGetRefId is
called, and any resource that does really needs to be fixed.

Change-Id: I5b58a28661e4eb10ccb21e8b50ec131937618d4a
heat tests : move GenericResource into tests directory

The resource.py GenericResource type is only used in tests, so
move it into the tests area, such that it can't accidentally be
used in the main heat codebase when we fail to import any resource
plugins..

Change-Id: I3912cc540903002a6dd5109e7ce51c7eb67ebf10