public interface DynamicId
Id
interface that allows the list of tag names attached
to the Id to be declared in advance of the use of the metric. This can be used to
provide a default value for a tag or to use a TagFactory implementation that uses
context available in the execution environment to compute the value of the tag.Modifier and Type | Method and Description |
---|---|
String |
name()
Description of the measurement that is being collected.
|
Id |
resolveToId()
Invokes each of the associated tag factories to produce a Id based on the
runtime context available when this method is invoked.
|
Iterable<Tag> |
tags()
Other dimensions that can be used to classify the measurement.
|
DynamicId |
withTag(String k,
String v)
New id with an additional tag value.
|
DynamicId |
withTag(Tag t)
New id with an additional tag value.
|
DynamicId |
withTagFactories(Iterable<TagFactory> factories)
New id with additional tag factories.
|
DynamicId |
withTagFactory(TagFactory factory)
New id with an additional tag factory.
|
DynamicId |
withTags(Iterable<Tag> tags)
New id with additional tag values.
|
DynamicId |
withTags(Map<String,String> tags)
New id with additional tag values.
|
String name()
DynamicId withTagFactory(TagFactory factory)
factory
- the factory to use to generate the values for the tagDynamicId withTagFactories(Iterable<TagFactory> factories)
factories
- a collection of factories for producing values for the tagsId resolveToId()