CTS API v3¶
The Cloud Trace Service Class¶
The CTS high-level interface is available through the cts
member of a Connection
object. The
cts
member will only be added if the
otcextensions.sdk.register_otc_extensions(conn)
method is called.
Key Event Operations¶
- class otcextensions.sdk.ctsv3.v3._proxy.Proxy(session, statsd_client=None, statsd_prefix=None, prometheus_counter=None, prometheus_histogram=None, influxdb_config=None, influxdb_client=None, *args, **kwargs)
- create_key_event(**attrs)
Create an event
- update_key_event(**attrs)
Update an event
- delete_key_event(notification)
Delete an event
- Parameters:
notification – The key event to delete a
KeyEvent
- Returns:
None
- key_events(notification_type, **attrs)
Query notification events
:param notification_type The type of notification to query :returns: A generator of key event object of
KeyEvent
Trace Operations¶
- class otcextensions.sdk.ctsv3.v3._proxy.Proxy(session, statsd_client=None, statsd_prefix=None, prometheus_counter=None, prometheus_histogram=None, influxdb_config=None, influxdb_client=None, *args, **kwargs)
- traces(**attrs)
Query traces
- Returns:
A generator of trace object of a
Trace
Tracker Operations¶
- class otcextensions.sdk.ctsv3.v3._proxy.Proxy(session, statsd_client=None, statsd_prefix=None, prometheus_counter=None, prometheus_histogram=None, influxdb_config=None, influxdb_client=None, *args, **kwargs)
- trackers(**attrs)
Query notification events
- Parameters:
attrs (dict) – Optional query parameters to be sent to limit the resources being returned. * tracker_name: Tracker name
- Returns:
A generator of tracker object of a
Tracker
- create_tracker(**attrs)
Create tracker
- delete_tracker(tracker)
Delete a single tracker
- Parameters:
tracker – The tracker to delete a
Tracker
- Returns:
None
- update_tracker(**attrs)
Update a single tracker
- Parameters:
attrs (dict) – Keyword arguments which will be used to overwrite a
Tracker
- Returns:
None
Quota Operations¶
- class otcextensions.sdk.ctsv3.v3._proxy.Proxy(session, statsd_client=None, statsd_prefix=None, prometheus_counter=None, prometheus_histogram=None, influxdb_config=None, influxdb_client=None, *args, **kwargs)
- quotas()
Query quotas
- Returns:
A generator of quota object of a
Quota