Outlyer Plugin
api for definining native Outlyer Plugins
class Plugin:
"""
The Plugin API.
Users must derive from this class when implementing a custom Plugin
"""
def collect(self) -> Status:
"""Perform collections operations for the provided Target"""
def gauge(self, name: str, labels: Optional[dict]) -> Gauge:
"""Get a Gauge instance for the specified Name/Labels"""
def counter(self, name: str, labels: Optional[dict]) -> Counter:
"""Get a Counter instance for the specified Name/Labels"""
def get(self, key: str, default: any) -> any:
"""Get a Target config property"""
Usage
from outlyer_plugin import Plugin, Status
class MyPlugin(Plugin):
def collect(self):
self.gauge(f'sys.cpu.user.pct').set(55)
return Status.OK
if __name__ == '__main__':
# To run the collection
sys.exit(MyPlugin().run())
Metadata
Release files for outlyer-plugin 0.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| outlyer-plugin-0.0.1.tar.gz | 4.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| outlyer_plugin-0.0.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 9.3 kB
Release files / outlyer-plugin-0.0.1.tar.gz
| Download URL | outlyer-plugin-0.0.1.tar.gz |
|---|---|
| Size | 4.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d2410a932c1a557f3384b8d6e712639541f65e448740c618157b14514989a797
|
|
BLAKE2b-256 checksum How to use checksums |
3af29c3baa12971c30783364f57ea899d9118fb7d496785f060a10b15e5b6306
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/39.2.0 requests-toolbelt/0.8.0 tqdm/4.29.0 CPython/3.7.0
|
Release files / outlyer_plugin-0.0.1-py3-none-any.whl
| Download URL | outlyer_plugin-0.0.1-py3-none-any.whl |
|---|---|
| Size | 5.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
0d79fecf4336de4e65d7d83344264a8f7cb8c584add66cbf4845f5f8bcb43d78
|
|
BLAKE2b-256 checksum How to use checksums |
662bfaa0b060effb0fb81e718acdf98496bd378e3b15a01afd5fdb9cdb405588
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/39.2.0 requests-toolbelt/0.8.0 tqdm/4.29.0 CPython/3.7.0
|