-
Notifications
You must be signed in to change notification settings - Fork 336
v5.54.0 proposal #5777
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: v5.x
Are you sure you want to change the base?
v5.54.0 proposal #5777
Conversation
…of playwright (breaking change) (#5596)
When adding, removing or modifying a breakpoint there can be a race condtion if two Remove Config configs are received in quick succession. We already have a mutex to guard against this, but the code was in need of a refactor because: 1. We had duplicate mutex code in two different files, where only one was needed 2. We couldn't easily test the main mutex code in a unit test as it was added in the calling file and therefore not isolated to the function containing the race condition.
Methods with more than two words would not be renamed properly. That way they would not be picked up anymore.
* Add support for upload compression methods and levels * Allows "off" and "zstd" in addition to previously only used gzip as compression methods.
The internal state kept by the DI code of which probes are active, might not be 100% in sync with the actual breakpoints configured via the Chrome DevTools Protocol (CDP). This could happen if the probe is in the process of either being updated or removed while at the same time being hit in the instrumented application.
* Headers collection config * Revamp headers collection + extended collection * Fix condition for extended collection * Body collection config * Check for RASP events * Testing extend header collection * RASP body collection tests * Minor reformats * Lint * Clearer condition * Truncate body on body collection * Complete config test * Fix lint * Reporter init w/ appsec config * Remove TODO * Clarify collection comments * Update test.ts with new configuration * Fix linting * Integration test for RASP request body collection * Set tag when reported request body is truncated * Integration test for data collection * Fix linting * Check for header names in integration test * Set the correct value for request body exceeded size tag * Add support for toJSON in request body truncation * Invert condition for early return * Avoid slicing on request body truncation and implement it in a for loop * Rename reporter config * Simplify condition logic * Create block scope in switch case to limit the scope of declared vars * Initialize Array with a fixed size Co-authored-by: simon-id <[email protected]> * Switch to for loop Co-authored-by: simon-id <[email protected]> * Set env var as strings Co-authored-by: simon-id <[email protected]> * Set env var as string Co-authored-by: simon-id <[email protected]> * Refactor headers group declaration + using set instead of arrays * Cache res.getHeaders() * Fix config and its test * Fix config test for defaults values * Check reported request body truncation on integration test * Add a comment to clarify the test case * Add a test case to check no request body is collected when feat is disabled * Manage custom toJSON function in arrays --------- Co-authored-by: simon-id <[email protected]>
* Fix unicorn linter errors to activate more rules * Address uncertain unicorn linter errors These rules might have to stay deactivated. * Fix unicorn lint issues * Activate lots of unicorn eslint rules * Fix auto fixable unicorn linter errors This also improves the performance for lookups by using sets instead of arrays. * Fix linter issues This refactors code for readability by addressing linter issues. * Fixup manual things that were auto fixed Simplify code where possible. * Fix auto fixable eslint issues * fixup! * fixup! * fixup! Address comments and very small findings
Overall package sizeSelf size: 9.48 MB Dependency sizes| name | version | self size | total size | |------|---------|-----------|------------| | @datadog/libdatadog | 0.5.1 | 29.73 MB | 29.73 MB | | @datadog/native-appsec | 8.5.2 | 19.33 MB | 19.34 MB | | @datadog/pprof | 5.8.0 | 12.55 MB | 12.92 MB | | @datadog/native-iast-taint-tracking | 4.0.0 | 11.72 MB | 11.73 MB | | @opentelemetry/core | 1.30.1 | 908.66 kB | 7.16 MB | | protobufjs | 7.5.3 | 2.95 MB | 5.6 MB | | @datadog/wasm-js-rewriter | 4.0.1 | 2.85 MB | 3.58 MB | | @datadog/native-metrics | 3.1.1 | 1.02 MB | 1.43 MB | | @opentelemetry/api | 1.8.0 | 1.21 MB | 1.21 MB | | import-in-the-middle | 1.14.0 | 120.58 kB | 842.2 kB | | source-map | 0.7.4 | 226 kB | 226 kB | | opentracing | 0.14.7 | 194.81 kB | 194.81 kB | | lru-cache | 7.18.3 | 133.92 kB | 133.92 kB | | pprof-format | 2.1.0 | 111.69 kB | 111.69 kB | | @datadog/sketches-js | 2.1.1 | 109.9 kB | 109.9 kB | | lodash.sortby | 4.7.0 | 75.76 kB | 75.76 kB | | ignore | 5.3.2 | 53.63 kB | 53.63 kB | | istanbul-lib-coverage | 3.2.2 | 34.37 kB | 34.37 kB | | rfdc | 1.4.1 | 27.15 kB | 27.15 kB | | @isaacs/ttlcache | 1.4.1 | 25.2 kB | 25.2 kB | | dc-polyfill | 0.1.9 | 25.11 kB | 25.11 kB | | tlhunter-sorted-set | 0.1.0 | 24.94 kB | 24.94 kB | | shell-quote | 1.8.2 | 23.54 kB | 23.54 kB | | limiter | 1.1.5 | 23.17 kB | 23.17 kB | | retry | 0.13.1 | 18.85 kB | 18.85 kB | | semifies | 1.0.0 | 15.84 kB | 15.84 kB | | jest-docblock | 29.7.0 | 8.99 kB | 12.76 kB | | crypto-randomuuid | 1.0.0 | 11.18 kB | 11.18 kB | | ttl-set | 1.0.0 | 4.61 kB | 9.69 kB | | mutexify | 1.4.0 | 5.71 kB | 8.74 kB | | path-to-regexp | 0.1.12 | 6.6 kB | 6.6 kB | | koalas | 1.0.2 | 6.47 kB | 6.47 kB | | module-details-from-path | 1.0.4 | 3.96 kB | 3.96 kB |🤖 This report was automatically generated by heaviest-objects-in-the-universe |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## v5.x #5777 +/- ##
=======================================
Coverage ? 79.37%
=======================================
Files ? 523
Lines ? 23781
Branches ? 0
=======================================
Hits ? 18877
Misses ? 4904
Partials ? 0 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
BenchmarksBenchmark execution time: 2025-05-31 05:18:40 Comparing candidate commit d7c4b5b in PR branch Found 21 performance improvements and 12 performance regressions! Performance is the same for 1236 metrics, 54 unstable metrics. scenario:plugin-graphql-control-18
scenario:plugin-graphql-control-20
scenario:plugin-graphql-control-22
scenario:plugin-graphql-with-async-hooks-18
scenario:plugin-graphql-with-async-hooks-20
scenario:plugin-graphql-with-async-hooks-22
scenario:plugin-graphql-with-depth-and-collapse-off-18
scenario:plugin-graphql-with-depth-and-collapse-on-18
scenario:plugin-graphql-with-depth-off-18
scenario:plugin-graphql-with-depth-on-max-18
scenario:startup-control-everything-20
scenario:startup-control-everything-22
scenario:startup-with-tracer-everything-20
scenario:startup-with-tracer-everything-22
|
Datadog ReportBranch report: ✅ 0 Failed, 984 Passed, 0 Skipped, 19m 14.71s Total Time |
--------- Co-authored-by: Carles Capell <[email protected]>
Allow users of ddtrace to configure samplingIntervals for the NativeSpaceProfiler. Prior to this Wall, Events, and Space Profilers were all referencing the same option: samplingInterval, however, they had different units. NativeWallProfiler and EventsProfiler expected samplingInterval to be in hertz, and NativeSpaceProfiler expected samplingInterval to be in number of bytes between samples. This and the lack of environment variable support made it impossible for users to configure the NativeSpaceProfiler samplingInterval. Heap sampling rate needs to be configurable for JS applications that have very high allocation rates. In services, with high allocation rates, the default sampling interval can cause unacceptable slow downs. This change allows users to find a more appropriate heap sampling rate that is tuned to their application's allocation rate. Co-authored-by: Dylan Visher <[email protected]>
f49046d
to
1007e57
Compare
The removed code was basically a noop. It has never had any effect as you can't use the `delete` symbol to remove elements from a `Set`.
When running `yarn services`, a number of folders are created in the project, if they do not already exist. The algorithm to ensure these folders were present had a few bugs (which luckily didn't affect the outcome), and were overly complicated. This cleans all that up.
There's no reason to expose a function to re-calculate the `ddBasePath` as it will be the same throughout the run-time of the process.
* jsdoc and clarify test agent code
To enable, set `DD_CODE_ORIGIN_FOR_SPANS_ENABLED=true`. This is a follow up to PR #4449, which added support for Fastify entry spans.
* add threshold computation * add traceId BigInt func * add span context to sampler * add jsdoc and backport old Sampler as RandomSampler * accept both Span and SpanContext in isSampled func * update calls to isSampled with span * move langchain plugin to deterministic sampler
* add baggage to span tags * update config option naming * update test
1007e57
to
23c5837
Compare
* Activate unicorn/no-useless-undefined eslint rule * Activate unicorn/number-literal-case eslint rule * Activate unicorn/prefer-includes eslint rule * Activate unicorn/prefer-set-has eslint rule * Activate unicorn/prefer-native-coercion-functions eslint rule * Activate unicorn/no-lonely-if eslint rule * Activate unicorn/prefer-logical-operator-over-ternary eslint rule
* Activate unicorn/no-unreadable-array-destructuring eslint rule * Activate unicorn/numeric-separators-style eslint rule * Activate unicorn/prefer-string-raw eslint rule * Partially fix unicorn/prefer-spread eslint errors * Activate unicorn/prefer-optional-catch-binding eslint rule * Activate unicorn/prefer-string-slice eslint rule * Activate unicorn/prefer-number-properties eslint rule * Activate unicorn/prefer-object-from-entries eslint rule * Manually address two small issues * Activate unicorn/no-unreadable-iife eslint rule * Activate unicorn/no-object-as-default-parameter eslint rule * Activate unicorn/no-negated-condition eslint rule * Fix .slice issues and deactivate lint rule for old guardrails * Remove obsolete brackets * As drive-by mark a couple of rules as explicitly not to be activated.
23c5837
to
61a497f
Compare
* fix tests * fix aws require path for llmobs
This updates most dependencies in their minor/patch range, if an update is available. As devDependency the Node.js types are updated to v18 to reflect the latest changes that we support. Multer is updated to v2 and sinon is updated to v18.
* Activate unicorn/no-anonymous-default-export eslint rule * Minor improvements while working on the code * Activate unicorn/consistent-function-scoping eslint rule * Activate unicorn/prefer-ternary eslint rule * Partially fix unicorn/prefer-spread eslint errors * Partially address unicorn/no-for-loop errors The rule is not yet active as long as it changes to use Object.entries() in case the iteration count is needed. * Manually refactor things for future eslint rules * Fix faulty tests and improve readability of the refactoring
61a497f
to
d7c4b5b
Compare
36f4669c7a
] - (SEMVER-PATCH) Fix missing returns (Ruben Bridgewater) #5799d0de1c38ac
] - (SEMVER-PATCH) Activate more complicated unicorn eslint rules (Ruben Bridgewater) #57908b95a5fea0
] - (SEMVER-PATCH) Update dependencies (Ruben Bridgewater) #5791ea7e2ca526
] - (SEMVER-PATCH) ci(aws-sdk): fix bedrock runtime tests failing (Sam Brenner) #5795c504dc6244
] - (SEMVER-PATCH) Pin openai tests to below v5 in plugin test (Ruben Bridgewater) #57935e0f54e6fd
] - (SEMVER-PATCH) Activate more unicorn eslint rules (Ruben Bridgewater) #57895320f381d8
] - (SEMVER-PATCH) Activate multiple eslint rules (Ruben Bridgewater) #5786153a813e63
] - (SEMVER-PATCH) add release status checks (Roch Devost) #5674db66b0a2fb
] - (SEMVER-PATCH) [test-optimization] [SDTEST-1923] Fix Playwright tests inv5
(Mario Vidal Domínguez) #5788b9cb0ba524
] - (SEMVER-PATCH) [test optimization] Update automatic log submission tests to include playwright (Juan Antonio Fernández de Alba) #5783108a847fdb
] - (SEMVER-MINOR) add baggage to span tags (Ida Liu) #5767fe11a427e8
] - (SEMVER-MINOR) feat: add deterministic sampling with knuth based on TraceId (Benjamin De Bernardi) #57121639cf7f58
] - (SEMVER-PATCH) bump dc-polyfill to 0.1.9 (Roch Devost) #5784c946c71223
] - (SEMVER-PATCH) test: clean up Mocha setup code withVersions and withExports (Thomas Watson) #57856bfd2dd891
] - (SEMVER-MINOR) [Code Origin for Spans] Add support for Express entry spans (Thomas Watson) #5423d863bc420e
] - (SEMVER-PATCH) test: clean upyarn services
script (Thomas Watson) #5781676146afe4
] - (SEMVER-PATCH) test: remove manual promise handling from test (Thomas Hunter II) #5759f7287a1329
] - (SEMVER-PATCH) Make the ddBasePath variable a static string (Thomas Watson) #5775019b06661e
] - (SEMVER-PATCH) Docs on adding new APIs to dd-trace-api (Bryan English) #5749b5dfaab5a9
] - (SEMVER-PATCH) test: clean up algorithm to createversions/*
folders (Thomas Watson) #57784c99cbfd0f
] - (SEMVER-PATCH) test: clean up invalid code inyarn services
script (Thomas Watson) #577968d5534d11
] - (SEMVER-PATCH) Bump ESLint dependencies (Thomas Watson) #5776c970eb5dbb
] - (SEMVER-MINOR) Configurable NativeSpaceProfiler samplingInterval (Attila Szegedi) #5766c9918c0fcc
] - (SEMVER-MINOR) New vulnerability sampling algorithm (Ugaitz Urien) #56975ba58ae920
] - (SEMVER-PATCH) Fix unicorn linter errors to activate more rules (Ruben Bridgewater) #550162593f201f
] - (SEMVER-PATCH) [test-optimization] [SDTEST-2034] Send tag when there is no branch (Mario Vidal Domínguez) #57703ed46b7a4a
] - (SEMVER-MINOR) Extended Request Data Collection (Carles Capell) #5709632908899f
] - (SEMVER-PATCH) [DI] Fix race condition if breakpoint is hit while being removed (Thomas Watson) #5769f58c6a3f9e
] - (SEMVER-MINOR) Add support for profiler upload compression methods and levels (Attila Szegedi) #57651d71591f2e
] - (SEMVER-PATCH) Fix amqplib not always passing through the correct method names (Ruben Bridgewater) #5676ef7552b465
] - (SEMVER-PATCH) Remove code targeting unsupported Node.js versions (Ruben Bridgewater) #567232dd20e0cc
] - (SEMVER-PATCH) [DI] Refactor mutex code guarding race condition (Thomas Watson) #572891ecb745a5
] - (SEMVER-PATCH) [test-optimization] New default value for test session name (breaking change) (Juan Antonio Fernández de Alba) #5409dc92b29025
] - (SEMVER-PATCH) [test-optimization] [SDTEST-1884] Increase minimum supported version of playwright (breaking change) (Mario Vidal Domínguez) #55961f3b634ab9
] - (SEMVER-PATCH) [test-optimization] Increase minimum supported version of cypress (breaking change) (Juan Antonio Fernández de Alba) #5397