platypush/plugins/graphite/__init__.py
def send(self,
             metric: str,
             value,
             host: Optional[str] = None,
             port: Optional[int] = None,
             timeout: Optional[int] = None,
             tags: Optional[Dict[str, str]] = None,
             prefix: str = '',
             protocol: str = 'tcp'):
        """
        Send data to a Graphite instance.

        :param metric: Metric name.
        :param value: Value to be sent.
        :param host: Graphite host (default: default configured ``host``).
        :param port: Graphite port (default: default configured ``port``).
        :param timeout: Timeout in seconds.
        :param tags: Map of tags for the metric.
        :param prefix: Metric prefix name (default: empty string).
        :param protocol: Communication protocol - possible values: 'tcp', 'udp' (default: 'tcp').
        """
        import graphyte

        host = host or self.host
        port = port or self.port
        tags = tags or {}
        protocol = protocol.lower()

        graphyte.init(host, port=port, prefix=prefix, protocol=protocol, timeout=timeout or self.timeout)
        graphyte.send(metric, value, tags=tags)

        Send data to a Graphite instance.

        :param metric: Metric name.
        :param value: Value to be sent.
        :param host: Graphite host (default: default configured ``host``).
        :param port: Graphite port (default: default configured ``port``).
        :param timeout: Timeout in seconds.
        :param tags: Map of tags for the metric.
        :param prefix: Metric prefix name (default: empty string).
        :param protocol: Communication protocol - possible values: 'tcp', 'udp' (default: 'tcp').
        
Send data to a Graphite instance.
Send data to a Graphite instance .
def send(self,
             metric: str,
             value,
             host: Optional[str] = None,
             port: Optional[int] = None,
             timeout: Optional[int] = None,
             tags: Optional[Dict[str, str]] = None,
             prefix: str = '',
             protocol: str = 'tcp'):
        import graphyte
        host = host or self.host
        port = port or self.port
        tags = tags or {}
        protocol = protocol.lower()
        graphyte.init(host, port=port, prefix=prefix, protocol=protocol, timeout=timeout or self.timeout)
        graphyte.send(metric, value, tags=tags)
def send ( self , metric : str , value , host : Optional [ str ] = None , port : Optional [ int ] = None , timeout : Optional [ int ] = None , tags : Optional [ Dict [ str , str ] ] = None , prefix : str = '' , protocol : str = 'tcp' ) : import graphyte host = host or self . host port = port or self . port tags = tags or { } protocol = protocol . lower ( ) graphyte . init ( host , port = port , prefix = prefix , protocol = protocol , timeout = timeout or self . timeout ) graphyte . send ( metric , value , tags = tags )
Send data to a Graphite instance.
Send data to a Graphite instance .
"""
        Send data to a Graphite instance.

        :param metric: Metric name.
        :param value: Value to be sent.
        :param host: Graphite host (default: default configured ``host``).
        :param port: Graphite port (default: default configured ``port``).
        :param timeout: Timeout in seconds.
        :param tags: Map of tags for the metric.
        :param prefix: Metric prefix name (default: empty string).
        :param protocol: Communication protocol - possible values: 'tcp', 'udp' (default: 'tcp').
        """
self
metric
str
None
value
Value to be sent.
Value to be sent .
host
Optional[str]
Graphite host (default: default configured ``host``).
Graphite host ( default : default configured ` ` host ` ` ) .
port
Optional[int]
Graphite port (default: default configured ``port``).
Graphite port ( default : default configured ` ` port ` ` ) .
timeout
Optional[int]
Timeout in seconds.
Timeout in seconds .
tags
Optional[Dict[str, str]]
Map of tags for the metric.
Map of tags for the metric .
prefix
str
Metric prefix name (default: empty string).
Metric prefix name ( default : empty string ) .
protocol
str
Communication protocol - possible values: 'tcp', 'udp' (default: 'tcp').
Communication protocol - possible values : ' tcp ' ' udp ' ( default : ' tcp ' ) .