Fix blocking test for nova notifier

Mock out the method of the conductor API that causes
nova to try to use the message bus to communicate
with the remote daemon. There is nothing listening
in the CI environment, so the instance_update call
hangs the tests.

Change-Id: Id95ee0d3f45ef38adadcf94981f97ab12f60f6ad
Signed-off-by: Doug Hellmann <doug.hellmann@dreamhost.com>
Lower the minimum required version of anyjson

Nova uses anyjson 0.2.4, so reduce our minimum required
version to avoid installation conflicts.

Change-Id: I4458117a9e4968afb6b7b7e6573d77dadc36cf5b
Signed-off-by: Doug Hellmann <doug.hellmann@dreamhost.com>
Fixes to enable the jenkins doc job to work

Some of our documentation dependencies were not listed in
test-requires, so the venv environment in tox needs to be
updated to include them.

Then the build_sphinx command looks for configuration settings
in setup.cfg, so those need to be added.

When Sphinx runs in this way, it ends up creating
RST files for every module it finds in the source tree
so it can document the internal APIs. Those generated files
can be ignored by git.

Change-Id: I21b5f9c6c4d4201893bb3bf87f0b61a053b968f5
Signed-off-by: Doug Hellmann <doug.hellmann@dreamhost.com>
Merge "Fixes to enable the jenkins doc job to work"
add migration migrate.cfg file to the python package

Fixes bug 1084595

Change-Id: Ief0789a15e6433badfa5696a876d2f486de5075b
Merge "add migration migrate.cfg file to the python package"
Make Impl of mongodb and sqlalchemy consistent

SqlAlchemy connection inherits from base.Connection, which doesn't have session
parameter in its function get_resources(). And session of get_resources() in
SqlAlchemy is not used and it can be got from self.session. So remove it to make
them consistent.

Change-Id: I85d5094d53af3de40645fa828d73d1dbc2677f0b
Signed-off-by: Shane Wang <shane.wang@intel.com>
Implement object store metering

 Implements these pollsters for swift :
  - storage.objects (per-tenant number of objects)
  - storage.objects.size (per-tenant total size of stored objects)
  - storage.objects.containers (per-tenant number of containers)

Implements: blueprint pollster-swift
Fixes: bug #1004450
Change-Id: Ie27abd0b5803043f06899f14b394f2a7ab691bca
Merge "Make Impl of mongodb and sqlalchemy consistent"
Fix sqlalchemy for show_data and v1 web api

When sqlalchemy (e.g. mysql) is used for ceilometer, show_data.py and web api do
not work because some attributes and keys are different, such as meter/meters,
the patch is fix them and make both can work.

Change-Id: I4b827c3e6664213f1401b183ccbc3a1aaae872aa
Signed-off-by: Shane Wang <shane.wang@intel.com>
Implement /meters to make discovery "nicer" from the client

The point of this api is to make discovery (esp. from a casual user)
easier. So you don't really want to dump all the raw samples out
just to see what is there. So instead "ceilometer meter-list"
will GET /v1/meters (or /{proj|user|source}/{id}/meters) and
this will just return a description (name, type, resource, user, etc)
of the available meters, not each sample point. After this you will probably
go and look at the samples that you are actually interested in.

It is a kind of dynamic version of doc/source/measurements.rst

Change-Id: I58f2757874ab151632b6d87043d6327104c5b65c
Add test storage driver

Create a "test" storage driver to be used by the
API test code.

blueprint api-server-pecan-wsme

Change-Id: I99c7c82afa17ec5a9f36fd20d47b16011e64ffa9
Signed-off-by: Doug Hellmann <doug.hellmann@dreamhost.com>
Move v1 API files into a subdirectory

Move all of the files for the v1 API together into a
single directory to make room for the v2 files.

blueprint api-server-pecan-wsme

Change-Id: Ic794581c677a0277924459ad8a34fd7daf2bc365
Signed-off-by: Doug Hellmann <doug.hellmann@dreamhost.com>
Implement V2 API with Pecan and WSME

This changeset reimplements the API
using Pecan and WSME instead of Flask.

Pecan uses "object dispatch" instead of
declared routes. The controller classes
are chained together to implement the
API.  Most of what we have are simple
REST lookups, but a few cases required
custom methods.

WSME is used to define types of inputs
and outputs for each controller method.
The WSME layer handles serizlization and
deserialization in several formats. In
our case, only JSON and XML are
configured.

There are a few small changes to the
return types in the API, as well as to
error handling. Now all errors are
returned as JSON messages made up of a
mapping containing the key
'error_message' and the text of the
error. This will later be enhanced to
include XML support for XML requests.

This change also moves the script for
starting the V1 API to a new name and
replaces it with a script that starts
the V2 API. There is an open
bug/blueprint to fix that so both
versions of the API are loaded.

blueprint api-server-pecan-wsme

Signed-off-by: Doug Hellmann <doug.hellmann@dreamhost.com>
Change-Id: I1b99a16de68f902370a8999eca073c56f9f14865
Start updating documentation for V2 API

Move the web API documentation into the 'webapi'
subdirectory to avoid conflicts with the auto-generated
'api' directory contents. Create a v2 doc file
as a placeholder until the automatic documentation
features of WSME are more complete.

blueprint api-server-pecan-wsme

Change-Id: Ide11ad0b4cebb29318b8bb977bc5165334e22a2c
Signed-off-by: Doug Hellmann <doug.hellmann@dreamhost.com>
Remove debug print in V2 API

Remove the print statement in v2.py.

Change-Id: Id19d2424f382f0ae797af93c780bd849c67f9c4d
Signed-off-by: Doug Hellmann <doug.hellmann@dreamhost.com>
Add sql db option to devstack for ceilometer

Ceilometer uses mongodb as the default storage.
This is one of the patches to support sql db option in devstack for
ceilometer, so users can easily choose and set up sql db environment
for ceilometer with 'stack.sh' by explicitly specifying the following
statement in localrc:

   use_database mysql

where mysql is taken as an example.

If users remove the above statement, mongodb is used and set up
by default.

This patch is for devstack to call dbsync to create ceilometer tables.

Change-Id: Idc9bffd0f389fa9760946b412c39210f60042d90
Signed-off-by: Shane Wang <shane.wang@intel.com>
Update documentation URL

This now points to docs.openstack.org

This fixes bug #1086652

Change-Id: Ic9cb1a7ebeb0bba062a427e8583e6a531af8039c
Signed-off-by: Julien Danjou <julien@danjou.info>
Merge "Update documentation URL"