File tree Expand file tree Collapse file tree
agent-data-plane-config/src
saluki-component-config/src Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -41,6 +41,9 @@ pub struct DogStatsDSalukiOnly {
4141 /// Number of receive buffers (`dogstatsd_buffer_count`).
4242 pub buffer_count : Option < usize > ,
4343
44+ /// Max receive buffers (`dogstatsd_buffer_count_max`).
45+ pub buffer_count_max : Option < usize > ,
46+
4447 /// Max cached metric contexts (`dogstatsd_cached_contexts_limit`).
4548 pub cached_contexts_limit : Option < usize > ,
4649
@@ -79,6 +82,9 @@ impl SalukiOnlyConfiguration {
7982 if let Some ( v) = self . dogstatsd . buffer_count {
8083 dsd. buffer_count = v;
8184 }
85+ if let Some ( v) = self . dogstatsd . buffer_count_max {
86+ dsd. buffer_count_max = v;
87+ }
8288 if let Some ( v) = self . dogstatsd . cached_contexts_limit {
8389 dsd. cached_contexts_limit = v;
8490 }
Original file line number Diff line number Diff line change @@ -26,11 +26,17 @@ pub struct SourceConfig {
2626 /// Payloads larger than this are truncated, leading to discarded messages. Defaults to 8192.
2727 pub buffer_size : usize ,
2828
29- /// The number of message buffers to allocate overall .
29+ /// The number of message buffers to allocate up front .
3030 ///
3131 /// Defaults to 128.
3232 pub buffer_count : usize ,
3333
34+ /// The maximum number of message buffers to allocate overall.
35+ ///
36+ /// The pool grows on demand from `buffer_count` up to this limit. A value below `buffer_count`
37+ /// is treated as equal to it. Defaults to 256.
38+ pub buffer_count_max : usize ,
39+
3440 /// The UDP port to listen on. If set to `0`, UDP is not used.
3541 ///
3642 /// Defaults to 8125.
@@ -170,6 +176,7 @@ impl Default for SourceConfig {
170176 Self {
171177 buffer_size : 8192 ,
172178 buffer_count : 128 ,
179+ buffer_count_max : 256 ,
173180 port : 8125 ,
174181 socket_receive_buffer_size : 0 ,
175182 tcp_port : 0 ,
You can’t perform that action at this time.
0 commit comments