-
Notifications
You must be signed in to change notification settings - Fork 10
tag aggregation smp tests #1252
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: raymond/tag-agg-correctness
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,42 @@ | ||
| use metrics::Counter; | ||
| use saluki_metrics::MetricsBuilder; | ||
|
|
||
| use super::FilterMetricTagsOutcome; | ||
|
|
||
| #[derive(Clone)] | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I know binary size is a big thing for us. Do we not derive Debug by default for that reason? |
||
| pub struct Telemetry { | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think structures like this should have doc comments, especially when pub. Or... to kind of say something similar but differently, Perhaps Edit: ok I answered the question with Claude. Yes there is a pattern of telemetry.rs files and structs named telemetry. My next question is whether it needs to be |
||
| rule_hits: Counter, | ||
| rule_misses: Counter, | ||
| noop_hits: Counter, | ||
| metrics_modified: Counter, | ||
| tags_filtered: Counter, | ||
| } | ||
|
|
||
| impl Telemetry { | ||
| pub fn new(builder: &MetricsBuilder) -> Self { | ||
| Self { | ||
| rule_hits: builder.register_debug_counter("tag_filterlist_rule_hits_total"), | ||
| rule_misses: builder.register_debug_counter("tag_filterlist_rule_misses_total"), | ||
| noop_hits: builder.register_debug_counter("tag_filterlist_noop_hits_total"), | ||
| metrics_modified: builder.register_debug_counter("tag_filterlist_metrics_modified_total"), | ||
| tags_filtered: builder.register_debug_counter("tag_filterlist_tags_filtered_total"), | ||
| } | ||
| } | ||
|
|
||
| pub fn record(&self, outcome: FilterMetricTagsOutcome) { | ||
| match outcome { | ||
| FilterMetricTagsOutcome::RuleMiss => { | ||
| self.rule_misses.increment(1); | ||
| } | ||
| FilterMetricTagsOutcome::NoChange => { | ||
| self.rule_hits.increment(1); | ||
| self.noop_hits.increment(1); | ||
| } | ||
| FilterMetricTagsOutcome::Modified { removed_tags } => { | ||
| self.rule_hits.increment(1); | ||
| self.metrics_modified.increment(1); | ||
| self.tags_filtered.increment(removed_tags as u64); | ||
| } | ||
| } | ||
| } | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,51 @@ | ||
| -----BEGIN CERTIFICATE----- | ||
| MIIDwTCCAqmgAwIBAgIUGNrRiJ81arCE1jTvLRoxxuLVoHAwDQYJKoZIhvcNAQEL | ||
| BQAwgYgxCzAJBgNVBAYTAlVTMQswCQYDVQQIDAJOWTEWMBQGA1UEBwwNTmV3IFlv | ||
| cmsgQ2l0eTEWMBQGA1UECgwNRGF0YWRvZywgSW5jLjEoMCYGA1UECwwfU2VsZi1T | ||
| aWduZWQgVGVzdGluZyBDZXJ0aWZpY2F0ZTESMBAGA1UEAwwJbG9jYWxob3N0MB4X | ||
| DTI1MTExMzE4NDAxMFoXDTM1MTExMTE4NDAxMFowgYgxCzAJBgNVBAYTAlVTMQsw | ||
| CQYDVQQIDAJOWTEWMBQGA1UEBwwNTmV3IFlvcmsgQ2l0eTEWMBQGA1UECgwNRGF0 | ||
| YWRvZywgSW5jLjEoMCYGA1UECwwfU2VsZi1TaWduZWQgVGVzdGluZyBDZXJ0aWZp | ||
| Y2F0ZTESMBAGA1UEAwwJbG9jYWxob3N0MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8A | ||
| MIIBCgKCAQEAs9oaPxXZ5t2725jEWJ+kLMbH6tFzKIgGEG2wpzJik1AumsSeax40 | ||
| JvA6W20Gyb73KkbCWM7Hm83++5QesDllpIvK0QNlDsz9VzQtiMCRZQ5Dfuw6stl+ | ||
| KQaCFvaEXBwvz/kfrIBLDeww9H9VL3YP2JnHIcA4Y5bvdIrSr3q59n7nd9exBtjS | ||
| IZxLHxf44/yQMIUcmPESnLNGYLxqIYuHvre+t1CrWduzHwKtsSIP1qy3U2YCRQW6 | ||
| mxDaZ+aI0BY8vYNX1w4XEeW8NO1HEu25DPXPWGbcSgHVk2VnQKtMIoVjuCGZGbBz | ||
| /TFJo69KoW/3CH3WHpT2JVKPV5itxkP68QIDAQABoyEwHzAdBgNVHQ4EFgQUFHdk | ||
| 73oIdZ7CkilNi96SveiH/OcwDQYJKoZIhvcNAQELBQADggEBAEMd7CiZkIqtE+O4 | ||
| Nj19xiTflKyw0EBklwlq1NrFb6VpGN3vPcu5X2CNH9p+c+zPYgDSTf+IFBYXO/zE | ||
| AzNYjFeUQf6Hsh0fTLqaiaueiAZw1o6QJp7/xFdwFcUFJM72lIlgndkoffEJCLOR | ||
| GcjAYD2Qv/oCjQ2B5xeHT9Sk4t85dhiK0aLbeSi+9yqtHis15OW8vqVFJXh1SxMV | ||
| zSKN9C4Yw0JKMNqlmePjQIc3d28tm4sUOzD2+qF+mSTSZqvAEuO3loQJPexfsDsF | ||
| n929iEzFbOshRpjKp/mZ1jzZewDOIg5Zek1UmbqIHf9MHfpdDYA0zcEnzTQqGFtL | ||
| BxX9Nnk= | ||
| -----END CERTIFICATE----- | ||
| -----BEGIN PRIVATE KEY----- | ||
| MIIEvAIBADANBgkqhkiG9w0BAQEFAASCBKYwggSiAgEAAoIBAQCz2ho/Fdnm3bvb | ||
| mMRYn6Qsxsfq0XMoiAYQbbCnMmKTUC6axJ5rHjQm8DpbbQbJvvcqRsJYzsebzf77 | ||
| lB6wOWWki8rRA2UOzP1XNC2IwJFlDkN+7Dqy2X4pBoIW9oRcHC/P+R+sgEsN7DD0 | ||
| f1Uvdg/YmcchwDhjlu90itKvern2fud317EG2NIhnEsfF/jj/JAwhRyY8RKcs0Zg | ||
| vGohi4e+t763UKtZ27MfAq2xIg/WrLdTZgJFBbqbENpn5ojQFjy9g1fXDhcR5bw0 | ||
| 7UcS7bkM9c9YZtxKAdW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aikIkEYFPdd/0M5J | ||
| 2x6OVOpP+yua6PTDnI/7ZOGA1kV7tQY5ww1nGIBKlG9178gR0p+UGYychddiFYWW | ||
| okTKpmjrEFPaseKHWnosA5QiEPZvZmHMT8qdiNUCgYAweUc7+5slfxKYVLUo34p9 | ||
| BiED632dV2YA7CYf+iEjXoFjCOH+ZqzI7OGfODpSMpjim3Fxt++UWbJscbNmtCZr | ||
| UeNDsJxiC+eksGWqpu0QoKdNPYRBB2QQFcvTT0AVt6PTzKaFVBvF/dnLuODjXp9Y | ||
| R5Ivn5V7QPeMY56Uzr2fJQ== | ||
| -----END PRIVATE KEY----- |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| {} |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,44 @@ | ||
| optimization_goal: cpu | ||
| erratic: false | ||
| target: | ||
| name: agent-data-plane | ||
| command: /maybe-profile.sh /usr/local/bin/agent-data-plane --config /etc/agent-data-plane/empty.yaml run | ||
| cpu_allotment: 4 | ||
| memory_allotment: 3200MiB | ||
| environment: | ||
| DD_HOSTNAME: smp-regression | ||
| DD_API_KEY: foo00000001 | ||
| DD_DD_URL: http://127.0.0.1:9091 | ||
| DD_IPC_CERT_FILE_PATH: /etc/agent-data-plane/cert.pem | ||
| DD_LOG_FORMAT_JSON: "true" | ||
| DD_DATA_PLANE_STANDALONE_MODE: "true" | ||
| DD_DATA_PLANE_TELEMETRY_ENABLED: "true" | ||
| DD_DATA_PLANE_TELEMETRY_LISTEN_ADDR: tcp://127.0.0.1:5102 | ||
| DD_DATA_PLANE_DOGSTATSD_ENABLED: "true" | ||
| DD_DOGSTATSD_PORT: "0" | ||
| DD_DOGSTATSD_SOCKET: /tmp/dsd.socket | ||
| DD_DOGSTATSD_ORIGIN_DETECTION: "true" | ||
| DD_AGGREGATE_CONTEXT_LIMIT: "80000" | ||
| profiling_environment: | ||
| SMP_PROFILING_ENABLED: "true" | ||
| DD_SERVICE: agent-data-plane | ||
| DD_TRACE_AGENT_URL: unix:///smp-host/apm.socket | ||
| DD_PROFILING_NATIVE_PRESET: cpu_live_heap | ||
| DD_PROFILING_INLINED_FUNCTIONS: "true" | ||
| checks: | ||
| - name: memory_usage | ||
| description: Memory usage quality gate. This puts a bound on the total ADP memory usage. | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is this intended to describe the entire experiment, or just the check? Without looking at other experiment.yaml files (yet), it feels like what is missing is a story about why the experiment was added. For example we have these large metric names that are the same until the Nth character position and these are being added to verify the performance of a new tag filtering mechanism. Do we want some of that context and thinking to be added to either the lading.yaml or experiment.yaml files? |
||
| bounds: | ||
| series: total_rss_bytes | ||
| upper_bound: 900.0 MiB | ||
| report_links: | ||
| - text: (metrics) | ||
| link: https://app.datadoghq.com/dashboard/4br-nxz-khi?fromUser=true&refresh_mode=paused&tpl_var_adp-run-id%5B0%5D={{ job_id | ||
| }}&tpl_var_experiment%5B0%5D={{ experiment }}&view=spans&from_ts={{ start_time_ms }}&to_ts={{ end_time_ms }}&live=false | ||
| - text: (profiles) | ||
| link: https://app.datadoghq.com/profiling/explorer?query=env%3Asingle-machine-performance%20service%3Aagent-data-plane%20job_id%3A{{ | ||
| job_id }}%20experiment%3A{{ experiment }}&agg_m=count&agg_m_source=base&agg_t=count&fromUser=false&viz=stream&start={{ | ||
| filter_start }}&end={{ filter_end }}&paused=true | ||
| - text: (logs) | ||
| link: https://app.datadoghq.com/logs?query=experiment%3A{{ experiment }}%20run_id%3A{{ job_id }}&agg_m=count&agg_m_source=base&agg_q=%40span.url&agg_q_source=base&agg_t=count&fromUser=true&index=single-machine-performance-target-logs&messageDisplay=inline&refresh_mode=paused&storage=hot&stream_sort=time%2Cdesc&top_n=100&top_o=top&viz=stream&x_missing=true&from_ts={{ | ||
| filter_start }}&to_ts={{ filter_end }}&live=false | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,47 @@ | ||
| blackhole: | ||
| - http: | ||
| binding_addr: 127.0.0.1:9091 | ||
| - http: | ||
| binding_addr: 127.0.0.1:9092 | ||
| target_metrics: | ||
| - prometheus: | ||
| uri: http://127.0.0.1:5102/scrape | ||
| generator: | ||
| - unix_datagram: | ||
| seed: [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97, 101, 103, 107, | ||
| 109, 113, 127, 131] | ||
| path: /tmp/dsd.socket | ||
| bytes_per_second: 250 MiB | ||
| maximum_prebuild_cache_size_bytes: 500 MiB | ||
| variant: | ||
| dogstatsd: | ||
| contexts: | ||
| inclusive: | ||
| min: 78000 | ||
| max: 78000 | ||
| tags_per_msg: | ||
| inclusive: | ||
| min: 54 | ||
| max: 54 | ||
| multivalue_count: | ||
| inclusive: | ||
| min: 2 | ||
| max: 32 | ||
| multivalue_pack_probability: 0.08 | ||
| kind_weights: | ||
| metric: 90 | ||
| event: 0 | ||
| service_check: 0 | ||
| metric_weights: | ||
| count: 0 | ||
| gauge: 0 | ||
| timer: 0 | ||
| distribution: 5 | ||
| set: 0 | ||
| histogram: 0 | ||
| metric_names: | ||
| - metricname_aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa{{0-499}} | ||
| tag_names: | ||
| - tagname_aaaaaaaaaaaaaaaaaaaaaa_{{0-54}} | ||
| tag_values: | ||
| - value{{0-9}} | ||
rayz marked this conversation as resolved.
Show resolved
Hide resolved
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
saluki-componentshas#![deny(warnings)], andComponentMetricsExtis imported here but not used anywhere in the module. This will fail the build due to an unused import warning. Remove the import, or use the extension trait explicitly if it’s required for metrics wiring.