Support DB auto-create suppression.

Adds a new boolean config option, db_auto_create, to allow the
DB auto-creation be suppressed on demand. This defaults to True
for now to maintain the pre-existing behaviour, but should be
changed to False before the Folsom release.

The 'glance-manage db_sync' command will now create the image*
tables if the DB did not previously exist. The db_auto_create
flag is irrelevant in that case.

The @glance.tests.function.runs_sql annotation is now obsolete
as the glance-api/registry services launched by functional tests
must now all run against an on-disk sqlite instance (as opposed
to in-memory, as this makes no sense when the DB tables are
created in advance).

Change-Id: I05fc6b3ca7691dfaf00bc75a0743c921c93b9694
Leave behind sqlite DB for red functional tests.

We leave behind the sqlite DB for failing tests to aid in diagnosis,
as the file size is relatively small and won't interfere with subsequent
tests, as it's in a per-test directory (which is blown-away if the test
is green).

Change-Id: I90be433fc6f02234b1118a547ea0b5524238161d
Merge "Support DB auto-create suppression."
Add connection timeout to glance client.

Adds a timeout option to glance client and bin/glance.
Includes fast running test case to verify the timeout works correctly.

Fixes LP Bug #1002907.

Change-Id: I4a0c4a8ef1862346ec2cd068d9d9e0577cba9b68
Fix paste to correctly deploy v2 API

Corrects a typo where 'apiv1app' should be 'apiv2app'

Change-Id: I4ef29f7539a572ed65422fd548e9718e86161b5f
Merge "Fix paste to correctly deploy v2 API"
Correct format of schema-image.json.

Correct the JSON format of schema-image.json. Fixes issues where
glance-api won't start due to invalid JSON in this file.

Fixes LP Bug #1003470.

Change-Id: Ibacc49f2c45e233bd6ad25b3334e013acaae8339
Adds sql_ config settings to glance-api.conf.

The Glance v2 API makes use of the DB directly. As such
we should include the sql_ configs in the default glance-api.conf
file.

Fixes LP Bug #1003504.

Change-Id: I5e287dafcd65864f56789ae22bab3dcc6b353a47
Remove unused imports in setup.py

Change-Id: Ifb08695a8a9a264a3032ae09524e8b37fa0dd761
Add missing files to tarball

Add a few missing files to generated tarballs.
Fixes bug 1001213.

Change-Id: Ie6ce3069e9e93aeb6be78bd2d90ad4f07ae56b3a
Fail gracefully if paste config file is missing.

If the paste config file can't be found, fail with a RuntimeError
and message instead of a traceback from os.path.abspath.

Change-Id: Id8823dbadab06a0de6bb7c235b70c355812ed55e
Merge "Fail gracefully if paste config file is missing."
Merge "Adds sql_ config settings to glance-api.conf."
Merge "Correct format of schema-image.json."
Lock pep8 to version 0.6.1 in tox.ini

Change-Id: Ib88f57a08bb8ba8bd7970300716d84a2a2e2a411
Lock pep8 at v1.1

Update offending files to pass pep8 v1.1 and lock our deps on this
new version.

Change-Id: I5380f213f8e2f62d75f513c8b4496f78fc692dad
Fix integration of image properties in v2 API

The (de)serialization of images in the v2 API expected a db-like
properties list in some cases, while in others a flat dictionary. This
patch aligns the code by ensuring the properties dictionaries are
normalized before being passed in and out of the controller.

* Expands the images functional test case to cover this integration point
* Cast all images to dictionaries before returning from the controller
* Related to bp api-2

Change-Id: I8b09677f622151330630fc7b0267f0549bb1a458
Merge "Remove unused imports in setup.py"
Add allow_additional_image_properties

Implements bp:api-v2-user-properties

Change-Id: I26378e9f4e8d0f53898f4665bad89922c0b5792a
Merge "Leave behind sqlite DB for red functional tests."