Skip to main content

Client to the Orlo deployment _data capture API

Project description

# orloclient

Python client for the [Orlo](https://github.com/eBayClassifiedsGroup/orlo) server.

# Installation
```
pip install orloclient
```

# Usage

With an Orlo server running on localhost:5000:
```python
vagrant@debian-jessie:/vagrant$ ipython
Python 2.7.9 (default, Mar 1 2015, 12:57:24)
Type "copyright", "credits" or "license" for more information.

IPython 4.0.1 -- An enhanced Interactive Python.
? -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help -> Python's own help system.
object? -> Details about 'object', use 'object??' for extra details.

In [1]: import orloclient, json

In [2]: client = orloclient.OrloClient(uri='http://localhost:5000')

In [3]: release = client.create_release(user='alex', platforms=['alexdev'])

In [4]: package = client.create_package(release, name='package-one', version='1.0.0')

In [5]: client.package_start(package)
Out[5]: True

In [6]: client.package_stop(package)
Out[6]: True

In [7]: client.release_stop(release)
Out[7]: True

In [8]: doc = client.get_release_json(release.id)

In [9]: print(json.dumps(doc, indent=2))
{
"releases": [
{
"platforms": [
"alexdev"
],
"ftime": "2016-03-03T16:56:03Z",
"stime": "2016-03-03T16:55:05Z",
"team": null,
"duration": 57,
"references": [],
"packages": [
{
"status": "SUCCESSFUL",
"rollback": false,
"name": "package-one",
"version": "1.0.0",
"ftime": "2016-03-03T16:55:56Z",
"stime": "2016-03-03T16:55:52Z",
"duration": 4,
"diff_url": null,
"id": "9877cd69-1196-42dc-8d6c-0b7c95e11a5d"
}
],
"id": "700ff271-f705-4bfb-8582-b74633759feb",
"user": "alex"
}
]
}
```

# Tests

There are two test suites, test_orloclient and test_integration. The former tests the orlo client functions while mocking the requests library, courtesy of [HTTPretty](https://github.com/gabrielfalcao/HTTPretty), while the integration tests run an actual Orlo server to test against.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

orloclient-0.2.0rc2.tar.gz (16.6 kB view details)

Uploaded Source

Built Distributions

orloclient-0.2.0rc2-py2.7.egg (33.9 kB view details)

Uploaded Source

orloclient-0.2.0rc2-py2-none-any.whl (26.4 kB view details)

Uploaded Python 2

File details

Details for the file orloclient-0.2.0rc2.tar.gz.

File metadata

File hashes

Hashes for orloclient-0.2.0rc2.tar.gz
Algorithm Hash digest
SHA256 278b1a19754752af2dbe6d9f613a86bdbcb3d0f770d03f2eb74423bee7aee8df
MD5 08af955a2d580387b4f669023b2700b1
BLAKE2b-256 54ec5b287a139a5dd796dc714d7df78e9fffe25e8beb18789387ea4a01ab5624

See more details on using hashes here.

File details

Details for the file orloclient-0.2.0rc2.macosx-10.11-x86_64.tar.gz.

File metadata

File hashes

Hashes for orloclient-0.2.0rc2.macosx-10.11-x86_64.tar.gz
Algorithm Hash digest
SHA256 49bebf50379369325fdeef3bf0d32ca2d415dd9b37096780bb09b593f46afa4a
MD5 9de98ebede5ffe01f90bd09a62ed5529
BLAKE2b-256 9c39977a3fa14feb72142260630880d40d792a35df6dcd073f15745fd456c50f

See more details on using hashes here.

File details

Details for the file orloclient-0.2.0rc2-py2.7.egg.

File metadata

File hashes

Hashes for orloclient-0.2.0rc2-py2.7.egg
Algorithm Hash digest
SHA256 b7130aa56393d501559b22b4d76139f6b645196d69130ff4e3acc3262fdacd56
MD5 ed5f381dc9815b9504b87baa93f9e2cf
BLAKE2b-256 0acfe036ecde1a309d341e04ac8341134cdab8a369240f934738c86667ede961

See more details on using hashes here.

File details

Details for the file orloclient-0.2.0rc2-py2-none-any.whl.

File metadata

File hashes

Hashes for orloclient-0.2.0rc2-py2-none-any.whl
Algorithm Hash digest
SHA256 2e2cac8593194c71c39fe9cc7f66f8db9bd5eb1752635eb6e623c1fa709922e1
MD5 bbb4eb1fec0fa9d9bb6983cce0e48472
BLAKE2b-256 08808752aa937965c7aa6e914ea4fc4668914d04f6b1d1c39695dbe328f07f67

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page