Rewrite get_secgroup_uuids to avoid resource_by_refid

get_secgroup_uuids has changed in the following ways:
* No longer attempts to find a security group name via
  a resource_by_refid lookup. resource_by_refid only exists
  as a workaround for AWS compatibility resource which are
  not backed by an API. Usage of resource_by_refid should be
  avoided in native resources if at all possible.
* If the security group looks like a UUID, assume it is
  a UUID for a security group that exists
* Call client.list_security_groups only once, and only if
  there is a non-uuid security group specified
* Do not attempt to reduce duplicate security groups to a unique
  list. If that is important for resources it can be done in
  validation.
* Raise PhysicalResourceNotFound if name maps to no group
* Raise PhysicalResourceNameAmbiguity if name maps to more than one
  group

Change-Id: I106adc15a7882192884d37c0806947470d139434
Closes-Bug: #1250286
Use get_secgroup_uuids in Instance

Instance._get_security_groups_id serves the same
purpose as neutron.get_secgroup_uuids. This change switches
Instance to using get_secgroup_uuids instead.

Updating the test has the side-effect on getting full test
coverage on get_secgroup_uuids, albeit indirectly.

Change-Id: I8cdc51692fd8d96e68c6c947891c9708f77d54c3
Related-Bug: #1250286
Managed Cloud compatibility for Cloud Servers

Make the Cloud Servers resource aware of the Managed Cloud automation.
The Cloud Servers resource should wait for the Managed Cloud automation
to complete before proceeding with the server configuration.

Blueprint managed-cloud
Change-Id: Iea331f1b275026d6189012528d376e01c986b0cb
Move resource doc generation to doc/source/ext

This is similar to other projects, and removes this
code from the withering gaze of coverage reports.

Change-Id: Ie0acb2a203f2e69a7d84aba3915a8499ab51ecb6
Fix some direct imports from sqlalchemy

Directly import sqlalchemy might result in some inconsistent
behaviors. It would bypass the db_backend configuration.

Change-Id: Ic07c5d9f4898add6629a296ee1dff22be0e75262
Implement Tags for S3 bucket

Use the metadata to hold the tags.

Change-Id: I52d8bb9429a90529431622c72ff2484e6c38c58e
Add support for limiting and sorting stacks

This adds support to the stacks index call for limit, sort_keys,
sort_dir, and marker query parameters, allowing users of the API to
retrieve a subset of stacks.

With this commit, stacks are also sorted by created_at DESC by default.

blueprint pagination

Change-Id: Ib20cfae183475ff42deda82168b8b9c8d043ecd0
Add links section to the stacks index response

Add a `links` section to the stacks index response that will contain
pagination links for the collection - this commit includes adding a
`next` link to the section.

blueprint pagination
Change-Id: I76451a101e7c417a485da78dd7fb19229d91861d
Merge "Move resource doc generation to doc/source/ext"
Merge "Rewrite get_secgroup_uuids to avoid resource_by_refid"
Merge "Managed Cloud compatibility for Cloud Servers"
Add _() to fix i18N compliance (part 1)

In heat, almost 200 log message and at least 30 exception
message are not processed by _(), and will not been translated.
We should use '_("STRING ...")' to enable i18n support.

I will split to two parts for review easier because the files
lost of _() are too much.

Closes-Bug: #1249217

Change-Id: I2c86dc7770a7f6f107ba16711b9cba363ef9b906
Merge "Use get_secgroup_uuids in Instance"
Merge "Implement Tags for S3 bucket"
Merge "Fix some direct imports from sqlalchemy"
Merge "Add support for limiting and sorting stacks"
Merge "Add links section to the stacks index response"
Get pool members from DB API

When the Load Balancer members are created as a result of autoscaling
groups calling _lb_update, the reference to the current members is
stored in the database and not in the template.  Treat ResourceData
mappings as canonical.

Closes-Bug: #1248218
Change-Id: Iaf8097eff6ad5ae0809d56604699dca2b08db3f4
Allow nova metadata to be updated

Note this is metadata not Metadata (confusing, I know).

This does not need to be run in a task as the server does not
change state for metadata changes.

Change-Id: If5f9ee89984fab388c0c9d839fbe23a59c68046b
Closes-bug: #1250638
Make instance Tags updatable

Note: I don't think that there is an issue with autoscaling tags
as autoscaling drives the instance via the properties and it doesn't
update intances anyways, it only creates/destroys instances.

Change-Id: I3cea4180f22690ea226273cc96132db6ae3dde12
Closes-bug: #1240885