public interface RollupPolicy extends Function<List<com.netflix.spectator.api.Measurement>,List<RollupPolicy.Result>>
| Modifier and Type | Interface and Description |
|---|---|
static class |
RollupPolicy.Result
Result of applying the rollup policy.
|
static class |
RollupPolicy.Rule
Rule for matching a set of measurements and removing specified dimensions.
|
| Modifier and Type | Method and Description |
|---|---|
static RollupPolicy |
fromIdMapper(Map<String,String> commonTags,
Function<com.netflix.spectator.api.Id,com.netflix.spectator.api.Id> idMapper)
Create a new policy that will aggregate ids based on the statistic tag.
|
static RollupPolicy |
fromRules(Map<String,String> commonTags,
List<RollupPolicy.Rule> rules)
Create a new policy based on a list of rules.
|
static RollupPolicy |
noop(Map<String,String> commonTags)
Does nothing, returns the input list without modification.
|
static RollupPolicy noop(Map<String,String> commonTags)
static RollupPolicy fromIdMapper(Map<String,String> commonTags, Function<com.netflix.spectator.api.Id,com.netflix.spectator.api.Id> idMapper)
commonTags - Common tags that are applied to all measurements.idMapper - Map an id to a new identifier that will be used for the resulting aggregate measurement.static RollupPolicy fromRules(Map<String,String> commonTags, List<RollupPolicy.Rule> rules)
commonTags - Set of common tags that are applied to all measurements.rules - List of rules for specifying what dimensions should be removed.