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

Preparing php 7.4 #24

Merged
merged 1 commit into from
Nov 17, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
59 changes: 54 additions & 5 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -314,6 +314,9 @@ jobs:
xfail_list:
type: string
default: none
php_src_dir:
type: string
default: /usr/src/php
working_directory: ~/datadog
environment:
DDAGENT_HOSTNAME: 127.0.0.1
Expand All @@ -329,15 +332,17 @@ jobs:
- run:
name: Run tests
command: |
mkdir -p <<parameters.php_src_dir>>
docker-php-source extract
if [[ ! "<<parameters.xfail_list>>" == "none" ]]; then
cp "<<parameters.xfail_list>>" /usr/src/php/xfail_tests.list
cp "<<parameters.xfail_list>>" <<parameters.php_src_dir>>/xfail_tests.list
(
cd /usr/src/php
cat xfail_tests.list | xargs -n 1 sed -i -e $'s/\(--FILE.*--\)/--XFAIL--\\\nvar_dump missmatch\\\n\\1/g'
cd <<parameters.php_src_dir>>
cat xfail_tests.list | xargs -n 1 grep -L '\-\-SKIPIF\-\-' | xargs -n 1 -r sed -i -e $'s/\(--FILE.*--\)/--SKIPIF--\\\n\\1/g' || true
cat xfail_tests.list | xargs -n 1 sed -i -e $'s/\(--SKIPIF--\)/\\1\\\nskip Unreliable output or flaky test/g'
)
fi
cd /usr/src/php
cd <<parameters.php_src_dir>>
export SIGNALFX_TRACING_CLI_ENABLED=true
export REPORT_EXIT_STATUS=1
export TEST_PHP_JUNIT=/tmp/artifacts/tests/php-tests.xml
Expand All @@ -348,7 +353,7 @@ jobs:
-d ddtrace.request_init_hook=/home/circleci/datadog/bridge/dd_wrap_autoloader.php
- run:
command: |
cd /usr/src/php
cd <<parameters.php_src_dir>>
mkdir -p /tmp/artifacts/core_dumps
find ./ -name "core.*" | xargs -I % -n 1 cp % /tmp/artifacts/core_dumps
when: on_fail
Expand Down Expand Up @@ -583,6 +588,12 @@ workflows:
lib_curl_command: yum -y install libcurl-devel
docker_image: "datadog/docker-library:ddtrace_centos_7_php_73"
so_suffix: "20180731"
- compile_extension:
requires: [ 'Code Checkout' ]
name: "Compile PHP 74"
lib_curl_command: yum -y install libcurl-devel
docker_image: "datadog/dd-trace-ci:php-7.4-centos-7"
so_suffix: "20190902"
- compile_extension:
requires: [ 'Code Checkout' ]
name: "Compile PHP 56-zts"
Expand Down Expand Up @@ -613,6 +624,12 @@ workflows:
docker_image: "circleci/php:7.3-zts"
lib_curl_command: sudo apt update; sudo apt -y install libcurl4-nss-dev
so_suffix: "20180731-zts"
- compile_extension:
requires: [ 'Code Checkout' ]
name: "Compile PHP 74-zts"
docker_image: "circleci/php:7.4-zts"
lib_curl_command: sudo apt update; sudo apt -y install libcurl4-nss-dev
so_suffix: "20190902-zts"
- "package extension":
requires:
- "Compile PHP 54"
Expand All @@ -621,11 +638,13 @@ workflows:
- "Compile PHP 71"
- "Compile PHP 72"
- "Compile PHP 73"
- "Compile PHP 74"
- "Compile PHP 56-zts"
- "Compile PHP 70-zts"
- "Compile PHP 71-zts"
- "Compile PHP 72-zts"
- "Compile PHP 73-zts"
- "Compile PHP 74-zts"
- "package verification":
requires:
- "package extension"
Expand Down Expand Up @@ -695,6 +714,18 @@ workflows:
name: "PHP 73 language tests"
xfail_list: dockerfiles/ci/xfail_tests/7.3.list
docker_image: "datadog/dd-trace-php:7.3-buster-debug"
- unit_tests:
requires: [ 'Code Checkout' ]
name: "PHP 74 Unit tests"
docker_image: "datadog/dd-trace-ci:php-7.4-debug-alpine-3.11"
valgrind_config: 7_4_musl
lib_curl_command: sudo apk update ; sudo apk add curl-dev
- php_language_tests:
requires: [ 'Language tests' ]
name: "PHP 74 language tests"
xfail_list: dockerfiles/ci/xfail_tests/7.4.list
docker_image: "datadog/dd-trace-ci:php-7.4-debug-buster"
php_src_dir: "/usr/local/src/php"
- php_language_tests:
requires: [ 'Language tests' ]
name: "PHP 72 language tests"
Expand Down Expand Up @@ -756,6 +787,12 @@ workflows:
integration_testsuite: "test-integrations-73"
docker_image: "datadog/docker-library:ddtrace_alpine_php-7.3-debug"
lib_curl_command: sudo apk update ; sudo apk add curl-dev
- integration_tests:
requires: [ 'Code Checkout' ]
name: "PHP 74 Integration tests"
integration_testsuite: "test-integrations-74"
docker_image: "datadog/dd-trace-ci:php-7.4-debug-alpine-3.11"
lib_curl_command: sudo apk update ; sudo apk add curl-dev
- integration_tests:
requires: [ 'Code Checkout' ]
name: "PHP 54 Web integration tests"
Expand Down Expand Up @@ -793,6 +830,13 @@ workflows:
integration_testsuite: "test-web-73"
docker_image: "datadog/docker-library:ddtrace_alpine_php-7.3-debug"
lib_curl_command: sudo apk update ; sudo apk add curl-dev
- integration_tests:
requires: [ 'Code Checkout' ]
name: "PHP 74 Web integration tests"
resource_class: medium+
integration_testsuite: "test-web-74"
docker_image: "datadog/dd-trace-ci:php-dev-7.4"
lib_curl_command: sudo apt update ; sudo apt-get -y install libcurl4-nss-dev
- hyperfine_tests:
requires: [ 'Code Checkout' ]
name: "Hyperfine 54 benchmarks"
Expand Down Expand Up @@ -823,6 +867,11 @@ workflows:
name: "Hyperfine 73 benchmarks"
docker_image: "datadog/docker-library:ddtrace_alpine_php-7.3-debug"
lib_curl_command: sudo apk update ; sudo apk add curl-dev
- hyperfine_tests:
requires: [ 'Code Checkout' ]
name: "Hyperfine 74 benchmarks"
docker_image: "datadog/dd-trace-ci:php-7.4-debug-alpine-3.11"
lib_curl_command: sudo apk update ; sudo apk add curl-dev
- "Lint files":
requires: [ 'Code Checkout' ]
- "Static Analysis":
Expand Down
3 changes: 3 additions & 0 deletions .circleci/valgrind/7_4_musl_valgrind.rc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
--suppressions=/home/circleci/valgrind_7_4_musl_suppressions.lib
--gen-suppressions=all
--leak-check=full
146 changes: 146 additions & 0 deletions .circleci/valgrind/valgrind_7_4_musl_suppressions.lib
Original file line number Diff line number Diff line change
@@ -0,0 +1,146 @@
{
<insert_a_suppression_name_here>
Memcheck:Free
fun:free
obj:/lib/ld-musl-x86_64.so.1
}
{
<insert_a_suppression_name_here>
Memcheck:Cond
fun:strlcpy
obj:*
obj:*
obj:*
obj:*
obj:*
obj:*
obj:*
obj:*
}
{
<insert_a_suppression_name_here>
Memcheck:Cond
fun:strlcpy
obj:*
obj:*
obj:*
obj:*
obj:*
obj:*
obj:*
obj:*
fun:zend_hash_find_bucket
obj:*
obj:*
}
{
php_zend_string_equal_val false positive due to handcrafted assembly
Memcheck:Cond
fun:zend_string_equal_val
}
{
<insert_a_suppression_name_here>
Memcheck:Cond
fun:memcmp
fun:__putenv
obj:*
obj:*
obj:*
fun:vgMemCheck_new_block
obj:*
obj:*
obj:*
obj:*
fun:do_cli
obj:*
}
{
<insert_a_suppression_name_here>
Memcheck:Cond
fun:memcmp
fun:unsetenv
obj:*
obj:*
obj:*
obj:*
fun:do_cli
obj:*
obj:*
fun:unsetenv
obj:*
obj:*
}
{
<insert_a_suppression_name_here>
Memcheck:Cond
fun:strlcpy
obj:*
obj:*
}
{
<leaks on exit opcode>
Memcheck:Leak
match-leak-kinds: definite
fun:malloc
fun:__zend_malloc
fun:_emalloc
fun:zend_compile
fun:compile_file
fun:phar_compile_file
fun:_dd_compile_file
fun:zend_execute_scripts
fun:php_execute_script
fun:do_cli
fun:main
}
{
<leaks on exit opcode>
Memcheck:Leak
match-leak-kinds: definite
fun:malloc
fun:__zend_malloc
obj:*
fun:_emalloc
obj:*
fun:compile_file
obj:*
fun:_dd_compile_file
fun:zend_execute_scripts
fun:php_execute_script
obj:*
obj:*
}
{
<leaks on exit from auto_prepend_file>
Memcheck:Leak
match-leak-kinds: definite
fun:malloc
fun:__zend_malloc
obj:*
fun:_emalloc
obj:*
fun:compile_file
obj:*
fun:_dd_compile_file
fun:zend_execute_scripts
fun:dd_execute_auto_prepend_file
fun:zif_ddtrace_init
obj:*
}
{
<leaks on exit from auto_prepend_file>
Memcheck:Leak
match-leak-kinds: definite
fun:malloc
fun:__zend_malloc
obj:*
fun:_emalloc
obj:*
obj:*
fun:php_execute_script
obj:*
obj:*
obj:/lib/ld-musl-x86_64.so.1
obj:*
obj:*
}
37 changes: 37 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,22 @@
"@composer test -- tests/Integrations/Predis",
"@composer scenario default"
],
"test-integrations-74": [
"sh clean-composer-scenario-locks.sh",
"@composer scenario:update",
"@composer scenario default",
"@composer test -- tests/Integrations/Curl",
"@composer test -- tests/Integrations/Memcached",
"@composer test -- tests/Integrations/Mysqli",
"@composer test -- tests/Integrations/PDO",
"@composer scenario guzzle5",
"@composer test -- tests/Integrations/Guzzle/V5",
"@composer scenario guzzle6",
"@composer test -- tests/Integrations/Guzzle/V6",
"@composer scenario predis1",
"@composer test -- tests/Integrations/Predis",
"@composer scenario default"
],
"test-web-54": [
"@cakephp-28-update",
"@cakephp-28-test",
Expand Down Expand Up @@ -312,6 +328,27 @@
"@zend-framework-1-test",
"@custom-framework-autoloaded-suite"
],
"test-web-74": [
"@laravel-57-update",
"@laravel-57-test",
"@laravel-58-update",
"@laravel-58-test",
"@lumen-52-update",
"@lumen-52-test",
"@lumen-56-update",
"@lumen-56-test",
"@lumen-58-update",
"@lumen-58-test",
"@slim-312-update",
"@slim-312-test",
"@symfony-40-suite",
"@symfony-42-suite",
"@wordpress-48-test",
"@yii-2-suite",
"@zend-framework-1-test",
"@custom-framework-autoloaded-suite",
"@opentracing-10-test"
],

"inrease-memory-limit": "export COMPOSER_MEMORY_LIMIT=-1",
"memory_test": "echo $COMPOSER_MEMORY_LIMIT",
Expand Down
2 changes: 2 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,8 @@ services:
'7.3-debug': { <<: *base_php_service, image: 'pawelchcki/ddtrace_php:7.3-stretch-debug' }
'7.3-zts-debug': { <<: *base_php_service, image: 'datadog/docker-library:ddtrace_alpine_php-7.3-zts-debug' }
'7.3-zts': { <<: *base_php_service, image: 'datadog/docker-library:ddtrace_alpine_php-7.3-zts' }
'7.4-debug-buster': { <<: *base_php_service, image: 'datadog/dd-trace-ci:php-7.4-debug-buster' }
'7.4-debug': { <<: *base_php_service, image: 'datadog/dd-trace-ci:php-7.4-debug-alpine-3.11' }
'ubuntu-16.04-7.1': { <<: *base_php_service, build: 'dockerfiles/ubuntu-16.04-php-7.1' }
'ubuntu-18.04-7.2': { <<: *base_php_service, build: 'dockerfiles/ubuntu-18.04-php-7.2' }
'fpm': { <<: *base_php_service, image: 'circleci/ruby:2.5', depends_on: [] }
Expand Down
Loading