Skip to main content

OpenStack Observability Client

Project description

python-observabilityclient

observabilityclient is an OpenStackClient (OSC) plugin implementation that implements commands for management of Prometheus.

Development

Install your OpenStack environment and patch your openstack client application using python.

# if using standalone, the following commands come after 'sudo dnf install -y python3-tripleoclient'

su - stack

# clone and install observability client plugin
git clone https://opendev.org/openstack/python-observabilityclient.git
cd python-observabilityclient
sudo python setup.py install --prefix=/usr

Usage

Use openstack metric query somequery to query for metrics in prometheus.

To use the python api do the following:

from observabilityclient import client

c = client.Client(
            '1', keystone_client.get_session(conf),
            adapter_options={
                'interface': conf.service_credentials.interface,
                'region_name': conf.service_credentials.region_name})
c.query.query("somequery")

List of commands

openstack metric list - lists all metrics openstack metric show - shows current values of a metric openstack metric query - queries prometheus and outputs the result openstack metric delete - deletes some metrics openstack metric snapshot - takes a snapshot of the current data openstack metric clean-tombstones - cleans the tsdb tombstones

List of functions provided by the python library

c.query.list - lists all metrics c.query.show - shows current values of a metric c.query.query - queries prometheus and outputs the result c.query.delete - deletes some metrics c.query.snapshot - takes a snapshot of the current data c.query.clean-tombstones - cleans the tsdb tombstones

Project details


Download files

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

Source Distribution

python_observabilityclient-1.2.0.tar.gz (36.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

python_observabilityclient-1.2.0-py3-none-any.whl (38.4 kB view details)

Uploaded Python 3

File details

Details for the file python_observabilityclient-1.2.0.tar.gz.

File metadata

File hashes

Hashes for python_observabilityclient-1.2.0.tar.gz
Algorithm Hash digest
SHA256 a486ce0fc9e1721e343907b05a5afe88b6afb4c187b5ed5b498f77178dfe7982
MD5 cd30e35ef5de0af353a7ade199ffd38f
BLAKE2b-256 698e90a87c435d9386ab4807660771f494f8af2f5d70055fdcfc1acb2cb12364

See more details on using hashes here.

File details

Details for the file python_observabilityclient-1.2.0-py3-none-any.whl.

File metadata

File hashes

Hashes for python_observabilityclient-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e5ed18fe1836e59e7b72f10f3037790ae690d796b59070d6753bd277978259b9
MD5 669e79307fa02bce060eb715e88319d4
BLAKE2b-256 509f86847909a3d25a4bd7e007a7caf9818270b0b2f0d6769bc620bce7cd1174

See more details on using hashes here.

Supported by

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