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
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
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
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
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
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
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
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
Merge "flake8 F812 list comprehension redefines fix."
Merge "Fix instance creation when a network with no subnet is used"
Merge "Rename functions which should not be run as tests."
Merge "Make autoscale not dependent on loadbalancer impl."
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
Enable H403

Fix the only two places where it triggered alongway.

Change-Id: Ib76e0e072c2d51a9c782f37d5f5df964f2db968f
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
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
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
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
Adds possible topdir to python search path

Change-Id: Ide47656071c6d17482b1e4ec0727ce316033e702
Fixes: bug #1189354
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