Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: DataDog/dd-trace-php
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 0.92.2
Choose a base ref
...
head repository: DataDog/dd-trace-php
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 0.93.0
Choose a head ref

Commits on Sep 29, 2023

  1. fix(profiling): do not leak module entry on purpose (#2291)

    This was done in the early days of the move from C to Rust. The goal
    at the time was to avoid unsafe code, and that was one way of working
    around specific requirements. This is a different way, still mostly
    safe code, but will not leak.
    
    Note that this wasn't a leak that mattered to anything except
    tooling. The goal is to soon run an NTS+ASAN build for the profiler,
    and this would trigger the leak sanitizer (implied by address
    sanitizer on Linux).
    morrisonlevi authored Sep 29, 2023
    Copy the full SHA
    ca7592e View commit details

Commits on Oct 3, 2023

  1. Fix ZAI config handling for .htaccess with php-fpm (#2298)

    When connecting .htaccess via php-fpm, apache will set true environment variables, a circumstance where the handling explicitly calling ZaiConfigOnUpdateIni was skipped, leading to non-updated configs.
    
    Signed-off-by: Bob Weinand <bob.weinand@datadoghq.com>
    bwoebi authored Oct 3, 2023
    Copy the full SHA
    42fb326 View commit details

Commits on Oct 4, 2023

  1. Add PHP 8.3 support (#2098)

    Signed-off-by: Bob Weinand <bob.weinand@datadoghq.com>
    Co-authored-by: Bob Weinand <bob.weinand@datadoghq.com>
    realFlowControl and bwoebi authored Oct 4, 2023
    Copy the full SHA
    a11444e View commit details
  2. Copy the full SHA
    addceef View commit details
  3. Copy the full SHA
    c59e4b5 View commit details

Commits on Oct 5, 2023

  1. Copy the full SHA
    aa0206a View commit details

Commits on Oct 6, 2023

  1. fix typo (#2307)

    realFlowControl authored Oct 6, 2023
    Copy the full SHA
    1ce04ad View commit details

Commits on Oct 9, 2023

  1. Expand arrays and public properties of objects in meta into nested-ta…

    …g format (#2302)
    
    This will be required for the display of OpenTelemetry array attributes.
    Note that this also removes the parenthesis from boolean/null values in order to be consistent with other languages, i.e. system-tests.
    
    Signed-off-by: Bob Weinand <bob.weinand@datadoghq.com>
    bwoebi authored Oct 9, 2023
    Copy the full SHA
    a1a69c2 View commit details

Commits on Oct 12, 2023

  1. Subclass SpanData with RootSpanData (#2309)

    This allows setting specific data on RootSpans.
    Further, since properties are always at the end of the zend_object, if RootSpanData has properties, they would conflict with the trailing SpanData members. Hence, they need to be moved in front.
    
    Signed-off-by: Bob Weinand <bob.weinand@datadoghq.com>
    bwoebi authored Oct 12, 2023
    Copy the full SHA
    ec50fc1 View commit details
  2. Explicitly drop dd.p.dm if provided in propagated tags when the incom…

    …ing sampling priority is reject (#2310)
    
    Beforehand, the tracer would pass _dd.p.dm unfiltered, if it was propagated and sampling priorities not changed. I do think this is the more reasonable behaviour, but complying with system tests here.
    
    Signed-off-by: Bob Weinand <bob.weinand@datadoghq.com>
    bwoebi authored Oct 12, 2023
    Copy the full SHA
    e50dbdf View commit details
  3. Copy the full SHA
    20a4874 View commit details
  4. Strictly validate dd.p.tid (#2303)

    Also ensure consuming trace headers does apply to an existing root span instead of preset if one exists.
    
    Signed-off-by: Bob Weinand <bob.weinand@datadoghq.com>
    bwoebi authored Oct 12, 2023
    Copy the full SHA
    3d6d159 View commit details

Commits on Oct 16, 2023

  1. Report extensions used in telemetry (#2295)

    Signed-off-by: Bob Weinand <bob.weinand@datadoghq.com>
    bwoebi authored Oct 16, 2023
    Copy the full SHA
    2e18ad1 View commit details

Commits on Oct 23, 2023

  1. Copy the full SHA
    29ce0c3 View commit details
  2. Refactor tightly coupled extraction state (#2314)

    Moving:
    - distributed state directly to the root span
    - the extraction logic into its own file, reusable for different purposes (extracting to span, to globals, to span link)
    - the trace_id to only the root span
    - the parent id to only the root span; the parent id of any other span is simply the id of the parent span
    
    The distributed tracing state is now fully separated between the root span-less (i.e. containing incoming distributed data) and the distributed data tied to a span, allowing it to properly use their own distributed tracing without information leaking across traces.
    
    It also adds a small hexId() helper function on SpanData.
    SpanLink gains a static fromHeaders() function, which works exactly like DDTrace\consume_distributed_tracing_headers().
    
    Adding ddtrace_set_priority_sampling_on_root() as public for an interoperable way to set sampling priority from appsec.
    
    Signed-off-by: Bob Weinand <bob.weinand@datadoghq.com>
    bwoebi authored Oct 23, 2023
    Copy the full SHA
    721d938 View commit details
  3. Copy the full SHA
    08aa3c6 View commit details
  4. nice names

    realFlowControl committed Oct 23, 2023
    Copy the full SHA
    bd0e54f View commit details

Commits on Oct 24, 2023

  1. Add Magento 2 Integration (#2274)

    * Generate integration artifact
    
    * Add laminas deferred loading on Application::bootstrap
    
    * Start the magento integration (wip++)
    
    * Play with blocks
    
    * Revert "Play with blocks"
    
    This reverts commit 2013054.
    
    * Play with blocks
    
    * Load magento on Magento\Framework\Console\Cli::__construct
    
    * Remove some hooks
    
    * Trace events
    
    * Trace plugins
    
    * Comment-out plugins tracing
    
    * Add test framework
    
    * Update docker images with required PHP extensions
    
    * fix: install sodium for PHP 7.2+
    
    * fix: Install intl using pecl (7.0) and downgrade redis to 5.6
    
    * test: Add Magento 2.4 snapshots
    
    * fix: only install intl for php 7.1+
    
    * test: Add Magento 2.3 test framework + snapshots + installation instructions
    
    * fix: Manually set MySQL 5.6 as supported in Magento 2.4
    
    * test: Remove Magento 2.2 test framework (Notes)
    
    Notes: Too old; incompatibility with composer
    
    * test: Add ignored Core.php
    
    * fix: Give 777 permissions after magento installation
    
    * fix: Use sudo to set permissions
    
    * test: Ignore 'magento.block.cache_key'
    
    * test: Ignore 'meta.magento.block.cache_key'
    
    * feat: Use DD_HTTP_SERVER_ROUTE_BASED_NAMING
    
    * test: Update snapshots
    
    * test: Ignore exception if GD library is not installed
    
    * fix: Typo in the IntegrationsLoader
    
    * debug: error log nginx config file content
    
    * fix: typo
    
    * style: Remove semi-colon from magento.area.get if there is no area
    
    * style: Refactor using MagentoIntegration::getRealClass
    
    * test: General duplication refactor
    
    * debug: Check that the nginx process has started and is listening
    
    * debug: Add error log
    
    * debug: Remove error log
    
    * debug: Change nginx-default.conf
    
    * debug: Enable DD_TRACE_DEBUG in Laravel 9+ tests
    
    * style: lint
    
    * debug: Don't run magento tests
    
    * Revert "debug: Don't run magento tests"
    
    This reverts commit 461a7a5.
    
    * debug: Remove Magento 2.3 test framework
    
    * debug: Totally remove magento test suites
    
    * Revert "debug: Totally remove magento test suites"
    
    This reverts commit 8400073.
    
    * debug: Remove test files from Magento 2.4 test framework
    
    * Revert "debug: Remove Magento 2.3 test framework"
    
    This reverts commit b71e00c.
    
    * debug: Remove test files from Magento 2.3 test framework
    
    * debug: Remove non-necessary files from Magento 2.3 test framework
    
    * debug: Error log config content
    
    * debug: Use dirname
    
    * Revert "debug: Use dirname"
    
    This reverts commit 8d711de.
    
    * debug: Use the root path instead of a tmp dir
    
    * debug: Change the web test order
    
    * debug: Change the web test order
    
    * debug: Desperate attempts at this point
    
    * debug: Remove Magento Test Frameworks
    
    * Revert "debug: Remove Magento Test Frameworks"
    
    This reverts commit 605e881.
    
    * debug: Increase nginx error verbosity level to debug
    
    * test: Add a .env to Laravel 8x test framework
    
    * test: Add a .env to Laravel 8x test framework
    
    * test: Change the Laravel `.env` files
    
    * debug: Add debug logs to Laravel 8x
    
    * debug: Set open_basedir 🤷
    
    * debug: Remove open_basedir inis
    
    * debug: Remove test framekworks
    
    * debug: Change laravel .env
    
    * Revert "debug: Remove test framekworks"
    
    This reverts commit d9e9e40.
    
    * ✅ Add .env files to laravel test frameworks (9+)
    
    * 🔇 Remove debug logs
    
    * ✅ Add .env to Laravel 8 Tests
    
    * 🔧 Run the nette 24 test first
    
    * 🔧 Change Laravel 8 .env DB info
    
    * 🔧 Change Laravel 8 .env DB info
    
    * 🔧 Reorder tests
    
    * 🔨 Wait for nginx's process to start/terminate
    
    * 🔨 Use start instead of run
    
    * Increase nginx worker connections
    
    * Try to prevent nginx memory issues
    
    * Revert the test order changes
    
    Note: This workaround doesn't workaround
    
    * Play with nginx configurations
    
    * Play with nginx configurations
    
    * Remove .user.ini files
    
    * Remove the magento 2.3 test framework
    
    * Increase the memory limit when nginx server is used
    
    * Revert "Remove the magento 2.3 test framework"
    
    This reverts commit aaed36c.
    
    * zip it all
    
    * 💚 Add lstat_stat_variation15.phpt to 8.1 xfail list
    
    * ♻️ Clean before ready for review
    
    * ✨ Load symfony on commands
    
    * ✨ Load symfony on Magento cli
    
    * ✨ Trace CRON jobs and retrieve user id/email
    
    * 📸 Update Magento snapshots
    
    * ♻️ Refactor code
    
    * 🩹 Replace null coalescings with elvis operators
    
    * ✏️ Replace /home/circleci/app by /home/circleci/datadog
    
    * ✨ Restrict fullActionName resource name to non-cacheable pages
    
    * 📸 Update snapshots
    
    * ♻️ Refactor code
    
    * ✨ Retrieve order information
    
    * Add `magento.event.name` tag to `magento.event.execute` spans
    PROFeNoM authored Oct 24, 2023
    Copy the full SHA
    e89e687 View commit details
  2. Copy the full SHA
    7fd21cb View commit details

Commits on Oct 26, 2023

  1. Copy the full SHA
    9ea5dce View commit details
  2. Copy the full SHA
    e080247 View commit details
  3. Copy the full SHA
    2b2a1b7 View commit details
  4. Copy the full SHA
    d50f633 View commit details
  5. Copy the full SHA
    a9f8912 View commit details

Commits on Oct 27, 2023

  1. Copy the full SHA
    b3e798f View commit details
  2. Avoid %.*s in places where longer strings are used (#2330)

    Before php/php-src@e14fbc8 (i.e. PHP 8.1) strings provided with a max length were always truncated at 500 chars
    
    Co-authored-by: Florian Engelhardt <florian.engelhardt@datadoghq.com>
    bwoebi and realFlowControl authored Oct 27, 2023
    Copy the full SHA
    7354305 View commit details
  3. Add a configuration flag to disable laravel queue distributed tracing (

    …#2304)
    
    * ✨ Add DD_TRACE_LARAVEL_QUEUE_SPAN_LINKS
    
    * Log the serialized span links
    
    * debug: Nullify EG(exception) during span link generation
    
    * Cleanup everything
    
    * style: Change the configuration flag name to `DD_TRACE_LARAVEL_QUEUE_DISTRIBUTED_TRACING`
    
    * style: Remove debug options + indentation
    
    * fix: typo
    
    * test: Add a regression test
    
    * test: Add another regression test
    
    * fix: test formatting rules
    
    * fix: revert changes that shouldn't have been made
    
    * Simplify a condition
    
    * Use SpanLink::fromHeaders
    
    ---------
    
    Signed-off-by: Bob Weinand <bob.weinand@datadoghq.com>
    Co-authored-by: Bob Weinand <bob.weinand@datadoghq.com>
    PROFeNoM and bwoebi authored Oct 27, 2023
    Copy the full SHA
    7cd6cee View commit details
  4. Respect service mapping when propagating for DBM (#2321)

    Signed-off-by: Bob Weinand <bob.weinand@datadoghq.com>
    bwoebi authored Oct 27, 2023
    Copy the full SHA
    cfa0dea View commit details
  5. Laminas RESTful methods handling (#2322)

    * fix: Strictly check variable type (See Notes)
    
    Note: Fixes "Error thrown in ddtrace's closure defined at /opt/datadog-php/dd-trace-sources/bridge/_generated_integrations.php:4423 for Laminas\View\Renderer\JsonRenderer::render(): Call to a member function getTemplate() on array"
    
    * feat: Add error type as resource to `laminas.mvcEvent.setError` spans
    
    * style: Clean useless PR changes
    
    * feat: Trace RESTful methods and capture ApiProblem as errors
    
    * fix: Don't use obstart (too risky)
    
    * test: Add REST endpoints tests
    
    * test: Push phpunit.xml
    
    * fix: Handle absent Laminas Mvc Application
    
    * test: Set 755 permissions on data/cache dir post-autoload dump
    
    * test: Push data/cache/.gitkeep
    
    * test: Replace /home/circleci/app by /home/circleci/datadog
    
    * test: Run ApiTools tests for php 8.0+
    
    * test: Separate ApiTools tests from Laminas Framework Tests
    PROFeNoM authored Oct 27, 2023
    Copy the full SHA
    28edd30 View commit details
  6. Expand arrays in metrics into nested-tag format (#2333)

    * feat: Handle nested args in metrics array
    
    * fix: Mistake in Cmd+C, Cmd+V :)
    PROFeNoM authored Oct 27, 2023
    Copy the full SHA
    8e45577 View commit details

Commits on Oct 28, 2023

  1. Copy the full SHA
    66c276e View commit details
  2. Add release notes for 0.93.0 (#2337)

    Signed-off-by: Bob Weinand <bob.weinand@datadoghq.com>
    bwoebi authored Oct 28, 2023
    Copy the full SHA
    93664fd View commit details
Showing with 17,238 additions and 1,573 deletions.
  1. +126 −5 .circleci/continue_config.yml
  2. +9 −10 .github/workflows/prof_correctness.yml
  3. +2 −0 .gitlab-ci.yml
  4. +89 −0 .gitlab/ci-images.yml
  5. +213 −220 Cargo.lock
  6. +17 −1 Makefile
  7. +6 −1 benchmark/runall.sh
  8. +1 −0 bridge/_files_integrations.php
  9. +4 −0 components-rs/ddtrace.h
  10. +2 −1 components-rs/sidecar.h
  11. +16 −0 components-rs/telemetry.rs
  12. +4 −0 config.m4
  13. +1 −0 ddtrace.sym
  14. +6 −0 docker-compose.yml
  15. +16 −1 dockerfiles/ci/README.md
  16. +14 −0 dockerfiles/ci/alpine_compile_extension/docker-compose.yml
  17. +1 −0 dockerfiles/ci/buster/Dockerfile
  18. +3 −1 dockerfiles/ci/buster/build-extensions.sh
  19. +11 −0 dockerfiles/ci/buster/docker-compose.yml
  20. +88 −0 dockerfiles/ci/buster/php-8.3/Dockerfile
  21. +1 −0 dockerfiles/ci/buster/php-8.3/suppr.txt
  22. +1 −0 dockerfiles/ci/centos/7/base.Dockerfile
  23. +11 −0 dockerfiles/ci/centos/7/docker-compose.yml
  24. +49 −0 dockerfiles/ci/centos/7/php-8.3/configure.sh
  25. +1 −0 dockerfiles/ci/xfail_tests/8.1.list
  26. +178 −0 dockerfiles/ci/xfail_tests/8.3.list
  27. +1 −1 dockerfiles/ci/xfail_tests/README.md
  28. +4 −4 ext/compat_string.c
  29. +15 −3 ext/compatibility.h
  30. +2 −1 ext/configuration.h
  31. +280 −444 ext/ddtrace.c
  32. +4 −46 ext/ddtrace.h
  33. +61 −0 ext/ddtrace.stub.php
  34. +74 −1 ext/ddtrace_arginfo.h
  35. +400 −0 ext/distributed_tracing_headers.c
  36. +26 −0 ext/distributed_tracing_headers.h
  37. +4 −4 ext/handlers_exception.c
  38. +102 −74 ext/handlers_http.h
  39. +10 −4 ext/hook/uhook.c
  40. +11 −11 ext/hook/uhook_attributes.c
  41. +2 −2 ext/hook/uhook_legacy.c
  42. +8 −0 ext/integrations/integrations.c
  43. +1 −0 ext/integrations/integrations.h
  44. +33 −32 ext/priority_sampling/priority_sampling.c
  45. +5 −3 ext/priority_sampling/priority_sampling.h
  46. +4 −4 ext/random.c
  47. +322 −182 ext/serializer.c
  48. +2 −1 ext/serializer.h
  49. +75 −81 ext/span.c
  50. +80 −20 ext/span.h
  51. +19 −3 ext/telemetry.c
  52. +46 −40 ext/tracer_tag_propagation/tracer_tag_propagation.c
  53. +5 −4 ext/tracer_tag_propagation/tracer_tag_propagation.h
  54. +1 −1 ext/version.h
  55. +1 −1 libdatadog
  56. +35 −36 package.xml
  57. +3 −3 profiling/Cargo.toml
  58. +28 −0 profiling/benches/memory.json
  59. +8 −0 profiling/benches/timeline.php
  60. +40 −14 profiling/src/allocation.rs
  61. +19 −11 profiling/src/exception.rs
  62. +48 −30 profiling/src/lib.rs
  63. +1 −3 profiling/src/pcntl.rs
  64. +52 −53 profiling/src/profiling/mod.rs
  65. +6 −4 profiling/src/profiling/uploader.rs
  66. +46 −0 profiling/tests/phpt/exceptions_01.phpt
  67. +2 −0 profiling/tests/phpt/gc_mem_caches_01.phpt
  68. +35 −0 profiling/tests/phpt/gc_mem_caches_02.phpt
  69. +1 −1 src/DDTrace/Tracer.php
  70. +4 −0 src/Integrations/Integrations/DatabaseIntegrationHelper.php
  71. +3 −2 src/Integrations/Integrations/IntegrationsLoader.php
  72. +161 −10 src/Integrations/Integrations/Laminas/LaminasIntegration.php
  73. +17 −23 src/Integrations/Integrations/Laravel/LaravelIntegration.php
  74. +15 −10 src/Integrations/Integrations/LaravelQueue/LaravelQueueIntegration.php
  75. +708 −0 src/Integrations/Integrations/Magento/MagentoIntegration.php
  76. +20 −6 src/Integrations/Integrations/PDO/PDOIntegration.php
  77. +26 −0 src/Integrations/Integrations/PHPRedis/PHPRedisIntegration.php
  78. +21 −29 src/Integrations/Integrations/Predis/PredisIntegration.php
  79. +2 −0 tea/src/extension.c
  80. +16 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/.dockerignore
  81. +3 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/.gitattributes
  82. +9 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/.gitignore
  83. +8 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/.laminas-ci.json
  84. +1 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/COPYRIGHT.md
  85. +39 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/Dockerfile
  86. +26 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/LICENSE.md
  87. +268 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/README.md
  88. +59 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/Vagrantfile
  89. +93 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/composer.json
  90. +26 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/config/application.config.php
  91. +4 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/config/autoload/.gitignore
  92. +8 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/config/autoload/README.md
  93. +11 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/config/autoload/api-tools-config.global.php
  94. +20 −0 ...eworks/Laminas/ApiTools/Version_1_9/config/autoload/api-tools-mvc-auth-oauth2-override.global.php
  95. +18 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/config/autoload/global-development.php
  96. +14 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/config/autoload/global.php
  97. +15 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/config/autoload/local.php.dist
  98. +19 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/config/autoload/user.global.php
  99. +15 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/config/development.config.php.dist
  100. +35 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/config/modules.config.php
  101. 0 tests/Frameworks/Laminas/ApiTools/Version_1_9/data/cache/.gitkeep
  102. +10 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/docker-compose.yml
  103. +45 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/module/Application/config/module.config.php
  104. +26 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/module/Application/src/Controller/IndexController.php
  105. +16 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/module/Application/src/Module.php
  106. +54 −0 ...rameworks/Laminas/ApiTools/Version_1_9/module/Application/test/Controller/IndexControllerTest.php
  107. +51 −0 .../Laminas/ApiTools/Version_1_9/module/Application/test/Controller/ZZIndexControllerDevModeTest.php
  108. +11 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/module/Application/view/application/index/index.phtml
  109. +105 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/module/Application/view/error/404.phtml
  110. +57 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/module/Application/view/error/index.phtml
  111. +41 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/module/Application/view/layout/layout.phtml
  112. +23 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/module/DatadogApi/Module.php
  113. +84 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/module/DatadogApi/config/module.config.php
  114. +8 −0 ...ols/Version_1_9/module/DatadogApi/src/V1/Rest/DatadogRestService/DatadogRestServiceCollection.php
  115. +6 −0 ...piTools/Version_1_9/module/DatadogApi/src/V1/Rest/DatadogRestService/DatadogRestServiceEntity.php
  116. +116 −0 ...Tools/Version_1_9/module/DatadogApi/src/V1/Rest/DatadogRestService/DatadogRestServiceResource.php
  117. +10 −0 ...ersion_1_9/module/DatadogApi/src/V1/Rest/DatadogRestService/DatadogRestServiceResourceFactory.php
  118. +31 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/phpcs.xml.dist
  119. +13 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/phpunit.xml.dist
  120. +34 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/psalm-baseline.xml
  121. +37 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/psalm.xml.dist
  122. +4 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/public/.gitignore
  123. +18 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/public/.htaccess
  124. BIN tests/Frameworks/Laminas/ApiTools/Version_1_9/public/img/ag-hero.png
  125. BIN tests/Frameworks/Laminas/ApiTools/Version_1_9/public/img/favicon.png
  126. +60 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/public/index.php
  127. +26 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/public/web.config
  128. +7 −0 tests/Frameworks/Laminas/ApiTools/Version_1_9/src/ApiTools/constants.php
  129. +5 −5 tests/Frameworks/Laravel/Version_8_x/.env.example
  130. +44 −0 tests/Frameworks/Magento/README.md
  131. +373 −0 tests/Frameworks/Magento/Version_2_3/composer.json
  132. +21 −0 tests/Frameworks/Magento/Version_2_3/install-magento
  133. BIN tests/Frameworks/Magento/Version_2_3/magento.zip
  134. +412 −0 tests/Frameworks/Magento/Version_2_4/composer.json
  135. +23 −0 tests/Frameworks/Magento/Version_2_4/install-magento
  136. BIN tests/Frameworks/Magento/Version_2_4/magento.zip
  137. +5 −3 tests/Integration/DatabaseMonitoringTest.php
  138. +3 −1 tests/Integrations/Custom/Autoloaded/InstrumentationTest.php
  139. +58 −0 tests/Integrations/Laminas/ApiTools/V1_9/RESTTest.php
  140. +3 −7 tests/Integrations/Laravel/V5_8/QueueTest.php
  141. +1 −6 tests/Integrations/Laravel/V8_x/QueueTest.php
  142. +214 −0 tests/Integrations/Laravel/V8_x/QueueTestNotDistributed.php
  143. +11 −0 tests/Integrations/Magento/V2_3/CommonScenariosTest.php
  144. +78 −0 tests/Integrations/Magento/V2_4/CommonScenariosTest.php
  145. +1 −1 tests/Sapi/CliServer/CliServer.php
  146. +1 −0 tests/Unit/Integrations/IntegrationsLoaderTest.php
  147. +13 −1 tests/ext/active_span.phpt
  148. +66 −0 tests/ext/dd_trace_span_link_with_exception.phpt
  149. +2 −2 tests/ext/distributed_tracing/distributed_trace_bogus_ids.phpt
  150. +1 −1 tests/ext/distributed_tracing/distributed_trace_overwrite_active_span.phpt
  151. +27 −0 tests/ext/distributed_tracing/distributed_trace_span_link_from_headers.phpt
  152. +1 −7 tests/ext/inherit_meta_from_parent.phpt
  153. +53 −0 tests/ext/integrations/curl/distributed_tracing_curl_drop_dm.phpt
  154. +1 −1 tests/ext/integrations/curl/distributed_tracing_curl_sampling_priority.phpt
  155. +1 −1 tests/ext/priority_sampling/001-default-sampling.phpt
  156. +1 −1 tests/ext/priority_sampling/002-user-reject.phpt
  157. +1 −1 tests/ext/priority_sampling/003-user-keep.phpt
  158. +1 −1 tests/ext/root_span_url_with_query_params_obfuscation.phpt
  159. +55 −37 tests/ext/sandbox/safe_to_string_metadata.phpt
  160. +1 −1 tests/ext/sandbox/safe_to_string_metadata_drops_invalid_keys.phpt
  161. +108 −0 tests/ext/sandbox/safe_to_string_metrics.phpt
  162. +8 −8 tests/ext/sandbox/safe_to_string_properties.phpt
  163. +38 −6 tests/ext/sandbox/span_clone.phpt
  164. +2 −1 tests/ext/span_stack/span_stack_swap.phpt
  165. +2 −1 tests/ext/span_stack/span_trace_swap.phpt
  166. +3 −1 tests/ext/span_stack/start_span_new_trace.phpt
  167. +7 −1 tests/ext/telemetry/composer.phpt
  168. +16 −0 tests/ext/telemetry/simple.phpt
  169. +601 −0 tests/snapshots/tests.integrations.laminas.api_tools.v1_9.rest_test.test_scenario_rest2xx.json
  170. +413 −0 tests/snapshots/tests.integrations.laminas.api_tools.v1_9.rest_test.test_scenario_rest4xx.json
  171. +421 −0 tests/snapshots/tests.integrations.laminas.api_tools.v1_9.rest_test.test_scenario_rest5xx.json
  172. +1 −1 ...ots/tests.integrations.laminas.v1_4.common_scenarios_test.test_scenario_get_to_missing_route.json
  173. +1 −1 ...shots/tests.integrations.laminas.v1_4.common_scenarios_test.test_scenario_get_with_exception.json
  174. +1 −1 ...ots/tests.integrations.laminas.v2_0.common_scenarios_test.test_scenario_get_to_missing_route.json
  175. +1 −1 ...shots/tests.integrations.laminas.v2_0.common_scenarios_test.test_scenario_get_with_exception.json
  176. +316 −0 ...pshots/tests.integrations.magento.v2_3.common_scenarios_test.test_scenario_get_return_string.json
  177. +1,818 −0 ...ots/tests.integrations.magento.v2_3.common_scenarios_test.test_scenario_get_to_missing_route.json
  178. +301 −0 ...shots/tests.integrations.magento.v2_3.common_scenarios_test.test_scenario_get_with_exception.json
  179. +1,768 −0 .../snapshots/tests.integrations.magento.v2_3.common_scenarios_test.test_scenario_get_with_view.json
  180. +316 −0 ...pshots/tests.integrations.magento.v2_4.common_scenarios_test.test_scenario_get_return_string.json
  181. +2,013 −0 ...ots/tests.integrations.magento.v2_4.common_scenarios_test.test_scenario_get_to_missing_route.json
  182. +301 −0 ...shots/tests.integrations.magento.v2_4.common_scenarios_test.test_scenario_get_with_exception.json
  183. +1,846 −0 .../snapshots/tests.integrations.magento.v2_4.common_scenarios_test.test_scenario_get_with_view.json
  184. +2 −2 tooling/bin/generate-final-artifact.sh
  185. +29 −26 zend_abstract_interface/config/config_ini.c
  186. +35 −0 zend_abstract_interface/config/tests/ini.cc
  187. +15 −1 zend_abstract_interface/interceptor/php8/interceptor.c
  188. +9 −3 zend_abstract_interface/uri_normalization/uri_normalization.c
131 changes: 126 additions & 5 deletions .circleci/continue_config.yml
Original file line number Diff line number Diff line change
@@ -200,10 +200,10 @@ aliases:
echo "APM Test Agent is not running and was not used for testing. No checks failed."
exit 0
fi
RESPONSE=$(curl -s -w "\n%{http_code}" -o response.txt http://test-agent:9126/test/trace_check/failures)
RESPONSE_CODE=$(echo "$RESPONSE" | awk 'END {print $NF}')
if [[ $RESPONSE_CODE -eq 200 ]]; then
echo "All APM Test Agent Check Traces returned successful! (HTTP 200)"
echo "APM Test Agent Check Traces Summary Results:"
@@ -2458,6 +2458,7 @@ jobs:
# Add undocumented installer currently used by relenv
cp -v profiling/datadog-profiling-install.sh "datadog-profiling/${triplet}/bin/"
done
find
tar -czf "datadog-profiling.tar.gz" "datadog-profiling/"
- run:
name: Build packages
@@ -2647,6 +2648,7 @@ workflows:
- "8.0"
- "8.1"
- "8.2"
- "8.3"
cmake_version:
- "3.24.4"
catch2_version:
@@ -2760,6 +2762,17 @@ workflows:
abi_no: "20220829"
triplet: "aarch64-alpine-linux-musl"
resource_class: "arm.medium"
- "cargo build --release":
name: "Profiler PHP v8.3 - x86_64-alpine-linux-musl"
docker_image: "datadog/dd-trace-ci:php-compile-extension-alpine-8.3"
abi_no: "20230831"
triplet: "x86_64-alpine-linux-musl"
- "cargo build --release":
name: "Profiler PHP v8.3 - aarch64-alpine-linux-musl"
docker_image: "datadog/dd-trace-ci:php-compile-extension-alpine-8.3"
abi_no: "20230831"
triplet: "aarch64-alpine-linux-musl"
resource_class: "arm.medium"

- "cache cargo deps":
name: "cache cargo deps - x86_64-unknown-linux-gnu"
@@ -2847,6 +2860,17 @@ workflows:
abi_no: "20220829"
triplet: "aarch64-unknown-linux-gnu"
resource_class: "arm.medium"
- "cargo build --release":
name: "Profiler PHP v8.3 - x86_64-unknown-linux-gnu"
docker_image: "datadog/dd-trace-ci:php-8.3_centos-7"
abi_no: "20230831"
triplet: "x86_64-unknown-linux-gnu"
- "cargo build --release":
name: "Profiler PHP v8.3 - aarch64-unknown-linux-gnu"
docker_image: "datadog/dd-trace-ci:php-8.3_centos-7"
abi_no: "20230831"
triplet: "aarch64-unknown-linux-gnu"
resource_class: "arm.medium"

- compile_alpine:
requires: [ 'Prepare Code' ]
@@ -2861,6 +2885,7 @@ workflows:
- '8.0'
- '8.1'
- '8.2'
- '8.3'
resource_class:
- "medium"
- "arm.medium"
@@ -2970,6 +2995,19 @@ workflows:
php_version: "8.2"
so_suffix: "20220829"
resource_class: "arm.medium"
- compile_extension_centos:
requires: [ 'Prepare Code' ]
name: "Compile x86_64 PHP 83 nts + zts + debug"
docker_image: "datadog/dd-trace-ci:php-8.3_centos-7"
php_version: "8.3"
so_suffix: "20230831"
- compile_extension_centos:
requires: [ 'Prepare Code' ]
name: "Compile aarch64 PHP 83 nts + zts + debug"
docker_image: "datadog/dd-trace-ci:php-8.3_centos-7"
php_version: "8.3"
so_suffix: "20230831"
resource_class: "arm.medium"
- pecl_build:
requires: [ 'Prepare Code' ]
name: "Build PECL"
@@ -2993,6 +3031,8 @@ workflows:
- "Compile aarch64 PHP 81 nts + zts + debug"
- "Compile x86_64 PHP 82 nts + zts + debug"
- "Compile aarch64 PHP 82 nts + zts + debug"
- "Compile x86_64 PHP 83 nts + zts + debug"
- "Compile aarch64 PHP 83 nts + zts + debug"
- "Build PECL"

- "Profiler PHP v7.1 - x86_64-alpine-linux-musl"
@@ -3002,6 +3042,7 @@ workflows:
- "Profiler PHP v8.0 - x86_64-alpine-linux-musl"
- "Profiler PHP v8.1 - x86_64-alpine-linux-musl"
- "Profiler PHP v8.2 - x86_64-alpine-linux-musl"
- "Profiler PHP v8.3 - x86_64-alpine-linux-musl"

- "Profiler PHP v7.1 - x86_64-unknown-linux-gnu"
- "Profiler PHP v7.2 - x86_64-unknown-linux-gnu"
@@ -3010,6 +3051,7 @@ workflows:
- "Profiler PHP v8.0 - x86_64-unknown-linux-gnu"
- "Profiler PHP v8.1 - x86_64-unknown-linux-gnu"
- "Profiler PHP v8.2 - x86_64-unknown-linux-gnu"
- "Profiler PHP v8.3 - x86_64-unknown-linux-gnu"

- "Profiler PHP v7.1 - aarch64-alpine-linux-musl"
- "Profiler PHP v7.2 - aarch64-alpine-linux-musl"
@@ -3018,6 +3060,7 @@ workflows:
- "Profiler PHP v8.0 - aarch64-alpine-linux-musl"
- "Profiler PHP v8.1 - aarch64-alpine-linux-musl"
- "Profiler PHP v8.2 - aarch64-alpine-linux-musl"
- "Profiler PHP v8.3 - aarch64-alpine-linux-musl"

- "Profiler PHP v7.1 - aarch64-unknown-linux-gnu"
- "Profiler PHP v7.2 - aarch64-unknown-linux-gnu"
@@ -3026,6 +3069,7 @@ workflows:
- "Profiler PHP v8.0 - aarch64-unknown-linux-gnu"
- "Profiler PHP v8.1 - aarch64-unknown-linux-gnu"
- "Profiler PHP v8.2 - aarch64-unknown-linux-gnu"
- "Profiler PHP v8.3 - aarch64-unknown-linux-gnu"

- compile_extension_asan:
requires: [ 'Prepare Code' ]
@@ -3071,6 +3115,17 @@ workflows:
docker_image: "datadog/dd-trace-ci:php-8.2_buster"
so_suffix: "20220829"
resource_class: "arm.medium"
- compile_extension_asan:
requires: [ 'Prepare Code' ]
name: "Compile x86_64 PHP 83 debug-zts-asan"
docker_image: "datadog/dd-trace-ci:php-8.3_buster"
so_suffix: "20230831"
- compile_extension_asan:
requires: [ 'Prepare Code' ]
name: "Compile aarch64 PHP 83 debug-zts-asan"
docker_image: "datadog/dd-trace-ci:php-8.3_buster"
so_suffix: "20230831"
resource_class: "arm.medium"

- "package extension":
name: "package extension zts-debug-asan"
@@ -3084,6 +3139,8 @@ workflows:
- "Compile aarch64 PHP 81 debug-zts-asan"
- "Compile x86_64 PHP 82 debug-zts-asan"
- "Compile aarch64 PHP 82 debug-zts-asan"
- "Compile x86_64 PHP 83 debug-zts-asan"
- "Compile aarch64 PHP 83 debug-zts-asan"

- "x-profiling phpt tests on Alpine":
requires: [ 'package extension' ]
@@ -3097,6 +3154,7 @@ workflows:
- '8.0'
- '8.1'
- '8.2'
- '8.3'

- randomized_tests:
requires: [ 'package extension' ]
@@ -3207,6 +3265,7 @@ workflows:
- alpine:3.12
- alpine:3.15
- alpine:3.16
- alpine:3.17
- alpine:latest
- verify_alpine:
requires: [ "package extension" ]
@@ -3242,7 +3301,8 @@ workflows:
- php:7.4-fpm-alpine
- php:8.0-fpm-alpine
- php:8.1-fpm-alpine
- php:8.2-rc-fpm-alpine
- php:8.2-fpm-alpine
- php:8.3.0RC2-fpm-alpine
- verify_centos:
requires: [ "package extension" ]
matrix:
@@ -3261,6 +3321,7 @@ workflows:
- PHP_MAJOR=8 PHP_MINOR=0
- PHP_MAJOR=8 PHP_MINOR=1
- PHP_MAJOR=8 PHP_MINOR=2
# - PHP_MAJOR=8 PHP_MINOR=3
- verify_debian:
requires: [ "package extension" ]
matrix:
@@ -3282,6 +3343,7 @@ workflows:
- PHP_VERSION=8.0
- PHP_VERSION=8.1
- PHP_VERSION=8.2
# - PHP_VERSION=8.3

- verify_tar_gz:
requires: [ "package extension" ]
@@ -3330,6 +3392,11 @@ workflows:
requires: [ "Build PECL" ]
name: "PHP 82 PECL tests"
docker_image: "datadog/dd-trace-ci:php-8.2_buster"
- pecl_tests:
requires: [ "Build PECL" ]
name: "PHP 83 PECL tests"
docker_image: "datadog/dd-trace-ci:php-8.3_buster"

- integration_tests:
requires: [ 'Prepare Code' ]
name: "PHP 72 web tests with apache (+ opcache)"
@@ -3418,6 +3485,22 @@ workflows:
integration_testsuite: "test_web"
docker_image: "datadog/dd-trace-ci:php-8.2_buster"
php_major_minor: "8.2"
- integration_tests:
requires: [ 'Prepare Code' ]
name: "PHP 83 web tests with apache (+ opcache)"
resource_class: medium+
sapi: apache2handler
integration_testsuite: "test_web"
docker_image: "datadog/dd-trace-ci:php-8.3_buster"
php_major_minor: "8.3"
- integration_tests:
requires: [ 'Prepare Code' ]
name: "PHP 83 web tests with nginx + FastCGI"
resource_class: medium+
sapi: cgi-fcgi
integration_testsuite: "test_web"
docker_image: "datadog/dd-trace-ci:php-8.3_buster"
php_major_minor: "8.3"
- integration_tests:
requires: [ 'Prepare Code' ]
name: "PHP 74 custom autoloaded web tests with nginx + PHP-FPM"
@@ -3452,7 +3535,7 @@ workflows:
cd system-tests
export PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin
sudo apt-get install -y python-is-python3
./build.sh -i runner
./build.sh -i runner
run: |
cd system-tests
export PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin
@@ -3477,6 +3560,7 @@ workflows:
- "8.0"
- "8.1"
- "8.2"
- "8.3"
make_target:
- test_coverage
- test_extension_ci
@@ -3502,6 +3586,7 @@ workflows:
- "8.0"
- "8.1"
- "8.2"
- "8.3"
switch_php_version:
- debug-zts-asan

@@ -3518,6 +3603,7 @@ workflows:
- "8.0"
- "8.1"
- "8.2"
- "8.3"
make_target:
- test_coverage
- asan:
@@ -3529,6 +3615,7 @@ workflows:
- '8.0'
- '8.1'
- '8.2'
- '8.3'
switch_php_version:
- debug-zts-asan
resource_class:
@@ -3560,6 +3647,7 @@ workflows:
- '8.0'
- '8.1'
- '8.2'
- '8.3'
make_target:
- test_composer
- test_integration
@@ -3582,6 +3670,7 @@ workflows:
- '8.0'
- '8.1'
- '8.2'
- '8.3'
make_target:
- test_web

@@ -3601,6 +3690,7 @@ workflows:
- '8.0'
- '8.1'
- '8.2'
- '8.3'
make_target:
- test_distributed_tracing

@@ -3618,6 +3708,7 @@ workflows:
- '8.0'
- '8.1'
- '8.2'
- '8.3'
switch_php_version:
- nts
make_target:
@@ -3670,10 +3761,22 @@ workflows:
requires: [ 'Prepare Code' ]
name: "PHP 82 Xdebug tests"
docker_image: "datadog/dd-trace-ci:php-8.2_buster"
xdebug_version_one: "3.2.0RC1"
xdebug_version_one: "3.2.2"
- xdebug_tests:
requires: [ 'Prepare Code' ]
name: "PHP 83 Xdebug tests"
docker_image: "datadog/dd-trace-ci:php-8.3_buster"
xdebug_version_one: "3.3.0alpha2"

- placeholder:
requires: [ 'Prepare Code' ]
name: Language tests

- php_language_tests:
requires: [ 'Language tests' ]
name: "PHP 83 language tests"
xfail_list: dockerfiles/ci/xfail_tests/8.3.list
docker_image: "datadog/dd-trace-ci:php-8.3_buster"
- php_language_tests:
requires: [ 'Language tests' ]
name: "PHP 82 language tests"
@@ -3806,6 +3909,15 @@ workflows:
docker_image: "datadog/dd-trace-ci:php-compile-extension-alpine-8.2"
triplet: "aarch64-alpine-linux-musl"
resource_class: "arm.medium"
- "profiling tests":
name: "Profiler test PHP v8.3 - x86_64-alpine-linux-musl"
docker_image: "datadog/dd-trace-ci:php-compile-extension-alpine-8.3"
triplet: "x86_64-alpine-linux-musl"
- "profiling tests":
name: "Profiler test PHP v8.3 - aarch64-alpine-linux-musl"
docker_image: "datadog/dd-trace-ci:php-compile-extension-alpine-8.3"
triplet: "aarch64-alpine-linux-musl"
resource_class: "arm.medium"

- "profiling tests":
name: "Profiler test PHP v7.1 - x86_64-unknown-linux-gnu"
@@ -3870,3 +3982,12 @@ workflows:
docker_image: "datadog/dd-trace-ci:php-8.2_centos-7"
triplet: "aarch64-unknown-linux-gnu"
resource_class: "arm.medium"
- "profiling tests":
name: "Profiler test PHP v8.3 - x86_64-unknown-linux-gnu"
docker_image: "datadog/dd-trace-ci:php-8.3_centos-7"
triplet: "x86_64-unknown-linux-gnu"
- "profiling tests":
name: "Profiler test PHP v8.3 - aarch64-unknown-linux-gnu"
docker_image: "datadog/dd-trace-ci:php-8.3_centos-7"
triplet: "aarch64-unknown-linux-gnu"
resource_class: "arm.medium"
19 changes: 9 additions & 10 deletions .github/workflows/prof_correctness.yml
Original file line number Diff line number Diff line change
@@ -58,17 +58,16 @@ jobs:
- name: Run tests
run: |
export DD_PROFILING_LOG_LEVEL=trace
export DD_PROFILING_EXPERIMENTAL_TIMELINE_ENABLED=1
export DD_PROFILING_EXPERIMENTAL_EXCEPTION_ENABLED=1
export DD_PROFILING_EXPERIMENTAL_EXCEPTION_SAMPLING_DISTANCE=1
php -d extension=target/release/libdatadog_php_profiling.so -v
mkdir profiling/tests/correctness/allocations/
DD_PROFILING_OUTPUT_PPROF=$PWD/profiling/tests/correctness/allocations/test.pprof php -d extension=$PWD/target/release/libdatadog_php_profiling.so profiling/tests/correctness/allocations.php
mkdir profiling/tests/correctness/time/
DD_PROFILING_OUTPUT_PPROF=$PWD/profiling/tests/correctness/time/test.pprof php -d extension=$PWD/target/release/libdatadog_php_profiling.so profiling/tests/correctness/time.php
mkdir profiling/tests/correctness/strange_frames/
DD_PROFILING_OUTPUT_PPROF=$PWD/profiling/tests/correctness/strange_frames/test.pprof php -d extension=$PWD/target/release/libdatadog_php_profiling.so profiling/tests/correctness/strange_frames.php
mkdir profiling/tests/correctness/timeline/
DD_PROFILING_OUTPUT_PPROF=$PWD/profiling/tests/correctness/timeline/test.pprof DD_PROFILING_EXPERIMENTAL_TIMELINE_ENABLED=1 php -d extension=$PWD/target/release/libdatadog_php_profiling.so profiling/tests/correctness/timeline.php
mkdir profiling/tests/correctness/exceptions/
DD_PROFILING_OUTPUT_PPROF=$PWD/profiling/tests/correctness/exceptions/test.pprof php -d extension=$PWD/target/release/libdatadog_php_profiling.so -d datadog.profiling.experimental_exception_sampling_distance=1 -d datadog.profiling.experimental_exception_enabled=On profiling/tests/correctness/exceptions.php
for test_case in "allocations" "time" "strange_frames" "timeline" "exceptions"; do
mkdir -p profiling/tests/correctness/"$test_case"/
export DD_PROFILING_OUTPUT_PPROF=$PWD/profiling/tests/correctness/"$test_case"/test.pprof
php -d extension=$PWD/target/release/libdatadog_php_profiling.so profiling/tests/correctness/"$test_case".php
lz4 -d --rm "$DD_PROFILING_OUTPUT_PPROF".1.lz4 "$DD_PROFILING_OUTPUT_PPROF"
done
- name: Check profiler correctness for allocations
uses: Datadog/prof-correctness/analyze@main
Loading