Set upload_image policy to control data upload

There was no policy to control data upload.
Up until today, the add_image policy was a all or nothing, from metadata
to the actual data. Now, with the combination of add_image and upload_image
an administrator will have finer control over the whole chain.

Change-Id: I1a7966ffb5c63dd8239a54fe2963b031d9fe1f9a
Closes-bug: #1254521
Add documentation for some API parameters

Add documentation for some parameters which can
be present in glance-api.conf:

* use_user_token
* admin_user
* admin_password
* admin_tenant_name
* auth_url
* auth_region
* auth_strategy

Fix for bug 1256952.

DocImpact

Change-Id: Ia5b731cabaec961f3a4226d30abd3bca9bd87651
Merge "Set upload_image policy to control data upload"
Merge "Add documentation for some API parameters"
Introduce Task Info Table

- move 'input', 'message' and 'result' columns to table 'task_info'
- introduce migration script for the above db changes.
- appropriate tests are included

Co-authored-by: Nikhil Komawar <nikhil.komawar@rackspace.com>

partly implements bp async-glance-workers

Change-Id: I9867d609f4729572b72a44d1f05e353acf6c98d9
Move is_image_sharable to registry api

When using the membership kwarg in is_image_sharable with the sqlalchemy driver,
an AttributeError may be raised since the 'member' variable is not always
defined. This function was copied throughout the db drivers and untested.

This patch adds tests and moves the function to the v1 registry api, where it
was the only place being used. Tests for this function in test_context were
removed as it does not make sense to test this function there and allowed for
the removal of the membership kwarg.

Fixes bug 1247481

Change-Id: Ia77bc0a144831ddcf7e180afdb0842754ff3fcf2
Unittests added for glance/cmd/cache_manage.py

Related to blueprint glance-cmd+unittests

Unittests for all methods, that manage cache added:
* list_cached
* list_queued
* queue_image
* delete_cached_image
* delete_all_cached_images
* delete_queued_image
* delete_all_queued_images

Unittests for several internal methods added:
catch_error; env; create_options; parse_options; lookup_command

Change-Id: Id07bbecdc9877268a514e3a594699364dcc4618f