Ihar Hrachyshka 2621c93e15 Sync jsonutils (and dependencies) from oslo-incubator
The sync includes change that drastically enhances performance on Python
2.6 with fresh simplejson library installed.

The sync adds a new 'strutils' module that is now used in jsonutils.

Changes:

jsonutils
---------
0d7296f Add kwargs to jsonutils.load(s) functions
18f2bc1 Enforce unicode json output for jsonutils.load[s]()
9e5a393 jsonutils.load() accepts file pointer, not string
a6b2aec On Python <= 2.6, use simplejson if available
e3a1d9c Use six.moves.xmlrpc_client instead of xmlrpclib
3a31bba Python3 support for xmlrpclib
e6494c2 Use six.iteritems to make dict work on Python2/3
12bcdb7 Remove vim header
3d7504b Ensure that Message objects will be sent via RPC in unicode format

gettextutils
------------
de4adbc pep8: fixed multiple violations
9912e5d Add API for creating translation functions
6cc96d0 Fix test_gettextutils on Python 3
fd33d1e Fix gettextutil.Message handling of deep copy failures
047b2e4 Change lazy translation to retain complete dict
6d55e26 Add support for translating log levels separately
afdbc0a Fix E501 in individual openstack projects
9d529dd Make Message keep string interpolation args
ec6d900 Add support for locales missing from babel
221c37d Allow the Message class to have non-English default locales
0e1af5b Implementation of translation log handler
8b2b0b7 Use hacking import_exceptions for gettextutils._
2cfc1a7 Translation Message improvements
45658e2 Fix violations of H302:import only modules
12bcdb7 Remove vim header
3970d46 Fix typos in oslo
88db9c8 When translating if no locale is given use default locale
04c1b5a Type check for Message param to avoid AttributeError
89369c3 gettextutils: port to Python 3
6d49bca Translate all substitution elements of a Message object

importutils
-----------
1173e46 Remove ValueError when accessing sys.modules
885828a Deleted duplicated method in cliutils.
12bcdb7 Remove vim header

strutils
--------
8a0f567 Remove str() from LOG.* and exceptions
fd18c28 Fix safe_encode(): return bytes on Python 3
302c7c8 strutils: Allow safe_{encode,decode} to take bytes as input
bec3a5e Implements SI/IEC unit system conversion to bytes
e53fe85 strutils bool_from_string, allow specified default
8b2b0b7 Use hacking import_exceptions for gettextutils._
84d461e Fix a bug in safe_encode where it returns a bytes object in py3
12bcdb7 Remove vim header
3970d46 Fix typos in oslo
1a2df89 Enable H302 hacking check
67bd769 python3: Fix traceback while running python3.
b0c51ec Refactors to_bytes
472d8ed Add slugify to strutils
7119e29 Enable hacking H404 test.
4246ce0 Added common code into fileutils and strutils.
536c39e Add 't', 'y', and `strict` to `bool_from_string`
d9b0719 Handle ints passed to `boolean_from_string`
8c964a2 Do not import openstack.common.log in strutils
e700d92 Replaces standard logging with common logging
547ab34 Fix Copyright Headers - Rename LLC to Foundation
bd5dad9 Decode / Encode string utils for openstack
7cf239c Rename utils.py to strutils.py

timeutils
---------
250cd88 Fixed a new pep8 error and a small typo
71208fe Fix spelling errors in comments
7013471 Fix typo in parameter documentation (timeutils)
ae931a9 Avoid TypeError in is_older_than, is_newer_than
12bcdb7 Remove vim header
f3b5f17 Add helper method total_seconds in timeutils.py
53ebd30 python3: use six.text_types for unicode()
3bc6f79 Fix timeutils.set_override_time not defaulting to current wall time
af76064 Optimize timeutils.utcnow_ts()

Change-Id: Ib3dc0b713ed90396919feba018772243b3b9c90f
Closes-Bug: 1314129
2014-06-27 12:32:51 -07:00
2014-02-01 01:19:58 +00:00
2014-03-26 15:50:05 +04:00
2014-05-28 17:13:01 -07:00
2014-03-10 10:16:03 +01:00
2013-06-24 14:11:15 -07:00
2013-06-14 18:25:42 -04:00
2013-06-24 14:11:15 -07:00
2014-03-19 15:06:23 +01:00
2013-04-29 18:01:12 -04:00
2013-06-25 10:41:57 +02:00
2014-04-02 11:06:09 +02:00
2014-05-01 13:51:51 +00:00
2014-06-08 11:16:59 +00:00

Trove

Trove is Database as a Service for Open Stack.

Usage for integration testing

If you'd like to start up a fake Trove API daemon for integration testing with your own tool, run:

$ ./tools/start-fake-mode.sh

Stop the server with:

$ ./tools/stop-fake-mode.sh

Tests

To run all tests and PEP8, run tox, like so:

$ tox

To run just the tests for Python 2.7, run:

$ tox -epy27

To run just PEP8, run:

$ tox -epep8

To generate a coverage report,run:

$ tox -ecover

(note: on some boxes, the results may not be accurate unless you run it twice)

Docs

This repository contains the following OpenStack manual:

  • Database Services API Reference

Prerequisites

Apache Maven must be installed to build the documentation.

To install Maven 3 for Ubuntu 12.04 and later, and Debian wheezy and later:

apt-get install maven

On Fedora 15 and later:

yum install maven3

Building

The manuals are in the apidocs directory.

To build a specific guide, look for a pom.xml file within a subdirectory, then run the mvn command in that directory. For example:

cd apidocs
mvn clean generate-sources

The generated PDF documentation file is:

apidocs/target/docbkx/webhelp/cdb-devguide/cdb-devguide-reviewer.pdf

The root of the generated HTML documentation is:

apidocs/target/docbkx/webhelp/cdb-devguide/content/index.html

Testing of changes and building of the manual

Install the python tox package and run tox from the top-level directory to use the same tests that are done as part of our Jenkins gating jobs.

If you like to run individual tests, run:

  • tox -e checkniceness - to run the niceness tests
  • tox -e checksyntax - to run syntax checks
  • tox -e checkdeletions - to check that no deleted files are referenced
  • tox -e checkbuild - to actually build the manual

tox will use the openstack-doc-tools package for execution of these tests. openstack-doc-tools has a requirement on maven for the build check.

Contributing

Our community welcomes all people interested in open source cloud computing, and encourages you to join the OpenStack Foundation.

The best way to get involved with the community is to talk with others online or at a meetup and offer contributions through our processes, the OpenStack wiki, blogs, or on IRC at #openstack on irc.freenode.net.

We welcome all types of contributions, from blueprint designs to documentation to testing to deployment scripts.

If you would like to contribute to the documents, please see the Documentation HowTo.

Bugs

Bugs should be filed on Launchpad, not GitHub:

https://bugs.launchpad.net/openstack-api-site/

Installing

Refer to http://docs.openstack.org to see where these documents are published and to learn more about the OpenStack project.

Description
OpenStack Database As A Service (Trove)
Readme 114 MiB
Languages
Python 95%
Shell 4.9%