libsolace.plugins.OpenTSDBClient module

a plugin for sending metrics to OpenTSDB

libsolace.plugins.OpenTSDBClient.OpenTSDBClient(fn)[source]

Similar to the influxdb client, but for opentsdb.

Example:

    >>> import libsolace.settingsloader as settings
    >>> import libsolace
    >>> metrics_class = libsolace.plugin_registry('OpenTSDBClient', settings=settings)
    >>> metrics = metrics_class(settings=settings)
class libsolace.plugins.OpenTSDBClient.OpenTSDBClient[source]

Similar to the influxdb client, but for opentsdb.

Example:

    >>> import libsolace.settingsloader as settings
    >>> import libsolace
    >>> metrics_class = libsolace.plugin_registry('OpenTSDBClient', settings=settings)
    >>> metrics = metrics_class(settings=settings)
plugin_name = 'OpenTSDBClient'
send(measurement, data, **tags)[source]

Send the metrics to opentsdb

Example:

>>> import libsolace.settingsloader as settings
>>> import libsolace
>>> metrics_class = libsolace.plugin_registry('OpenTSDBClient', settings=settings)
>>> metrics = metrics_class(settings=settings)
>>> metrics.send('somekey', 100, extratag1='tagvalue', extratag2='tagvalue')
Parameters:
  • measurement – the key name
  • data – the value
  • tags
Returns: