Use ScaledResource as type for InstanceGroup members

Use the placeholder type OS::Heat::ScaledResource as the nominal resource
type for resources in an instance group. Use the environment to select the
actual underlying resource type (current AWS::EC2::Instance).

Change-Id: I52252c596fa48e57d927eb78e9d5b7c8261adb3e
run_test.sh -V --unit doesn't run using virtualenv

Before this change, when you called the script using the -V option, the tests
were run outside the virtualenv that the script creates.
To fix it, I modified the lines of the script that run the tests to run
inside the virtualenv using the $wrapper variable.

Change-Id: I5c202727e0b5214670d54e14c80a68cc8ebec400
Closes-Bug: #1251730
Bump to sqlalchemy-migrate 0.8.2

This allows us to drop some unsightly sqlalchemy-migrate 0.7.3
patching.

The related requirements change is here:

  Icde6248ca102884323d7912bab0f4a716aa294ec

Change-Id: I5f80dfc07f8256716d025002fc1a1f47e58b2142
Make db API respect context show_deleted

Currently the soft-delete aware stuff in the DB api only respects
flags passed in directly, not the context.show_deleted, so align
the code with what is implied by existing comments and respect
the flag in the context too.

Change-Id: I88cd1a8862a2a53c314849e11d026182180bce9b
blueprint: request-scoping-policy
Return map parsed value at JsonParam.value

Currently, JsonParam returns String value as JsonParam.value.
However, SCHEMA_TYPES:MAP property doesn't support getting String value.
JsonParam have to return map value for to work properly.

Fixes bug #1256891

Change-Id: I5acc1aa95c0c0e7bebc760d8bf088971630696ec
Add attributes schema to OS::Neutron::FloatingIP

FloatingIP now validates attributes against a schema instead of
accepting all possible inputs and filtering on the result returned by
neutron.

Change-Id: I3bf1c3728a9d6faab71c2312f331d73b1460c013
Closes-Bug: #1240893
Property methods for resource metadata

For OS::Nova::Server which will build its metadata dynamically
based on currently available SoftwareDeployment resources.
This change makes it possible to:
* read and assign resource.metadata as before
* subclassses to override resource.metadata for building dynamically
* allowing access to the simple attribute based resource._metadata
  when necessary

partial blueprint: hot-software-config
Change-Id: Ifd7aa15dd58c96e6b9efafe6b4201a964e140d8d
Add collection count to stack list

Add an optional parameter ``with_count`` to the stack_list API to
allow the inclusion of the collection count in the body of the response

When passing the parameter, the response looks like:
{
  'stacks': [...],
  'count': 42
}

blueprint: count-stacks
Change-Id: I560cfff9d327db9b325e7cf4786bd2fcd71d47b2
tests: use server.test not example.com

Change-Id: I1eb2daaf26ea248ebeb2bb147a42902a8cf84755
Merge "Make db API respect context show_deleted"
Add SupportStatus class for resources

SupportStatus class has following attributes:
- status (SUPPORTED, DEPRECATED, etc. All allowed support
statuses are defined)
- message (property for providing some information about status)
- version (when resource came into specific support status)

By default support status of each resource is SUPPORTED.

Support status added to Resource class as a static attribute.

Implements bp resource-support-status

Change-Id: Ib3aacdb0f28b09ebeecfc3f13cf22587f8d57f03
Pass the files correctly though the update mechanism

By "files", we mean the TemplateResource templates that get
passed into stack create and update.

The files are critical to the definition of TemplateResources
so we need to have the correct version of them in each stage
of the update.

Within the update there are 3 stacks:
- existing (stack been updated)
- newstack (the goal state)
- previous (a snapshot of the initial stack)

To update TemplateResources we need the existing stack to have access
to the new "files" but the previous stack must contain the old set (or empty).
This way the TemplateResource can get access to the new template and find the
difference to the previous template.

Note: although there are no tests in this patch, a following fully uses
and tests this functionality.

Partial-bug: #1254966
Change-Id: I803a385940759a4eb04df1eccce166be24ee333c
Handle TemplateResouces with the wrong template extension

Change-Id: Ifcd7a5728fcdb61146ad6461697756ea46e9ab96
Fix stack-show on a TemplateResource with outputs

TemplateResource currently tries to re-download the template.
this is not good, esp. if you have a relative path to a local file.
First see if we have a new template, if not look in the db.

Closes-bug: #1252980
Change-Id: If819aab9ed1360744f8e73f0b6409641e2d8114f
Fix error in Trove Instance schema definition

Change-Id: I79d0f0318a161b4666ea149ba0691bd6dfe877f2
Merge "run_test.sh -V --unit doesn't run using virtualenv"
Change ID column of Event table to UUID

If you are using a public Heat you can use the event ID in
'heat event-list' to measure how much activity the service provider
has in their heat installation.

To avoid this, the Id column of the Event table was changed from
autoincremental integer to a uuid.

Added some unit tests in order to ensure that events with integer or
uuid id pass through the API, since we have a migration which will
leave behind integer ids.

Change-Id: Ib3eddb700738cb3667c72977a9a5011209acd6d7
Closes-Bug: #1249159
heat engine changes for abandon-stack

abandon-stack operation is similar to delete-stack, but actual
resources would not be deleted. Only stack and resource data
would be deleted from heat database. And also abandon-stack
operation would return the stack/resources data in json format.

Implements: blueprint abandon-stack
Change-Id: Ibb386255887d4de54e9a3dc95254a7151475cf3a
Add REST endpoint for abandon-stack

Implements: blueprint abandon-stack
Change-Id: Ie6151208a540d44a3235cb13b49ef02caa090090
Call cfn-create-aws-symlinks in boothook.sh

Images which have heat-cfntools installed from rpm or deb
will not have cfn tool links in /opt/aws/bin.

This change runs cfn-create-aws-symlinks during cloud-init
boothook.sh. It should do the following:
* if no cfn tools exist in /opt/aws/bin, symlinks from /usr/bin
  will be created
* if cfn tools exist in /opt/aws/bin, no symlinks are created
* if cfn-create-aws-symlinks doesn't exist, there will be no effect

This is required to use a vanilla Fedora 20 cloud image with heat,
which has heat-cfntools pre-installed.

Change-Id: I5426fdad3031f91b4b9c1f9c9c19ac9cc42cf2dd