Commit d1e5588 1 parent 7350e1a commit d1e5588 Copy full SHA for d1e5588
File tree 4 files changed +24
-18
lines changed
website/cue/reference/components/transforms/base
4 files changed +24
-18
lines changed Original file line number Diff line number Diff line change @@ -27,12 +27,17 @@ pub struct SampleConfig {
27
27
/// dropped.
28
28
pub rate : u64 ,
29
29
30
- /// The name of the log field whose value is hashed to determine if the event should be
31
- /// passed .
30
+ /// The name of the field whose value is hashed to determine if the event should be
31
+ /// sampled .
32
32
///
33
- /// Consistently samples the same events. Actual rate of sampling may differ from the configured
34
- /// one if values in the field are not uniformly distributed. If left unspecified, or if the
35
- /// event doesn't have `key_field`, then events are count rated.
33
+ /// Each unique value for the key creates a bucket of related events to be sampled together
34
+ /// and the rate is applied to the buckets themselves to sample `1/N` buckets. The overall rate
35
+ /// of sampling may differ from the configured one if values in the field are not uniformly
36
+ /// distributed. If left unspecified, or if the event doesn’t have `key_field`, then the
37
+ /// event is sampled independently.
38
+ ///
39
+ /// This can be useful to, for example, ensure that all logs for a given transaction are
40
+ /// sampled together, but that overall `1/N` transactions are sampled.
36
41
#[ configurable( metadata( docs:: examples = "message" , ) ) ]
37
42
pub key_field : Option < String > ,
38
43
Original file line number Diff line number Diff line change @@ -33,11 +33,9 @@ pub struct ThrottleConfig {
33
33
#[ serde_as( as = "serde_with::DurationSeconds<f64>" ) ]
34
34
window_secs : Duration ,
35
35
36
- /// The name of the log field whose value is hashed to determine if the event should be
37
- /// rate limited.
36
+ /// The value to group events into separate buckets to be rate limited independently.
38
37
///
39
- /// Each unique key creates a bucket of related events to be rate limited separately. If
40
- /// left unspecified, or if the event doesn't have `key_field`, then the event is not rate
38
+ /// If left unspecified, or if the event doesn't have `key_field`, then the event is not rate
41
39
/// limited separately.
42
40
#[ configurable( metadata( docs:: examples = "{{ message }}" , docs:: examples = "{{ hostname }}" , ) ) ]
43
41
key_field : Option < Template > ,
Original file line number Diff line number Diff line change @@ -8,12 +8,17 @@ base: components: transforms: sample: configuration: {
8
8
}
9
9
key_field : {
10
10
description : """
11
- The name of the log field whose value is hashed to determine if the event should be
12
- passed .
11
+ The name of the field whose value is hashed to determine if the event should be
12
+ sampled .
13
13
14
- Consistently samples the same events. Actual rate of sampling may differ from the configured
15
- one if values in the field are not uniformly distributed. If left unspecified, or if the
16
- event doesn't have `key_field`, then events are count rated.
14
+ Each unique value for the key creates a bucket of related events to be sampled together
15
+ and the rate is applied to the buckets themselves to sample `1/N` buckets. Overall rate
16
+ of sampling may differ from the configured one if values in the field are not uniformly
17
+ distributed. If left unspecified, or if the event doesn’t have `key_field`, then the
18
+ event is sampled independently.
19
+
20
+ This can be useful to, for example, ensure that all logs for a given transaction are
21
+ sampled together, but that overall `1/N` transactions are sampled.
17
22
"""
18
23
required : false
19
24
type : string : examples : [" message " ]
Original file line number Diff line number Diff line change @@ -8,11 +8,9 @@ base: components: transforms: throttle: configuration: {
8
8
}
9
9
key_field : {
10
10
description : """
11
- The name of the log field whose value is hashed to determine if the event should be
12
- rate limited.
11
+ The value to group events into a separate buckets to be rate limited independently.
13
12
14
- Each unique key creates a bucket of related events to be rate limited separately. If
15
- left unspecified, or if the event doesn't have `key_field`, then the event is not rate
13
+ If left unspecified, or if the event doesn't have `key_field`, then the event is not rate
16
14
limited separately.
17
15
"""
18
16
required : false
You can’t perform that action at this time.
0 commit comments