Wrap image data in iterator

This is establishing the API for a future optimization. We want to
be able to offer true socket-level caching, but can't do that with
httplib2 right now. For now, we will just fake the optimization
by returning an iterator over the image body, which happens to already
be fully loaded into a string.

Change-Id: I2d36e3cdd45b26d7c7c27ba050bf6a4b5765df6c
Establish the supported importable interface

* Consumers of this client should not depend on being able to import
  any module other than glanceclient and glanceclient
* The only attributs of the glanceclient module are Client
  and __version__
* The attributes of the glanceclient.exc modules have yet to be
  locked down
* glanceclient.common.exceptions was replaced with a placeholder
  module until consumers of it are updated

Change-Id: Iea9648cd06906d65764987c1f2ee5a88ebeee748
Rewrite link parsing for finding v2 schemas

What we called 'links' are no longer returned in a container of
objects, they are top-level entity attribtues. This fixes the
parsing of the entities to look in the correct place when trying
to locate a specific schema.

Add a helper for printing to stderr and exiting with a non-zero
exit code.

Map 'name' to 'Attribute' when explaining a schema.

Related to bp glance-client-v2

Change-Id: Ib98e912a7af0bb570b4fd738733edd9b837d1a05
Add support for viewing a single image through v2

* Add image-create command
* Add tests for Image model, Controller.get, and Controller.list
* Related to bp glance-client-v2

Change-Id: Ib98e912a7af0bb570b4fd738733edd9b837d1a06
Replace static v2 Image model with warlock model

* Add warlock v0.1.0 as a dependency
* Generate a pythonic, self-validating Image model using warlock
* Add raw method to Schema model
* Related to bp glance-client-v2

Change-Id: Ib98e912a7af0bb570b4fd738733edd9b837d1a04
Convert v2 images list method to generator

We will want this to be a generator as soon as we implement
pagination. Let's establish the interface now.

Related to bp glance-client-v2

Change-Id: Ib98e912a7af0bb570b4fd738733edd9b837d1a07
Align print_dict to the left

Change-Id: Ib98e912a7af0bb570b4fd738733edd9b837d1a10
Prevent links from being printed in v2 CLI

Nobody wants to see links in a human interface. This prevents the
file, access, self and schema links from being printed when calling
image-show or explain.

Related to bp glance-client-v2

Change-Id: Ib98e912a7af0bb570b4fd738733edd9b837d1a11
Add pagination to v2 image-list

* Use a recursive generator function to iterate over the image
  container. The presence of next links are indicators to
  continue pagination while their value drives the location of
  the next page.
* A user can pass in --page-size on the command line, or page_size
  when using the controller directly, to control how many images
  are requested with each subsequent paginated request. Default page
  size is 20.
* Add a flag (strict_url_check) for the FakeAPI class to control
  whether it chops off query params when trying to match a request
  to a fixture.
* Related to bp glance-client-v2.

Change-Id: Ib98e912a7af0bb570b4fd738733edd9b837d1a12
Relax prettytable dependency to v0.6.X from v0.6

Change-Id: Ide7247ba444b60179d9c76c43dfaa43c025b69c9
Update README usage examples

* Update the python snippet to reflect reality
* Fix broken links
* Remove superfluous text

Change-Id: I4b7e9aae35cc49e5fa89ca33d2399784c2afd029
Merge changes Ib98e912a,Ib98e912a,Ib98e912a,Ib98e912a,Ib98e912a

* changes:
  Align print_dict to the left
  Convert v2 images list method to generator
  Replace static v2 Image model with warlock model
  Add support for viewing a single image through v2
  Rewrite link parsing for finding v2 schemas
Merge changes Ib98e912a,Ib98e912a

* changes:
  Add pagination to v2 image-list
  Prevent links from being printed in v2 CLI
Merge "Wrap image data in iterator"
Add pagination to v1 image-list

* Use recursive generator function to make subsequent requests
  to the v1 detailed images resource
* 'limit' continues to act as the absolute limit of images to return
  from a list call
* 'page_size' indicates how many images to ask for in each subsequent
  pagination request
* Expose --page-size through the cli
* Convert v1 images tests to use strict url comparison
* Drop strict_url_check from FakeAPI kwargs - now the functionality
  is always active and tests must directly match fixture urls
* Fix bug 1024614

Change-Id: Ifa7874d88360e03b5c8aa95bfb9d5e6dc6dc927e
Merge "Relax prettytable dependency to v0.6.X from v0.6"
Clarify usage of --insecure flag

Change-Id: If19a7aab92350fb68e447a0ffe8a97e079d762e4
Replace httplib2 with httplib as http driver

* This allows us to send truly chunked responses to users
* Handle bad connection url schemes with a new InvalidEndpoint exception
* Fixes bug 1023240

Change-Id: I34500987f51d4e0c6e1f89ecf93853de3fcbb1c3