Class: Datadog::Tracing::Sampling::RateLimiter
- Inherits:
-
Object
- Object
- Datadog::Tracing::Sampling::RateLimiter
- Defined in:
- lib/datadog/tracing/sampling/rate_limiter.rb
Overview
Checks for rate limiting on a resource.
Direct Known Subclasses
Instance Method Summary collapse
-
#allow?(size) ⇒ Boolean
Checks if resource of specified size can be conforms with the current limit.
-
#effective_rate ⇒ Float
The effective rate limiting ratio based on recent calls to ‘allow?`.
Instance Method Details
#allow?(size) ⇒ Boolean
Checks if resource of specified size can be conforms with the current limit.
Implementations of this method are not guaranteed to be side-effect free.
16 |
# File 'lib/datadog/tracing/sampling/rate_limiter.rb', line 16 def allow?(size); end |
#effective_rate ⇒ Float
The effective rate limiting ratio based on recent calls to ‘allow?`.
22 |
# File 'lib/datadog/tracing/sampling/rate_limiter.rb', line 22 def effective_rate; end |