flytekit.interfaces.stats.client
| Property |
Type |
Description |
RESERVED_TAG_WORDS |
frozenset |
|
def get_base_stats(
cfg: flytekit.configuration.StatsConfig,
prefix: str,
)
| Parameter |
Type |
Description |
cfg |
flytekit.configuration.StatsConfig |
|
prefix |
str |
|
def get_stats(
cfg: flytekit.configuration.StatsConfig,
prefix: str,
)
| Parameter |
Type |
Description |
cfg |
flytekit.configuration.StatsConfig |
|
prefix |
str |
|
A dummy client for statsd.
class DummyStatsClient(
host = 'localhost',
port = 8125,
prefix = None,
maxudpsize = 512,
ipv6 = False,
)
Create a new client.
| Parameter |
Type |
Description |
host |
|
|
port |
|
|
prefix |
|
|
maxudpsize |
|
|
ipv6 |
|
|
A Proxy object for an underlying statsd client.
Adds a new call, scope(prefix), which returns a new proxy to the same
client which will prefix all calls to underlying methods with the scoped prefix:
new_client = client.get_stats(‘a’)
new_client.incr(‘b’) # Metric name = a.b
This can be nested:
newer_client = new_client.get_stats(‘subsystem’)
newer_client.incr(‘bad’) # Metric name = a.subsystem.bad
class ScopeableStatsProxy(
client,
prefix = None,
)
| Parameter |
Type |
Description |
client |
|
|
prefix |
|
|
| Parameter |
Type |
Description |
name |
|
|
class StatsClientProxy(
client,
prefix = None,
)
| Parameter |
Type |
Description |
client |
|
|
prefix |
|
|
| Parameter |
Type |
Description |
name |
|
|