Raise Forbidden exception in image_get

The simple db driver now raises 'exception.Forbidden' when a caller
tries to access an image that is not owned by the provided context.
The list of images returned by image_get_all will also be filtered
to match what the sqlalchemy driver is expected to return.

Related to bp glance-simple-db-parity.

Change-Id: Idb2b85252d5ad33194d3bd8b5d8a9bc368968bd0
Log level for BaseContextMiddleware should be warn

The current log level is error for BaseContextMiddleware.
It is toned down to warn in this patch.

Fixes bug 1043374

Change-Id: I468183b374f06b0afad3d559fdb2c09ac0663105
Tidy up API docs

* Add bit about images api vs glance
* Explain how to send auth token
* Prepend '/v1' to example URIs

Related to bp glance-folsom-docs-cleanup

Change-Id: I2c3b568e463f62033268573f50f2d8a74d053965
Remove repeated image-sharing docs

* Drop image sharing blurb from authentication docs.
* Link to authentication page from api page

Related to bp glance-folsom-docs-cleanup

Change-Id: Idac46a78f79fac0c673f6a9b91c1f44df7b705b4
Add link to notifications docs on index

Related to bp glance-folsom-docs-cleanup

Change-Id: Ib0c65fe2bf724199e13107325175541be85bfb29
Drop architecture doc page

Related to bp glance-folsom-docs-cleanup

Change-Id: If4d187e5c96e337f0df0134a101ad1bac061dc80
Tweak doc page titles

Related to bp glance-folsom-docs-cleanup

Change-Id: Ifc4d8371c0752997258e19e7b149ae88ec3413b0
Move authtoken config out of paste

Since we can now configure Keystone's auth_token middleware using
our own config files, we should ship our example config to show
how this is done. This moves the auth_* variables out of
glance-api-paste.ini and glance-registry-paste.ini into
glance-api.conf and glance-registry.conf.

Fixes bug 1043490

Change-Id: Ibdaf8b2ef0f55e5e892fbd1b994dceb323f07c7b
Adds notifications for images v2

The v2 API didnt generate any notifications. It should
send same as those that v1 API has

Fixes bug 1038552

Change-Id: Ieab82937822ad907493d4b538fd75e571416bf16
Merge "Raise Forbidden exception in image_get"
Catch pruner exception when no images are cached

This handles a situation where the pruner would raise an exception when
the image_cache_max_size was set lower than the size of the last image.

Fixes bug 1039854

Change-Id: I4a6c164e9f821f1250314974f829f058fbd02863
Merge "Move authtoken config out of paste"
Merge "Tidy up API docs"
Merge "Remove repeated image-sharing docs"
Merge "Add link to notifications docs on index"
Merge "Drop architecture doc page"
Merge "Tweak doc page titles"
Add test for nonexistent image in db layer

Related to bp glance-simple-db-parity.

Change-Id: I1fcfa80089937e9dec9d637f2227561febb43183
Expand image_create db test

Ensure the test that checks for default values when calling
image_create is expecting the right things. The simple db driver
needed some love to get it to pass the thicker test.

Related to bp glance-simple-db-parity

Change-Id: I80f0ee55ff5ec18e544b91bed218e8c6e3b06a84
Raise Duplicate on image_create with duplicate id

The simple db would allow a user to create new images using IDs
that belonged to existing images. This patch corrects that behavior
and adds a test.

Related to bp glance-simple-db-parity.

Change-Id: I42a036f81e61413e789d87100f58b45b8cc75d38