Skip to main content
Join the official 2020 Python Developers SurveyStart the survey!

SKA SDP Configuration Database

Project description

Configuration Database

This is the frontend module for accessing SKA SDP configuration information. It provides ways for SDP controller and processing components to discover and manipulate the intended state of the system.

At the moment this is implemented on top of etcd, a highly-available database. This library provides primitives for atomic queries and updates to the stored configuration information.

Installation

Install from PyPI:

pip install ska-sdp-config

Basic Usage

Make sure you have a database backend accessible (etcd3 is supported at the moment). Location can be configured using the SDP_CONFIG_HOST and SDP_CONFIG_PORT environment variables. The defaults are 127.0.0.1 and 2379, which should work with a local etcd started without any configuration.

This should give you access to SDP configuration information, for instance try:

import ska_sdp_config

config = ska_sdp_config.Config()

for txn in config.txn():
    for pb_id in txn.list_processing_blocks():
        pb = txn.get_processing_block(pb_id)
        print("{} ({}:{})".format(pb_id, pb.workflow['id'], pb.workflow['version']))

To read a list of currently active processing blocks with their associated workflows.

Command line

This package also comes with a command line utility for easy access to configuration data. For instance run:

sdpcfg list values /pb/

To query all processing blocks.

Project details


Download files

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

Files for ska-sdp-config, version 0.0.11
Filename, size File type Python version Upload date Hashes
Filename, size ska_sdp_config-0.0.11-py3-none-any.whl (22.7 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size ska-sdp-config-0.0.11.tar.gz (19.9 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page