Do not send traceback to clients by default

eventlet.wsgi.server contains a "debug" param which is True by default.
This sends tracebacks to the client on 500 errors, which is not
desirable for security reasons.

Set this to be False by default.

Fixes bug 1192132

Change-Id: Ib54fb79128c6922f7a38339c4256f0e4c81e1665
Fix for unencrypted uris in scrubber queue files

The scrubber can write unencrypted uris in queue files in
certain conditions. This fixes the problem by removing the
lines which write the queue files when exceptions occur.

Test included.

Fixes bug 1180884

Change-Id: If742a84cea1bd1f5abf99fb0e3cbd1e0c1623171
Import sql_connection option before using it.

This change fixes issues that would arise when testing certain files on
their own. Normal test runs were not affected due to serendipity in the
implied import order.

Change-Id: I9a85bf0112a9796482624e860efc2ec620aaf0f2
Don't run store tests without a store!

Store tests reuse a base test case which defines relevant test
functions. However, the base test case should never run independently,
only in a subclass, because it has no store to test.

Somehow, this issue only occurs if you run tox -- --tests
glance/tests/functional/store

Change-Id: I5d8d26ba68d034fb8e94e5408a757d9869825285
Add a bit of description

Fixes Hacking warning:
H701  Empty localization string

Change-Id: I9528fee604f3d2a37286f7b8bf03f0dd94bfc290
Port slow, overly assertive v1 functional tests to integration tests

This patch ports existing v1 api functional tests to a newly added group
of integration tests. The new tests take about 1/8th of the time of the
previous tests, thanks to not forking off api and registry server
processes.

One original functional test is preserved, to ensure that we are still
testing the basic v1 functional wireup.

Related to bp refactoring-better-faster-stronger-functional-tests

Change-Id: Ifcc76b4bf4e484a52558538e5398cad882e48e4c
Do not raise NEW exceptions

Raising NEW exception is bad practice, because we lose TraceBack.
So all places like:

except SomeException as e:
    raise e

should be replaced by

except SomeException:
    raise

If we are doing some other actions before reraising we should
store information about exception then do all actions and then
reraise it. This is caused by eventlet bug. It lost information
about exception if it switch threads.

fixes bug 1191730

Change-Id: I047e355607318bf9fa6208c2b174b7cc394297f0
Merge "Do not send traceback to clients by default"
Merge "Do not raise NEW exceptions"
Merge "Import sql_connection option before using it."
Fixes exposing trace during calling image create API

Now Glance will return trace instead of standard HTTP error
during create image with bad location and nonempty body.
The root cause is nonempty request body will make add image
as synchronous action instead of queuing it. And then, the
image upload will fail due to the bad location. As a result,
user will run into the exception trace instead of friendly
HTTP error.

Based on current design, it's invalid to provide multiple
image sources in one request. So this fix is adding an
explicit check to make sure there is only one image source.

Fixes bug: 1185055

Change-Id: I204aa14fa35e50aeb29b6dc22bbf5bbc66a2fb42
Merge "Don't run store tests without a store!"
Merge "Fix for unencrypted uris in scrubber queue files"
Merge "Port slow, overly assertive v1 functional tests to integration tests"
Merge "Fixes exposing trace during calling image create API"
Removed unusued variables to clean the code.

Change-Id: I96d2f84cab88490f04af98603fba58325fa391fe
Merge "Add a bit of description"