PersistentSamplingConfiguration
A SamplingConfiguration that remembers when its measure was last collected.
The probe updates lastTime and the value is saved with the deployment, so sampling can resume from that point after an app restart. Extend it for probes that collect data since the last sample, like health data.
- Inheritance
-
- Object
- Serializable
- SamplingConfiguration
- PersistentSamplingConfiguration
- Implementers
- Annotations
-
- @JsonSerializable(includeIfNull: false, explicitToJson: true)
Constructors
PersistentSamplingConfiguration.fromJson
PersistentSamplingConfiguration
Properties
fromJsonFunction
The function which can convert a JSON string to an object of this type.
lastTime
getter/setter pair
When this measure was last collected, or null if never.
Set by the Probe; saved at most once per second.
Methods
toJson
Return a JSON encoding of this object.