Skip to content
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

fix(aws_sqs source): Pass span context to spawned tasks #14254

Merged
merged 2 commits into from
Sep 2, 2022

Conversation

jszwedko
Copy link
Member

@jszwedko jszwedko commented Sep 1, 2022

So that metrics are correctly tagged.

Fixes: #14252

I still want to test this manually. #14196 will verify it further and add tests, but this should at least fix the issue.

Signed-off-by: Jesse Szwedko [email protected]

So that metrics are correctly tagged.

Fixes: #14252

Signed-off-by: Jesse Szwedko <[email protected]>
@netlify
Copy link

netlify bot commented Sep 1, 2022

Deploy Preview for vector-project canceled.

Name Link
🔨 Latest commit c50e8dd
🔍 Latest deploy log https://app.netlify.com/sites/vector-project/deploys/631277f53a887a0008665c71

@github-actions github-actions bot added the domain: sources Anything related to the Vector's sources label Sep 1, 2022
@jszwedko jszwedko requested a review from bruceg September 1, 2022 22:27
@github-actions
Copy link

github-actions bot commented Sep 1, 2022

Soak Test Results

Baseline: 05fc485
Comparison: d1248a1
Total Vector CPUs: 4

Explanation

A soak test is an integrated performance test for vector in a repeatable rig, with varying configuration for vector. What follows is a statistical summary of a brief vector run for each configuration across SHAs given above. The goal of these tests are to determine, quickly, if vector performance is changed and to what degree by a pull request. Where appropriate units are scaled per-core.

The table below, if present, lists those experiments that have experienced a statistically significant change in their throughput performance between baseline and comparision SHAs, with 90.0% confidence OR have been detected as newly erratic. Negative values mean that baseline is faster, positive comparison. Results that do not exhibit more than a ±8.87% change in mean throughput are discarded. An experiment is erratic if its coefficient of variation is greater than 0.3. The abbreviated table will be omitted if no interesting changes are observed.

No interesting changes in throughput with confidence ≥ 90.00% and absolute Δ mean >= ±8.87%:

Fine details of change detection per experiment.
experiment Δ mean Δ mean % confidence baseline mean baseline stdev baseline stderr baseline outlier % baseline CoV comparison mean comparison stdev comparison stderr comparison outlier % comparison CoV erratic declared erratic
http_to_http_acks 286.22KiB 1.64 80.06% 17.07MiB 7.69MiB 160.71KiB 0 0.450209 17.35MiB 7.4MiB 154.63KiB 0 0.426273 True True
syslog_humio_logs 97.61KiB 0.6 100.00% 15.9MiB 611.3KiB 12.48KiB 0 0.0375277 16.0MiB 744.96KiB 15.25KiB 0 0.0454603 False False
http_pipelines_blackhole_acks 6.88KiB 0.56 98.63% 1.19MiB 118.63KiB 2.41KiB 0 0.0973338 1.2MiB 68.83KiB 1.4KiB 0 0.0561536 False False
datadog_agent_remap_blackhole_acks 262.32KiB 0.42 99.07% 61.53MiB 4.1MiB 85.4KiB 0 0.066627 61.78MiB 2.55MiB 53.45KiB 0 0.0413325 False False
http_text_to_http_json 145.67KiB 0.36 100.00% 39.15MiB 757.0KiB 15.45KiB 0 0.0188801 39.29MiB 757.48KiB 15.46KiB 0 0.0188237 False False
syslog_regex_logs2metric_ddmetrics 42.53KiB 0.33 99.46% 12.57MiB 591.17KiB 12.04KiB 0 0.0459101 12.61MiB 460.01KiB 9.38KiB 0 0.0356068 False False
datadog_agent_remap_blackhole 132.1KiB 0.22 80.35% 59.01MiB 3.99MiB 83.13KiB 0 0.0675648 59.14MiB 2.85MiB 59.57KiB 0 0.0482497 False False
splunk_hec_indexer_ack_blackhole 9.04KiB 0.04 28.62% 23.76MiB 870.8KiB 17.72KiB 0 0.03579 23.76MiB 842.82KiB 17.15KiB 0 0.0346271 False False
datadog_agent_remap_datadog_logs_acks 24.04KiB 0.04 17.67% 61.37MiB 2.78MiB 58.07KiB 0 0.0452183 61.4MiB 4.35MiB 90.6KiB 0 0.0708746 False False
splunk_hec_to_splunk_hec_logs_noack 3.21KiB 0.01 24.81% 23.84MiB 370.56KiB 7.57KiB 0 0.0151788 23.84MiB 331.81KiB 6.77KiB 0 0.0135895 False False
enterprise_http_to_http -178.03B -0 1.85% 23.85MiB 259.69KiB 5.3KiB 0 0.0106325 23.85MiB 259.46KiB 5.3KiB 0 0.0106231 False False
file_to_blackhole -58.78KiB -0.06 41.21% 95.34MiB 3.34MiB 69.22KiB 0 0.0350163 95.28MiB 4.01MiB 83.5KiB 0 0.04211 False False
http_pipelines_blackhole -1010.51B -0.06 25.83% 1.64MiB 87.12KiB 1.78KiB 0 0.0518617 1.64MiB 118.06KiB 2.41KiB 0 0.0703202 False False
splunk_hec_route_s3 -16.87KiB -0.09 19.43% 17.93MiB 2.34MiB 48.84KiB 0 0.130715 17.91MiB 2.3MiB 48.12KiB 0 0.128371 False False
splunk_hec_to_splunk_hec_logs_acks -25.52KiB -0.1 69.60% 23.77MiB 825.3KiB 16.8KiB 0 0.0338979 23.75MiB 899.23KiB 18.28KiB 0 0.0369729 False False
http_to_http_json -29.68KiB -0.12 98.56% 23.85MiB 346.85KiB 7.08KiB 0 0.0142007 23.82MiB 481.81KiB 9.85KiB 0 0.0197502 False False
syslog_log2metric_splunk_hec_metrics -37.49KiB -0.21 95.76% 17.79MiB 529.5KiB 10.79KiB 0 0.0290605 17.75MiB 736.31KiB 14.99KiB 0 0.0404944 False False
datadog_agent_remap_datadog_logs -201.87KiB -0.33 96.93% 60.29MiB 1.13MiB 23.81KiB 0 0.0188206 60.1MiB 4.34MiB 90.29KiB 0 0.0721627 False False
syslog_loki -56.61KiB -0.4 97.86% 13.82MiB 711.74KiB 14.58KiB 0 0.0502714 13.77MiB 974.29KiB 19.81KiB 0 0.0690924 False False
http_to_http_noack -112.63KiB -0.46 100.00% 23.84MiB 409.04KiB 8.36KiB 0 0.0167541 23.73MiB 1.18MiB 24.7KiB 0 0.0499288 False False
fluent_elasticsearch -384.38KiB -0.47 100.00% 79.47MiB 54.33KiB 1.1KiB 0 0.000667427 79.1MiB 4.28MiB 87.9KiB 0 0.0540451 False False
syslog_splunk_hec_logs -136.37KiB -0.83 100.00% 16.03MiB 895.55KiB 18.24KiB 0 0.0545629 15.89MiB 942.27KiB 19.2KiB 0 0.0578903 False False
http_pipelines_no_grok_blackhole -115.56KiB -1.03 100.00% 11.0MiB 169.21KiB 3.45KiB 0 0.0150193 10.89MiB 1.07MiB 22.21KiB 0 0.0979585 False False
socket_to_socket_blackhole -450.48KiB -1.89 100.00% 23.31MiB 182.35KiB 3.72KiB 0 0.00763933 22.87MiB 225.21KiB 4.6KiB 0 0.00961621 False False
syslog_log2metric_humio_metrics -297.77KiB -2.27 100.00% 12.81MiB 630.02KiB 12.85KiB 0 0.0480154 12.52MiB 885.36KiB 18.03KiB 0 0.0690431 False False

@jszwedko jszwedko added this to the Vector v0.24.1 milestone Sep 2, 2022
@spencergilbert
Copy link
Contributor

I still want to test this manually. #14196 will verify it further and add tests, but this should at least fix the issue.

We actually are using our assertion helpers for this source, but the assertion helpers don't check for component tags.

Signed-off-by: Jesse Szwedko <[email protected]>
@jszwedko
Copy link
Member Author

jszwedko commented Sep 2, 2022

I tested this out and discovered the span propagation actually has to be on the future being spawned rather than the spawn call. I pushed c50e8dd to remedy that. This is a pretty subtle difference 😓

It seems to work now though. Hopefully we can get better tests around it.

Looks like this gotcha is on clippy's radar too: rust-lang/rust-clippy#8722

@jszwedko jszwedko enabled auto-merge (squash) September 2, 2022 21:42
@jszwedko jszwedko merged commit bd43ffb into master Sep 2, 2022
@jszwedko jszwedko deleted the aws-sqs-metric-tags branch September 2, 2022 23:21
@github-actions
Copy link

github-actions bot commented Sep 2, 2022

Soak Test Results

Baseline: 7b877d6
Comparison: c50e8dd
Total Vector CPUs: 4

Explanation

A soak test is an integrated performance test for vector in a repeatable rig, with varying configuration for vector. What follows is a statistical summary of a brief vector run for each configuration across SHAs given above. The goal of these tests are to determine, quickly, if vector performance is changed and to what degree by a pull request. Where appropriate units are scaled per-core.

The table below, if present, lists those experiments that have experienced a statistically significant change in their throughput performance between baseline and comparision SHAs, with 90.0% confidence OR have been detected as newly erratic. Negative values mean that baseline is faster, positive comparison. Results that do not exhibit more than a ±8.87% change in mean throughput are discarded. An experiment is erratic if its coefficient of variation is greater than 0.3. The abbreviated table will be omitted if no interesting changes are observed.

No interesting changes in throughput with confidence ≥ 90.00% and absolute Δ mean >= ±8.87%:

Fine details of change detection per experiment.
experiment Δ mean Δ mean % confidence baseline mean baseline stdev baseline stderr baseline outlier % baseline CoV comparison mean comparison stdev comparison stderr comparison outlier % comparison CoV erratic declared erratic
syslog_log2metric_humio_metrics 436.36KiB 3.52 100.00% 12.1MiB 322.34KiB 6.58KiB 0 0.0260159 12.52MiB 588.59KiB 11.99KiB 0 0.0458886 False False
socket_to_socket_blackhole 382.61KiB 1.65 100.00% 22.66MiB 815.73KiB 16.65KiB 0 0.0351551 23.03MiB 967.56KiB 19.75KiB 0 0.0410219 False False
splunk_hec_route_s3 163.54KiB 0.87 98.31% 18.26MiB 2.35MiB 48.93KiB 0 0.128643 18.42MiB 2.29MiB 47.85KiB 0 0.124098 False False
http_text_to_http_json 186.85KiB 0.47 100.00% 39.19MiB 769.18KiB 15.7KiB 0 0.0191623 39.37MiB 714.33KiB 14.59KiB 0 0.0177132 False False
syslog_splunk_hec_logs 70.98KiB 0.43 99.79% 16.26MiB 900.06KiB 18.3KiB 0 0.0540306 16.33MiB 689.28KiB 14.04KiB 0 0.041202 False False
syslog_regex_logs2metric_ddmetrics 31.87KiB 0.25 94.53% 12.43MiB 567.2KiB 11.56KiB 0 0.0445409 12.46MiB 583.51KiB 11.89KiB 0 0.0457078 False False
syslog_humio_logs 40.71KiB 0.24 100.00% 16.7MiB 106.94KiB 2.18KiB 0 0.00625301 16.74MiB 117.53KiB 2.41KiB 0 0.00685582 False False
splunk_hec_indexer_ack_blackhole 17.33KiB 0.07 48.64% 23.74MiB 951.03KiB 19.34KiB 0 0.0391126 23.76MiB 892.42KiB 18.16KiB 0 0.036676 False False
splunk_hec_to_splunk_hec_logs_acks 15.46KiB 0.06 46.27% 23.74MiB 900.73KiB 18.31KiB 0 0.0370446 23.76MiB 840.93KiB 17.11KiB 0 0.0345634 False False
splunk_hec_to_splunk_hec_logs_noack 10.05KiB 0.04 63.23% 23.83MiB 433.5KiB 8.85KiB 0 0.0177627 23.84MiB 332.67KiB 6.79KiB 0 0.0136255 False False
enterprise_http_to_http -1.07KiB -0 11.80% 23.85MiB 251.26KiB 5.13KiB 0 0.010287 23.85MiB 249.06KiB 5.09KiB 0 0.0101974 False False
http_pipelines_blackhole_acks -527.58B -0.04 13.83% 1.22MiB 112.18KiB 2.28KiB 0 0.0897215 1.22MiB 92.28KiB 1.88KiB 0 0.0738381 False False
http_pipelines_no_grok_blackhole -5.09KiB -0.05 18.73% 10.96MiB 42.22KiB 882.61B 0 0.00375937 10.96MiB 1.03MiB 21.44KiB 0 0.093918 False False
file_to_blackhole -62.1KiB -0.06 43.52% 95.33MiB 3.42MiB 70.86KiB 0 0.0358565 95.27MiB 3.91MiB 81.32KiB 0 0.0410379 False False
http_to_http_json -37.62KiB -0.15 99.67% 23.85MiB 330.88KiB 6.75KiB 0 0.0135475 23.81MiB 531.27KiB 10.85KiB 0 0.0217855 False False
fluent_elasticsearch -204.76KiB -0.25 100.00% 79.47MiB 52.94KiB 1.07KiB 0 0.000650427 79.27MiB 1.75MiB 35.95KiB 0 0.0220361 False False
syslog_log2metric_splunk_hec_metrics -55.78KiB -0.32 95.99% 17.1MiB 850.4KiB 17.33KiB 0 0.0485469 17.05MiB 1.0MiB 20.92KiB 0 0.0588545 False False
http_to_http_noack -86.28KiB -0.35 99.93% 23.83MiB 522.49KiB 10.68KiB 0 0.0214093 23.74MiB 1.1MiB 23.02KiB 0 0.0464803 False False
datadog_agent_remap_blackhole_acks -245.08KiB -0.38 97.39% 62.24MiB 4.44MiB 92.38KiB 0 0.0712862 62.0MiB 2.87MiB 59.94KiB 0 0.0462104 False False
datadog_agent_remap_datadog_logs_acks -393.9KiB -0.64 99.62% 60.25MiB 4.01MiB 83.99KiB 0 0.0666267 59.86MiB 5.14MiB 107.03KiB 0 0.085881 False False
datadog_agent_remap_blackhole -468.97KiB -0.76 100.00% 60.5MiB 4.09MiB 85.26KiB 0 0.0676474 60.04MiB 3.22MiB 67.11KiB 0 0.0535883 False False
datadog_agent_remap_datadog_logs -543.13KiB -0.86 100.00% 62.0MiB 1.03MiB 21.58KiB 0 0.0166094 61.47MiB 4.12MiB 85.81KiB 0 0.0670177 False False
http_to_http_acks -255.65KiB -1.43 72.04% 17.45MiB 7.82MiB 163.52KiB 0 0.448067 17.2MiB 8.19MiB 170.74KiB 0 0.475821 True True
syslog_loki -251.94KiB -1.66 100.00% 14.85MiB 314.65KiB 6.44KiB 0 0.0206942 14.6MiB 721.33KiB 14.66KiB 0 0.0482402 False False
http_pipelines_blackhole -43.62KiB -2.53 100.00% 1.68MiB 73.67KiB 1.5KiB 0 0.0427163 1.64MiB 141.49KiB 2.88KiB 0 0.0841662 False False

@hhromic
Copy link
Contributor

hhromic commented Sep 8, 2022

I can confirm now that this fix worked in the latest nightly image 👍.
Thanks for the quick fix! Looking forward for the next bugfix release now.

jszwedko added a commit that referenced this pull request Sep 9, 2022
* fix(aws_sqs source): Pass span context to spawned tasks

So that metrics are correctly tagged.

Fixes: #14252

Signed-off-by: Jesse Szwedko <[email protected]>

* Move span attachment

Signed-off-by: Jesse Szwedko <[email protected]>

Signed-off-by: Jesse Szwedko <[email protected]>
jszwedko added a commit that referenced this pull request Sep 12, 2022
* fix(aws_sqs source): Pass span context to spawned tasks

So that metrics are correctly tagged.

Fixes: #14252

Signed-off-by: Jesse Szwedko <[email protected]>

* Move span attachment

Signed-off-by: Jesse Szwedko <[email protected]>

Signed-off-by: Jesse Szwedko <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
domain: sources Anything related to the Vector's sources
Projects
None yet
Development

Successfully merging this pull request may close these issues.

aws_sqs source: metrics are missing component tags
4 participants