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

Init CrashTracker support in the sidecar #535

Merged
merged 12 commits into from
Aug 19, 2024
Merged

Init CrashTracker support in the sidecar #535

merged 12 commits into from
Aug 19, 2024

Conversation

iamluc
Copy link
Contributor

@iamluc iamluc commented Jul 17, 2024

What does this PR do?

This PR introduces a CrashTracker receiver (via a Unix socket) in the sidecar.

As the sidecar uses the Tokio async framework, I had to convert a few functions from the crashtracker crate into async functions.

Motivation

What inspired you to submit this pull request?

Additional Notes

Anything else we should know when reviewing?

How to test the change?

Describe here in detail how the change can be validated.

@github-actions github-actions bot added profiling Relates to the profiling* modules. sidecar labels Jul 17, 2024
@pr-commenter
Copy link

pr-commenter bot commented Jul 18, 2024

Benchmarks

Comparison

Benchmark execution time: 2024-08-19 13:31:05

Comparing candidate commit ab216b8 in PR branch luc/php-crashtracker with baseline commit 31b6854 in branch main.

Found 0 performance improvements and 0 performance regressions! Performance is the same for 50 metrics, 2 unstable metrics.

Candidate

Candidate benchmark details

Group 1

cpu_model git_commit_sha git_commit_date git_branch
Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz ab216b8 1724073675 luc/php-crashtracker
scenario metric min mean ± sd median ± mad p75 p95 p99 max peak_to_median_ratio skewness kurtosis cv sem runs sample_size
tags/replace_trace_tags execution_time 2.709µs 2.746µs ± 0.017µs 2.751µs ± 0.009µs 2.758µs 2.769µs 2.774µs 2.775µs 0.89% -0.580 -0.662 0.61% 0.001µs 1 200
scenario metric 95% CI mean Shapiro-Wilk pvalue Ljung-Box pvalue (lag=1) Dip test pvalue
tags/replace_trace_tags execution_time [2.744µs; 2.749µs] or [-0.085%; +0.085%] None None None

Group 2

cpu_model git_commit_sha git_commit_date git_branch
Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz ab216b8 1724073675 luc/php-crashtracker
scenario metric min mean ± sd median ± mad p75 p95 p99 max peak_to_median_ratio skewness kurtosis cv sem runs sample_size
redis/obfuscate_redis_string execution_time 38.748µs 39.191µs ± 0.773µs 38.841µs ± 0.031µs 38.886µs 40.789µs 40.860µs 42.825µs 10.26% 1.904 2.508 1.97% 0.055µs 1 200
scenario metric 95% CI mean Shapiro-Wilk pvalue Ljung-Box pvalue (lag=1) Dip test pvalue
redis/obfuscate_redis_string execution_time [39.084µs; 39.298µs] or [-0.273%; +0.273%] None None None

Group 3

cpu_model git_commit_sha git_commit_date git_branch
Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz ab216b8 1724073675 luc/php-crashtracker
scenario metric min mean ± sd median ± mad p75 p95 p99 max peak_to_median_ratio skewness kurtosis cv sem runs sample_size
benching deserializing traces from msgpack to their internal representation execution_time 1.153µs 1.353µs ± 0.063µs 1.358µs ± 0.053µs 1.408µs 1.437µs 1.447µs 1.448µs 6.58% -0.639 0.393 4.63% 0.004µs 1 200
scenario metric 95% CI mean Shapiro-Wilk pvalue Ljung-Box pvalue (lag=1) Dip test pvalue
benching deserializing traces from msgpack to their internal representation execution_time [1.344µs; 1.362µs] or [-0.644%; +0.644%] None None None

Group 4

cpu_model git_commit_sha git_commit_date git_branch
Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz ab216b8 1724073675 luc/php-crashtracker
scenario metric min mean ± sd median ± mad p75 p95 p99 max peak_to_median_ratio skewness kurtosis cv sem runs sample_size
normalization/normalize_name/normalize_name/Too-Long-.Too-Long-.Too-Long-.Too-Long-.Too-Long-.Too-Lo... execution_time 312.264µs 318.438µs ± 1.558µs 318.715µs ± 0.756µs 319.433µs 320.346µs 320.693µs 320.759µs 0.64% -1.492 2.826 0.49% 0.110µs 1 200
normalization/normalize_name/normalize_name/Too-Long-.Too-Long-.Too-Long-.Too-Long-.Too-Long-.Too-Lo... throughput 3117601.691op/s 3140404.391op/s ± 15480.190op/s 3137603.225op/s ± 7424.697op/s 3145659.554op/s 3169826.428op/s 3196823.467op/s 3202419.650op/s 2.07% 1.531 2.973 0.49% 1094.615op/s 1 200
normalization/normalize_name/normalize_name/bad-name execution_time 27.988µs 28.073µs ± 0.059µs 28.066µs ± 0.044µs 28.107µs 28.179µs 28.228µs 28.230µs 0.59% 0.748 0.002 0.21% 0.004µs 1 200
normalization/normalize_name/normalize_name/bad-name throughput 35422994.837op/s 35622121.138op/s ± 74647.746op/s 35630708.981op/s ± 55782.448op/s 35687572.123op/s 35712928.086op/s 35728758.684op/s 35729856.177op/s 0.28% -0.739 -0.019 0.21% 5278.393op/s 1 200
normalization/normalize_name/normalize_name/good execution_time 16.728µs 16.767µs ± 0.022µs 16.761µs ± 0.018µs 16.786µs 16.799µs 16.810µs 16.835µs 0.44% 0.261 -1.021 0.13% 0.002µs 1 200
normalization/normalize_name/normalize_name/good throughput 59399610.882op/s 59640515.735op/s ± 76560.796op/s 59661828.666op/s ± 65474.286op/s 59710971.070op/s 59741160.790op/s 59760690.549op/s 59778495.345op/s 0.20% -0.258 -1.027 0.13% 5413.666op/s 1 200
scenario metric 95% CI mean Shapiro-Wilk pvalue Ljung-Box pvalue (lag=1) Dip test pvalue
normalization/normalize_name/normalize_name/Too-Long-.Too-Long-.Too-Long-.Too-Long-.Too-Long-.Too-Lo... execution_time [318.222µs; 318.654µs] or [-0.068%; +0.068%] None None None
normalization/normalize_name/normalize_name/Too-Long-.Too-Long-.Too-Long-.Too-Long-.Too-Long-.Too-Lo... throughput [3138258.985op/s; 3142549.796op/s] or [-0.068%; +0.068%] None None None
normalization/normalize_name/normalize_name/bad-name execution_time [28.064µs; 28.081µs] or [-0.029%; +0.029%] None None None
normalization/normalize_name/normalize_name/bad-name throughput [35611775.678op/s; 35632466.597op/s] or [-0.029%; +0.029%] None None None
normalization/normalize_name/normalize_name/good execution_time [16.764µs; 16.770µs] or [-0.018%; +0.018%] None None None
normalization/normalize_name/normalize_name/good throughput [59629905.145op/s; 59651126.325op/s] or [-0.018%; +0.018%] None None None

Group 5

cpu_model git_commit_sha git_commit_date git_branch
Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz ab216b8 1724073675 luc/php-crashtracker
scenario metric min mean ± sd median ± mad p75 p95 p99 max peak_to_median_ratio skewness kurtosis cv sem runs sample_size
write only interface execution_time 1.439µs 2.905µs ± 1.446µs 2.738µs ± 0.019µs 2.755µs 2.972µs 12.875µs 16.538µs 503.90% 8.023 64.671 49.64% 0.102µs 1 200
scenario metric 95% CI mean Shapiro-Wilk pvalue Ljung-Box pvalue (lag=1) Dip test pvalue
write only interface execution_time [2.705µs; 3.105µs] or [-6.896%; +6.896%] None None None

Group 6

cpu_model git_commit_sha git_commit_date git_branch
Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz ab216b8 1724073675 luc/php-crashtracker
scenario metric min mean ± sd median ± mad p75 p95 p99 max peak_to_median_ratio skewness kurtosis cv sem runs sample_size
normalization/normalize_service/normalize_service/A0000000000000000000000000000000000000000000000000... execution_time 618.378µs 619.121µs ± 0.407µs 619.088µs ± 0.244µs 619.287µs 619.889µs 620.310µs 621.127µs 0.33% 1.185 2.800 0.07% 0.029µs 1 200
normalization/normalize_service/normalize_service/A0000000000000000000000000000000000000000000000000... throughput 1609976.358op/s 1615193.338op/s ± 1061.579op/s 1615279.337op/s ± 637.149op/s 1615942.327op/s 1616586.444op/s 1616950.428op/s 1617133.334op/s 0.11% -1.178 2.769 0.07% 75.065op/s 1 200
normalization/normalize_service/normalize_service/Data🐨dog🐶 繋がっ⛰てて execution_time 385.727µs 388.062µs ± 1.090µs 387.998µs ± 0.666µs 388.657µs 390.030µs 391.062µs 391.500µs 0.90% 0.433 0.367 0.28% 0.077µs 1 200
normalization/normalize_service/normalize_service/Data🐨dog🐶 繋がっ⛰てて throughput 2554280.492op/s 2576929.887op/s ± 7232.191op/s 2577332.269op/s ± 4424.958op/s 2581817.806op/s 2588537.180op/s 2591112.152op/s 2592506.830op/s 0.59% -0.415 0.341 0.28% 511.393op/s 1 200
normalization/normalize_service/normalize_service/Test Conversion 0f Weird !@#$%^&**() Characters execution_time 190.894µs 191.383µs ± 0.195µs 191.368µs ± 0.133µs 191.517µs 191.725µs 191.842µs 191.976µs 0.32% 0.264 -0.083 0.10% 0.014µs 1 200
normalization/normalize_service/normalize_service/Test Conversion 0f Weird !@#$%^&**() Characters throughput 5208980.386op/s 5225136.493op/s ± 5313.284op/s 5225539.170op/s ± 3631.733op/s 5228996.551op/s 5232711.775op/s 5236270.382op/s 5238517.562op/s 0.25% -0.258 -0.087 0.10% 375.706op/s 1 200
normalization/normalize_service/normalize_service/[empty string] execution_time 45.110µs 45.224µs ± 0.059µs 45.222µs ± 0.043µs 45.260µs 45.330µs 45.378µs 45.396µs 0.38% 0.420 -0.184 0.13% 0.004µs 1 200
normalization/normalize_service/normalize_service/[empty string] throughput 22028265.096op/s 22112162.429op/s ± 28999.087op/s 22113062.671op/s ± 21191.702op/s 22135210.643op/s 22154465.428op/s 22163862.310op/s 22168016.145op/s 0.25% -0.414 -0.194 0.13% 2050.545op/s 1 200
normalization/normalize_service/normalize_service/test_ASCII execution_time 48.935µs 49.130µs ± 0.213µs 49.092µs ± 0.061µs 49.157µs 49.371µs 50.320µs 50.507µs 2.88% 4.406 22.398 0.43% 0.015µs 1 200
normalization/normalize_service/normalize_service/test_ASCII throughput 19799092.014op/s 20354629.103op/s ± 86667.315op/s 20369991.472op/s ± 25207.371op/s 20392832.803op/s 20420346.497op/s 20428405.686op/s 20435192.398op/s 0.32% -4.341 21.871 0.42% 6128.305op/s 1 200
scenario metric 95% CI mean Shapiro-Wilk pvalue Ljung-Box pvalue (lag=1) Dip test pvalue
normalization/normalize_service/normalize_service/A0000000000000000000000000000000000000000000000000... execution_time [619.065µs; 619.178µs] or [-0.009%; +0.009%] None None None
normalization/normalize_service/normalize_service/A0000000000000000000000000000000000000000000000000... throughput [1615046.213op/s; 1615340.463op/s] or [-0.009%; +0.009%] None None None
normalization/normalize_service/normalize_service/Data🐨dog🐶 繋がっ⛰てて execution_time [387.911µs; 388.213µs] or [-0.039%; +0.039%] None None None
normalization/normalize_service/normalize_service/Data🐨dog🐶 繋がっ⛰てて throughput [2575927.574op/s; 2577932.199op/s] or [-0.039%; +0.039%] None None None
normalization/normalize_service/normalize_service/Test Conversion 0f Weird !@#$%^&**() Characters execution_time [191.356µs; 191.410µs] or [-0.014%; +0.014%] None None None
normalization/normalize_service/normalize_service/Test Conversion 0f Weird !@#$%^&**() Characters throughput [5224400.123op/s; 5225872.864op/s] or [-0.014%; +0.014%] None None None
normalization/normalize_service/normalize_service/[empty string] execution_time [45.216µs; 45.232µs] or [-0.018%; +0.018%] None None None
normalization/normalize_service/normalize_service/[empty string] throughput [22108143.434op/s; 22116181.424op/s] or [-0.018%; +0.018%] None None None
normalization/normalize_service/normalize_service/test_ASCII execution_time [49.100µs; 49.159µs] or [-0.060%; +0.060%] None None None
normalization/normalize_service/normalize_service/test_ASCII throughput [20342617.846op/s; 20366640.359op/s] or [-0.059%; +0.059%] None None None

Group 7

cpu_model git_commit_sha git_commit_date git_branch
Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz ab216b8 1724073675 luc/php-crashtracker
scenario metric min mean ± sd median ± mad p75 p95 p99 max peak_to_median_ratio skewness kurtosis cv sem runs sample_size
normalization/normalize_trace/test_trace execution_time 301.798ns 312.571ns ± 12.862ns 305.906ns ± 2.561ns 315.027ns 343.765ns 346.449ns 349.917ns 14.39% 1.401 0.685 4.10% 0.909ns 1 200
scenario metric 95% CI mean Shapiro-Wilk pvalue Ljung-Box pvalue (lag=1) Dip test pvalue
normalization/normalize_trace/test_trace execution_time [310.788ns; 314.354ns] or [-0.570%; +0.570%] None None None

Group 8

cpu_model git_commit_sha git_commit_date git_branch
Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz ab216b8 1724073675 luc/php-crashtracker
scenario metric min mean ± sd median ± mad p75 p95 p99 max peak_to_median_ratio skewness kurtosis cv sem runs sample_size
credit_card/is_card_number/ execution_time 1.613µs 1.614µs ± 0.000µs 1.613µs ± 0.000µs 1.614µs 1.614µs 1.615µs 1.616µs 0.14% 0.833 1.560 0.03% 0.000µs 1 200
credit_card/is_card_number/ throughput 618888562.814op/s 619758007.584op/s ± 188782.250op/s 619778493.728op/s ± 144188.971op/s 619907600.462op/s 620007581.639op/s 620069716.694op/s 620107325.190op/s 0.05% -0.830 1.549 0.03% 13348.921op/s 1 200
credit_card/is_card_number/ 3782-8224-6310-005 execution_time 104.152µs 105.092µs ± 0.559µs 105.007µs ± 0.177µs 105.201µs 105.730µs 107.599µs 109.422µs 4.20% 3.981 23.944 0.53% 0.040µs 1 200
credit_card/is_card_number/ 3782-8224-6310-005 throughput 9138927.404op/s 9515756.236op/s ± 49588.286op/s 9523182.679op/s ± 16012.595op/s 9537555.953op/s 9567916.726op/s 9594167.826op/s 9601387.400op/s 0.82% -3.824 22.472 0.52% 3506.421op/s 1 200
credit_card/is_card_number/ 378282246310005 execution_time 96.184µs 96.988µs ± 0.557µs 96.852µs ± 0.247µs 97.183µs 98.086µs 98.892µs 99.708µs 2.95% 1.956 5.147 0.57% 0.039µs 1 200
credit_card/is_card_number/ 378282246310005 throughput 10029277.776op/s 10310856.757op/s ± 58570.683op/s 10325020.227op/s ± 26321.223op/s 10349352.855op/s 10374202.161op/s 10386604.734op/s 10396725.032op/s 0.69% -1.900 4.855 0.57% 4141.573op/s 1 200
credit_card/is_card_number/37828224631 execution_time 1.613µs 1.614µs ± 0.003µs 1.613µs ± 0.000µs 1.614µs 1.614µs 1.615µs 1.658µs 2.74% 13.648 187.802 0.19% 0.000µs 1 200
credit_card/is_card_number/37828224631 throughput 603281782.817op/s 619706308.286op/s ± 1178688.194op/s 619790548.194op/s ± 136569.208op/s 619930727.893op/s 620012881.423op/s 620051969.336op/s 620141325.786op/s 0.06% -13.627 187.415 0.19% 83345.842op/s 1 200
credit_card/is_card_number/378282246310005 execution_time 94.228µs 95.464µs ± 0.637µs 95.283µs ± 0.355µs 95.854µs 96.700µs 97.172µs 97.850µs 2.69% 0.910 0.558 0.67% 0.045µs 1 200
credit_card/is_card_number/378282246310005 throughput 10219708.303op/s 10475597.129op/s ± 69526.395op/s 10495070.812op/s ± 39238.313op/s 10524907.417op/s 10559106.288op/s 10588279.548op/s 10612606.716op/s 1.12% -0.876 0.462 0.66% 4916.259op/s 1 200
credit_card/is_card_number/37828224631000521389798 execution_time 94.088µs 94.718µs ± 0.417µs 94.671µs ± 0.252µs 94.964µs 95.479µs 95.726µs 97.008µs 2.47% 1.288 3.886 0.44% 0.029µs 1 200
credit_card/is_card_number/37828224631000521389798 throughput 10308454.236op/s 10557863.616op/s ± 46177.969op/s 10562885.193op/s ± 28072.209op/s 10589435.452op/s 10624312.784op/s 10627781.531op/s 10628346.864op/s 0.62% -1.234 3.574 0.44% 3265.275op/s 1 200
credit_card/is_card_number/x371413321323331 execution_time 22.448µs 22.801µs ± 0.185µs 22.778µs ± 0.097µs 22.877µs 23.162µs 23.370µs 23.413µs 2.79% 0.883 1.059 0.81% 0.013µs 1 200
credit_card/is_card_number/x371413321323331 throughput 42710668.667op/s 43859845.409op/s ± 353855.420op/s 43902338.801op/s ± 186303.084op/s 44082785.564op/s 44360263.161op/s 44488999.515op/s 44547955.722op/s 1.47% -0.829 0.932 0.80% 25021.357op/s 1 200
credit_card/is_card_number_no_luhn/ execution_time 1.612µs 1.613µs ± 0.000µs 1.613µs ± 0.000µs 1.614µs 1.614µs 1.614µs 1.615µs 0.08% 0.260 -0.505 0.03% 0.000µs 1 200
credit_card/is_card_number_no_luhn/ throughput 619304618.236op/s 619794736.818op/s ± 166934.398op/s 619793585.137op/s ± 128885.392op/s 619933518.182op/s 620025230.378op/s 620104725.666op/s 620160002.882op/s 0.06% -0.259 -0.506 0.03% 11804.044op/s 1 200
credit_card/is_card_number_no_luhn/ 3782-8224-6310-005 execution_time 85.868µs 86.694µs ± 0.395µs 86.647µs ± 0.236µs 86.924µs 87.450µs 87.776µs 87.995µs 1.55% 0.717 0.485 0.45% 0.028µs 1 200
credit_card/is_card_number_no_luhn/ 3782-8224-6310-005 throughput 11364335.502op/s 11535056.881op/s ± 52352.896op/s 11541040.300op/s ± 31478.733op/s 11571036.840op/s 11609799.601op/s 11628633.645op/s 11645738.639op/s 0.91% -0.690 0.435 0.45% 3701.909op/s 1 200
credit_card/is_card_number_no_luhn/ 378282246310005 execution_time 78.938µs 80.305µs ± 0.534µs 80.239µs ± 0.337µs 80.639µs 81.358µs 81.640µs 82.129µs 2.36% 0.569 0.574 0.66% 0.038µs 1 200
credit_card/is_card_number_no_luhn/ 378282246310005 throughput 12176006.215op/s 12453103.386op/s ± 82478.098op/s 12462755.079op/s ± 52562.423op/s 12508784.924op/s 12575758.405op/s 12623326.887op/s 12668131.440op/s 1.65% -0.524 0.517 0.66% 5832.082op/s 1 200
credit_card/is_card_number_no_luhn/37828224631 execution_time 1.613µs 1.614µs ± 0.000µs 1.613µs ± 0.000µs 1.614µs 1.614µs 1.615µs 1.615µs 0.10% 0.556 -0.312 0.03% 0.000µs 1 200
credit_card/is_card_number_no_luhn/37828224631 throughput 619190406.296op/s 619758818.111op/s ± 178279.369op/s 619795944.414op/s ± 133772.492op/s 619905839.737op/s 619989885.571op/s 620041314.144op/s 620079736.831op/s 0.05% -0.555 -0.314 0.03% 12606.255op/s 1 200
credit_card/is_card_number_no_luhn/378282246310005 execution_time 77.340µs 78.385µs ± 0.460µs 78.397µs ± 0.328µs 78.713µs 79.169µs 79.332µs 79.821µs 1.82% 0.164 -0.220 0.59% 0.033µs 1 200
credit_card/is_card_number_no_luhn/378282246310005 throughput 12528095.232op/s 12757969.723op/s ± 74827.521op/s 12755576.792op/s ± 53159.933op/s 12810730.336op/s 12875196.500op/s 12915966.458op/s 12929858.447op/s 1.37% -0.134 -0.243 0.59% 5291.105op/s 1 200
credit_card/is_card_number_no_luhn/37828224631000521389798 execution_time 94.074µs 94.623µs ± 0.364µs 94.569µs ± 0.249µs 94.849µs 95.250µs 95.645µs 95.940µs 1.45% 0.729 0.371 0.38% 0.026µs 1 200
credit_card/is_card_number_no_luhn/37828224631000521389798 throughput 10423194.479op/s 10568390.957op/s ± 40510.656op/s 10574306.551op/s ± 27807.517op/s 10600226.848op/s 10624464.531op/s 10627414.095op/s 10629877.396op/s 0.53% -0.708 0.316 0.38% 2864.536op/s 1 200
credit_card/is_card_number_no_luhn/x371413321323331 execution_time 22.438µs 22.763µs ± 0.187µs 22.733µs ± 0.127µs 22.897µs 23.104µs 23.254µs 23.302µs 2.50% 0.563 -0.294 0.82% 0.013µs 1 200
credit_card/is_card_number_no_luhn/x371413321323331 throughput 42914574.541op/s 43934522.164op/s ± 358371.514op/s 43989064.418op/s ± 246836.938op/s 44205280.505op/s 44424623.103op/s 44538721.541op/s 44566823.140op/s 1.31% -0.529 -0.348 0.81% 25340.693op/s 1 200
scenario metric 95% CI mean Shapiro-Wilk pvalue Ljung-Box pvalue (lag=1) Dip test pvalue
credit_card/is_card_number/ execution_time [1.613µs; 1.614µs] or [-0.004%; +0.004%] None None None
credit_card/is_card_number/ throughput [619731844.180op/s; 619784170.988op/s] or [-0.004%; +0.004%] None None None
credit_card/is_card_number/ 3782-8224-6310-005 execution_time [105.014µs; 105.169µs] or [-0.074%; +0.074%] None None None
credit_card/is_card_number/ 3782-8224-6310-005 throughput [9508883.776op/s; 9522628.695op/s] or [-0.072%; +0.072%] None None None
credit_card/is_card_number/ 378282246310005 execution_time [96.911µs; 97.065µs] or [-0.080%; +0.080%] None None None
credit_card/is_card_number/ 378282246310005 throughput [10302739.424op/s; 10318974.090op/s] or [-0.079%; +0.079%] None None None
credit_card/is_card_number/37828224631 execution_time [1.613µs; 1.614µs] or [-0.027%; +0.027%] None None None
credit_card/is_card_number/37828224631 throughput [619542953.438op/s; 619869663.133op/s] or [-0.026%; +0.026%] None None None
credit_card/is_card_number/378282246310005 execution_time [95.376µs; 95.552µs] or [-0.093%; +0.093%] None None None
credit_card/is_card_number/378282246310005 throughput [10465961.439op/s; 10485232.819op/s] or [-0.092%; +0.092%] None None None
credit_card/is_card_number/37828224631000521389798 execution_time [94.660µs; 94.776µs] or [-0.061%; +0.061%] None None None
credit_card/is_card_number/37828224631000521389798 throughput [10551463.794op/s; 10564263.439op/s] or [-0.061%; +0.061%] None None None
credit_card/is_card_number/x371413321323331 execution_time [22.776µs; 22.827µs] or [-0.113%; +0.113%] None None None
credit_card/is_card_number/x371413321323331 throughput [43810804.451op/s; 43908886.367op/s] or [-0.112%; +0.112%] None None None
credit_card/is_card_number_no_luhn/ execution_time [1.613µs; 1.613µs] or [-0.004%; +0.004%] None None None
credit_card/is_card_number_no_luhn/ throughput [619771601.316op/s; 619817872.320op/s] or [-0.004%; +0.004%] None None None
credit_card/is_card_number_no_luhn/ 3782-8224-6310-005 execution_time [86.639µs; 86.749µs] or [-0.063%; +0.063%] None None None
credit_card/is_card_number_no_luhn/ 3782-8224-6310-005 throughput [11527801.273op/s; 11542312.488op/s] or [-0.063%; +0.063%] None None None
credit_card/is_card_number_no_luhn/ 378282246310005 execution_time [80.231µs; 80.379µs] or [-0.092%; +0.092%] None None None
credit_card/is_card_number_no_luhn/ 378282246310005 throughput [12441672.715op/s; 12464534.057op/s] or [-0.092%; +0.092%] None None None
credit_card/is_card_number_no_luhn/37828224631 execution_time [1.613µs; 1.614µs] or [-0.004%; +0.004%] None None None
credit_card/is_card_number_no_luhn/37828224631 throughput [619734110.305op/s; 619783525.917op/s] or [-0.004%; +0.004%] None None None
credit_card/is_card_number_no_luhn/378282246310005 execution_time [78.321µs; 78.449µs] or [-0.081%; +0.081%] None None None
credit_card/is_card_number_no_luhn/378282246310005 throughput [12747599.349op/s; 12768340.098op/s] or [-0.081%; +0.081%] None None None
credit_card/is_card_number_no_luhn/37828224631000521389798 execution_time [94.573µs; 94.674µs] or [-0.053%; +0.053%] None None None
credit_card/is_card_number_no_luhn/37828224631000521389798 throughput [10562776.570op/s; 10574005.345op/s] or [-0.053%; +0.053%] None None None
credit_card/is_card_number_no_luhn/x371413321323331 execution_time [22.737µs; 22.789µs] or [-0.114%; +0.114%] None None None
credit_card/is_card_number_no_luhn/x371413321323331 throughput [43884855.319op/s; 43984189.009op/s] or [-0.113%; +0.113%] None None None

Group 9

cpu_model git_commit_sha git_commit_date git_branch
Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz ab216b8 1724073675 luc/php-crashtracker
scenario metric min mean ± sd median ± mad p75 p95 p99 max peak_to_median_ratio skewness kurtosis cv sem runs sample_size
sql/obfuscate_sql_string execution_time 74.429µs 74.665µs ± 0.124µs 74.655µs ± 0.032µs 74.689µs 74.749µs 74.870µs 76.168µs 2.03% 9.176 107.962 0.17% 0.009µs 1 200
scenario metric 95% CI mean Shapiro-Wilk pvalue Ljung-Box pvalue (lag=1) Dip test pvalue
sql/obfuscate_sql_string execution_time [74.648µs; 74.682µs] or [-0.023%; +0.023%] None None None

Group 10

cpu_model git_commit_sha git_commit_date git_branch
Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz ab216b8 1724073675 luc/php-crashtracker
scenario metric min mean ± sd median ± mad p75 p95 p99 max peak_to_median_ratio skewness kurtosis cv sem runs sample_size
two way interface execution_time 17.110µs 22.105µs ± 13.082µs 17.668µs ± 0.166µs 17.854µs 54.217µs 56.633µs 127.462µs 621.42% 3.928 21.438 59.03% 0.925µs 1 200
scenario metric 95% CI mean Shapiro-Wilk pvalue Ljung-Box pvalue (lag=1) Dip test pvalue
two way interface execution_time [20.292µs; 23.918µs] or [-8.202%; +8.202%] None None None

Group 11

cpu_model git_commit_sha git_commit_date git_branch
Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz ab216b8 1724073675 luc/php-crashtracker
scenario metric min mean ± sd median ± mad p75 p95 p99 max peak_to_median_ratio skewness kurtosis cv sem runs sample_size
benching string interning on wordpress profile execution_time 137.676µs 138.226µs ± 0.227µs 138.208µs ± 0.136µs 138.355µs 138.523µs 138.845µs 139.394µs 0.86% 0.873 3.807 0.16% 0.016µs 1 200
scenario metric 95% CI mean Shapiro-Wilk pvalue Ljung-Box pvalue (lag=1) Dip test pvalue
benching string interning on wordpress profile execution_time [138.195µs; 138.258µs] or [-0.023%; +0.023%] None None None

Baseline

Omitted due to size.

@iamluc iamluc changed the base branch from luc/crashtracker-fix-typos to main July 18, 2024 09:47
@datadog-datadog-prod-us1
Copy link

datadog-datadog-prod-us1 bot commented Jul 18, 2024

Library Vulnerabilities

✅ No library vulnerabilities found (scanned 6652db2).

}
self.upload_to_telemetry(config)

let rt = tokio::runtime::Builder::new_current_thread()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is probably not signal safe, should update the comment above

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I removed the comment because I didn't know what to say...
If you have a suggestion, I'm all ears.

crashtracker/src/crash_info.rs Outdated Show resolved Hide resolved
crashtracker/src/lib.rs Show resolved Hide resolved
Ok(())
}

pub async fn async_receiver_entry_point_unix_socket(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we have a test for this

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's tested by the "bin_tests" as both sync and async "entry_point_unix_socket" use this code path

/// Return the path of the crashtracker unix domain socket.
#[no_mangle]
#[allow(clippy::missing_safety_doc)]
pub unsafe extern "C" fn ddog_sidecar_get_crashtracker_unix_socket_path() -> ffi::CharSlice<'static>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Who is the owner of this string, and is expected to free it?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The caller. I mean, it returns libc::malloc, so the caller can just free() it.

let socket_path = crashtracker_unix_socket_path();
let str = socket_path.to_str().unwrap_or_default();

let size = str.len();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

At the cost of not being able to free() it in C code. This impl allows avoiding to need extra drop routines / relying on the specific allocator rust currently uses.

@codecov-commenter
Copy link

codecov-commenter commented Jul 24, 2024

Codecov Report

Attention: Patch coverage is 6.00000% with 94 lines in your changes missing coverage. Please review.

Project coverage is 71.77%. Comparing base (31b6854) to head (ab216b8).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #535      +/-   ##
==========================================
- Coverage   71.77%   71.77%   -0.01%     
==========================================
  Files         237      238       +1     
  Lines       32871    32924      +53     
==========================================
+ Hits        23594    23631      +37     
- Misses       9277     9293      +16     
Components Coverage Δ
crashtracker 20.66% <8.57%> (-0.60%) ⬇️
datadog-alloc 98.73% <ø> (ø)
data-pipeline 50.00% <ø> (ø)
data-pipeline-ffi 0.00% <ø> (ø)
ddcommon 82.11% <ø> (ø)
ddcommon-ffi 68.11% <ø> (ø)
ddtelemetry 59.02% <ø> (ø)
ipc 84.29% <ø> (ø)
profiling 84.26% <ø> (+0.69%) ⬆️
profiling-ffi 77.42% <ø> (ø)
serverless 0.00% <ø> (ø)
sidecar 40.23% <0.00%> (-0.25%) ⬇️
sidecar-ffi 0.00% <0.00%> (ø)
spawn-worker 54.87% <ø> (ø)
trace-mini-agent 70.88% <ø> (ø)
trace-normalization 98.25% <ø> (ø)
trace-obfuscation 95.73% <ø> (ø)
trace-protobuf 77.67% <ø> (ø)
trace-utils 93.39% <ø> (+0.42%) ⬆️

@github-actions github-actions bot removed the profiling Relates to the profiling* modules. label Aug 13, 2024
@iamluc iamluc marked this pull request as ready for review August 13, 2024 14:20
@iamluc iamluc requested review from a team as code owners August 13, 2024 14:20
@iamluc iamluc force-pushed the luc/php-crashtracker branch 2 times, most recently from f2ce221 to 2ae68b8 Compare August 19, 2024 09:29
@iamluc iamluc merged commit df81898 into main Aug 19, 2024
34 checks passed
@iamluc iamluc deleted the luc/php-crashtracker branch August 19, 2024 13:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants