aws_xray_sdk.core.sampling.target_poller

Module Contents

log
class TargetPoller(cache, rule_poller, connector)

Bases:object

The poller to report the current statistics of all centralized sampling rules and retrieve the new allocated sampling quota and TTL from X-Ray service.

start(self)
_worker(self)
_do_work(self)
_get_candidates(self, all_rules)

Don’t report a rule statistics if any of the conditions is met: 1. The report time hasn’t come(some rules might have larger report intervals). 2. The rule is never matched.

_get_jitter(self)

A random jitter of up to 0.1 seconds is injected after every run to ensure all poller calls eventually get evenly distributed over the polling interval window.