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

Enable CLI by default #2871

Merged
merged 3 commits into from
Oct 3, 2024
Merged
Show file tree
Hide file tree
Changes from 2 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
5 changes: 1 addition & 4 deletions .circleci/continue_config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -836,7 +836,6 @@ jobs:
name: Run xdebug tests
command: |
export REPORT_EXIT_STATUS=1
export DD_TRACE_CLI_ENABLED=1
targetdir() {
if [[ ${1:0:1} -eq 2 ]]; then
echo $1
Expand Down Expand Up @@ -1154,7 +1153,7 @@ jobs:
name: Set test environment variables
shell: powershell.exe
command: |
docker exec php powershell.exe 'setx DD_AUTOLOAD_NO_COMPILE true; setx DD_TRACE_CLI_ENABLED 1; setx DATADOG_HAVE_DEV_ENV 1; setx DD_TRACE_GIT_METADATA_ENABLED 0'
docker exec php powershell.exe 'setx DD_AUTOLOAD_NO_COMPILE true; setx DATADOG_HAVE_DEV_ENV 1; setx DD_TRACE_GIT_METADATA_ENABLED 0'
- run:
name: Run extension tests
shell: powershell.exe
Expand Down Expand Up @@ -1843,7 +1842,6 @@ jobs:
)
fi
cd /usr/local/src/php
export DD_TRACE_CLI_ENABLED=true
export DD_TRACE_STARTUP_LOGS=0
export DD_TRACE_WARN_CALL_STACK_DEPTH=0
export DD_TRACE_WARN_LEGACY_DD_TRACE=0
Expand Down Expand Up @@ -2584,7 +2582,6 @@ jobs:
TERM=dumb \
HTTPBIN_HOSTNAME=${HTTPBIN_HOSTNAME} \
DATADOG_HAVE_DEV_ENV=1 \
DD_TRACE_CLI_ENABLED=1 \
DD_TRACE_GIT_METADATA_ENABLED=0 \
pecl run-tests <<# parameters.showdiff >> --showdiff <</ parameters.showdiff >> --ini=" -d datadog.trace.sources_path=" -p datadog_trace
- run:
Expand Down
15 changes: 6 additions & 9 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -153,10 +153,10 @@ install_appsec:
install_all: install install_ini

run_tests: $(TEST_FILES) $(TEST_STUB_FILES) $(BUILD_DIR)/run-tests.php
DD_TRACE_CLI_ENABLED=1 DD_TRACE_GIT_METADATA_ENABLED=0 $(RUN_TESTS_CMD) $(TESTS)
DD_TRACE_GIT_METADATA_ENABLED=0 $(RUN_TESTS_CMD) $(TESTS)

test_c: $(SO_FILE) $(TEST_FILES) $(TEST_STUB_FILES) $(BUILD_DIR)/run-tests.php
$(if $(ASAN), USE_ZEND_ALLOC=0 USE_TRACKED_ALLOC=1) DD_TRACE_CLI_ENABLED=1 DD_TRACE_GIT_METADATA_ENABLED=0 $(RUN_TESTS_CMD) -d extension=$(SO_FILE) $(BUILD_DIR)/$(subst $(BUILD_DIR_NAME)/,,$(TESTS))
$(if $(ASAN), USE_ZEND_ALLOC=0 USE_TRACKED_ALLOC=1) DD_TRACE_GIT_METADATA_ENABLED=0 $(RUN_TESTS_CMD) -d extension=$(SO_FILE) $(BUILD_DIR)/$(subst $(BUILD_DIR_NAME)/,,$(TESTS))

test_c_coverage: dist_clean
DD_TRACE_DOCKER_DEBUG=1 EXTRA_CFLAGS="-fprofile-arcs -ftest-coverage" $(MAKE) test_c || exit 0
Expand All @@ -168,12 +168,11 @@ test_c_disabled: $(SO_FILE) $(TEST_FILES) $(TEST_STUB_FILES) $(BUILD_DIR)/run-te
)

test_c_observer: $(SO_FILE) $(TEST_FILES) $(TEST_STUB_FILES) $(BUILD_DIR)/run-tests.php
$(if $(ASAN), USE_ZEND_ALLOC=0 USE_TRACKED_ALLOC=1) DD_TRACE_CLI_ENABLED=1 DD_TRACE_GIT_METADATA_ENABLED=0 $(RUN_TESTS_CMD) -d extension=$(SO_FILE) -d extension=zend_test.so -d zend_test.observer.enabled=1 -d zend_test.observer.observe_all=1 -d zend_test.observer.show_output=0 $(BUILD_DIR)/$(TESTS)
$(if $(ASAN), USE_ZEND_ALLOC=0 USE_TRACKED_ALLOC=1) DD_TRACE_GIT_METADATA_ENABLED=0 $(RUN_TESTS_CMD) -d extension=$(SO_FILE) -d extension=zend_test.so -d zend_test.observer.enabled=1 -d zend_test.observer.observe_all=1 -d zend_test.observer.show_output=0 $(BUILD_DIR)/$(TESTS)

test_opcache: $(SO_FILE) $(TEST_OPCACHE_FILES) $(BUILD_DIR)/run-tests.php
$(if $(ASAN), USE_ZEND_ALLOC=0 USE_TRACKED_ALLOC=1) DD_TRACE_CLI_ENABLED=1 $(RUN_TESTS_CMD) -d extension=$(SO_FILE) -d zend_extension=opcache.so $(BUILD_DIR)/tests/opcache
$(if $(ASAN), USE_ZEND_ALLOC=0 USE_TRACKED_ALLOC=1) $(RUN_TESTS_CMD) -d extension=$(SO_FILE) -d zend_extension=opcache.so $(BUILD_DIR)/tests/opcache

test_c_mem: export DD_TRACE_CLI_ENABLED=1
test_c_mem: $(SO_FILE) $(TEST_FILES) $(TEST_STUB_FILES) $(BUILD_DIR)/run-tests.php
$(RUN_TESTS_CMD) -d extension=$(SO_FILE) -m $(BUILD_DIR)/$(TESTS)

Expand All @@ -182,21 +181,19 @@ test_c2php: $(SO_FILE) $(INIT_HOOK_TEST_FILES) $(BUILD_DIR)/run-tests.php
set -xe; \
export PATH="$(PROJECT_ROOT)/tests/ext/valgrind:$$PATH"; \
sed -i 's/stream_socket_accept($$listenSock, 5)/stream_socket_accept($$listenSock, 20)/' $(BUILD_DIR)/run-tests.php; \
export DD_TRACE_CLI_ENABLED=1; \
export USE_ZEND_ALLOC=0; \
export ZEND_DONT_UNLOAD_MODULES=1; \
export USE_TRACKED_ALLOC=1; \
$(shell grep -Pzo '(?<=--ENV--)(?s).+?(?=--)' $(INIT_HOOK_TEST_FILES)) valgrind -q --tool=memcheck --trace-children=yes --vex-iropt-register-updates=allregs-at-mem-access bash -c '$(RUN_TESTS_CMD) -d extension=$(SO_FILE) -d datadog.trace.sources_path=$(TRACER_SOURCE_DIR) -d pcre.jit=0 $(INIT_HOOK_TEST_FILES)'; \
)

test_with_init_hook: $(SO_FILE) $(INIT_HOOK_TEST_FILES) $(BUILD_DIR)/run-tests.php
$(if $(ASAN), USE_ZEND_ALLOC=0 USE_TRACKED_ALLOC=1) DD_TRACE_CLI_ENABLED=1 $(RUN_TESTS_CMD) -d extension=$(SO_FILE) -d datadog.trace.sources_path=$(TRACER_SOURCE_DIR) $(INIT_HOOK_TEST_FILES);
$(if $(ASAN), USE_ZEND_ALLOC=0 USE_TRACKED_ALLOC=1) $(RUN_TESTS_CMD) -d extension=$(SO_FILE) -d datadog.trace.sources_path=$(TRACER_SOURCE_DIR) $(INIT_HOOK_TEST_FILES);

test_extension_ci: $(SO_FILE) $(TEST_FILES) $(TEST_STUB_FILES) $(BUILD_DIR)/run-tests.php
( \
set -xe; \
export PATH="$(PROJECT_ROOT)/tests/ext/valgrind:$$PATH"; \
export DD_TRACE_CLI_ENABLED=1; \
export TEST_PHP_JUNIT=$(JUNIT_RESULTS_DIR)/normal-extension-test.xml; \
export DD_TRACE_GIT_METADATA_ENABLED=0; \
$(RUN_TESTS_CMD) -d extension=$(SO_FILE) $(BUILD_DIR)/$(TESTS); \
Expand Down Expand Up @@ -519,7 +516,7 @@ cores:
# TESTS
########################################################################################################################
TRACER_SOURCES_INI := -d datadog.trace.sources_path=$(TRACER_SOURCE_DIR)
ENV_OVERRIDE := $(shell [ -n "${DD_TRACE_DOCKER_DEBUG}" ] && echo DD_AUTOLOAD_NO_COMPILE=true DD_TRACE_SOURCES_PATH=$(TRACER_SOURCE_DIR)) DD_DOGSTATSD_URL=http://request-replayer:80 DD_TRACE_CLI_ENABLED=true DD_TRACE_GIT_METADATA_ENABLED=false
ENV_OVERRIDE := $(shell [ -n "${DD_TRACE_DOCKER_DEBUG}" ] && echo DD_AUTOLOAD_NO_COMPILE=true DD_TRACE_SOURCES_PATH=$(TRACER_SOURCE_DIR)) DD_DOGSTATSD_URL=http://request-replayer:80 DD_TRACE_GIT_METADATA_ENABLED=false
TEST_EXTRA_INI ?=
TEST_EXTRA_ENV ?=

Expand Down
1 change: 0 additions & 1 deletion appsec/cmake/run-tests-wrapper.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ export NO_INTERACTION=1
export DD_TRACE_ENABLED=true
#export DD_TRACE_DEBUG=true
export DD_TRACE_GENERATE_ROOT_SPAN=true
export DD_TRACE_CLI_ENABLED=true
export DD_TRACE_AGENT_PORT=18126
export PHPRC=

Expand Down
2 changes: 0 additions & 2 deletions dockerfiles/frameworks/contrib/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,5 @@
if [[ -z "$NO_DDTRACE" ]]; then
curl -o /tmp/ddtrace.deb http://nginx_file_server/ddtrace.deb
dpkg -i /tmp/ddtrace.deb

export DD_TRACE_CLI_ENABLED=true
fi
exec "$@"
4 changes: 2 additions & 2 deletions dockerfiles/frameworks/contrib/phpredis/3.1.6/run.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/bin/bash -xe

switch_php 7.3
DD_TRACE_CLI_ENABLED=true php ./tests/TestRedis.php --host ${REDIS_HOST} --class Redis
DD_TRACE_CLI_ENABLED=true php ./tests/TestRedis.php --host ${REDIS_HOST} --class RedisArray
php ./tests/TestRedis.php --host ${REDIS_HOST} --class Redis
php ./tests/TestRedis.php --host ${REDIS_HOST} --class RedisArray
4 changes: 2 additions & 2 deletions dockerfiles/frameworks/contrib/phpredis/4.3.0/run.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/bin/bash -xe

switch_php 7.3
DD_TRACE_CLI_ENABLED=true php ./tests/TestRedis.php --host ${REDIS_HOST} --class Redis
DD_TRACE_CLI_ENABLED=true php ./tests/TestRedis.php --host ${REDIS_HOST} --class RedisArray
php ./tests/TestRedis.php --host ${REDIS_HOST} --class Redis
php ./tests/TestRedis.php --host ${REDIS_HOST} --class RedisArray
4 changes: 2 additions & 2 deletions dockerfiles/frameworks/contrib/phpredis/5.3.1/run.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/bin/bash -xe

switch_php 7.3
DD_TRACE_CLI_ENABLED=true php ./tests/TestRedis.php --host ${REDIS_HOST} --class Redis
DD_TRACE_CLI_ENABLED=true php ./tests/TestRedis.php --host ${REDIS_HOST} --class RedisArray
php ./tests/TestRedis.php --host ${REDIS_HOST} --class Redis
php ./tests/TestRedis.php --host ${REDIS_HOST} --class RedisArray
2 changes: 0 additions & 2 deletions dockerfiles/release-candidates/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,11 @@ x-base-php-service:
tty: true
environment:
- DD_AGENT_HOST=ddagent
- DD_TRACE_CLI_ENABLED=1
- DD_TRACE_DEBUG=1
- DD_TRACE_STARTUP_LOGS=0
- DD_ENV=testing # Should take priority over DD_TAGS=env:localhost
- DD_TAGS=env:localhost,foo.tag:custom
- DD_SERVICE=rc-${PHP_FPM_CONTAINER:-testing-service} # Will emmit deprecated diagnostic
#- DD_TRACE_AUTO_FLUSH_ENABLED=1
#- DD_TRACE_GENERATE_ROOT_SPAN=0
cap_add:
- SYS_PTRACE
Expand Down
2 changes: 1 addition & 1 deletion dockerfiles/verify_packages/verify.sh
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ fi
echo "PHP version: $(${DD_TRACE_PHP_BIN} -v)"

# Script output
CLI_OUTPUT=$(DD_TRACE_CLI_ENABLED=true ${DD_TRACE_PHP_BIN} /var/www/html/index.php)
CLI_OUTPUT=$(${DD_TRACE_PHP_BIN} /var/www/html/index.php)
if [ "${CLI_OUTPUT}" != "hi" ]; then
echo "Error: expected request output is 'hi'. Actual:\n${APACHE_OUTPUT}"
exit 1
Expand Down
4 changes: 1 addition & 3 deletions examples/long-running/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,5 @@ RUN dpkg -i /tmp/dd-trace-php.deb

WORKDIR /app

CMD DD_TRACE_CLI_ENABLED=true \
DD_TRACE_AUTO_FLUSH_ENABLED=true \
DD_TRACE_GENERATE_ROOT_SPAN=false \
CMD DD_TRACE_GENERATE_ROOT_SPAN=false \
php long-running-script.php
4 changes: 4 additions & 0 deletions ext/configuration.c
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,10 @@ static void dd_ini_env_to_ini_name(const zai_str env_name, zai_config_name *ini_
}

bool ddtrace_config_minit(int module_number) {
if (ddtrace_active_sapi == DATADOG_PHP_SAPI_CLI) {
config_entries[DDTRACE_CONFIG_DD_TRACE_AUTO_FLUSH_ENABLED].default_encoded_value = (zai_str) ZAI_STR_FROM_CSTR("true");
}

if (!zai_config_minit(config_entries, (sizeof config_entries / sizeof *config_entries), dd_ini_env_to_ini_name,
module_number)) {
ddtrace_log_ginit();
Expand Down
4 changes: 2 additions & 2 deletions ext/configuration.h
Original file line number Diff line number Diff line change
Expand Up @@ -118,8 +118,8 @@ enum ddtrace_sampling_rules_format {
CONFIG(INT, DD_TRACE_AGENT_PORT, "0", .ini_change = zai_config_system_ini_change) \
CONFIG(BOOL, DD_TRACE_ANALYTICS_ENABLED, "false") \
CONFIG(BOOL, DD_TRACE_APPEND_TRACE_IDS_TO_LOGS, "false") \
CONFIG(BOOL, DD_TRACE_AUTO_FLUSH_ENABLED, "false") \
CONFIG(BOOL, DD_TRACE_CLI_ENABLED, "false") \
CONFIG(BOOL, DD_TRACE_AUTO_FLUSH_ENABLED, "false") /* true in CLI */ \
CONFIG(BOOL, DD_TRACE_CLI_ENABLED, "true") \
CONFIG(BOOL, DD_TRACE_MEASURE_COMPILE_TIME, "true") \
CONFIG(BOOL, DD_TRACE_MEASURE_PEAK_MEMORY_USAGE, "true") \
CONFIG(BOOL, DD_TRACE_DEBUG, "false", .ini_change = ddtrace_alter_dd_trace_debug) \
Expand Down
19 changes: 17 additions & 2 deletions ext/ddtrace.c
Original file line number Diff line number Diff line change
Expand Up @@ -453,6 +453,13 @@ static void dd_activate_once(void) {

static pthread_once_t dd_activate_once_control = PTHREAD_ONCE_INIT;

static bool dd_is_cli_autodisabled(const char *arg) {
const char *slashend = strrchr(arg, '/');
const char *backslashend = strrchr(arg, '\\');
arg = MAX(MAX(slashend, backslashend) + 1, arg);
return strcmp(arg, "composer") == 0 || strcmp(arg, "composer.phar") == 0;
}

static void ddtrace_activate(void) {
ddog_reset_logger();

Expand Down Expand Up @@ -482,8 +489,16 @@ static void ddtrace_activate(void) {
dd_save_sampling_rules_file_config(sampling_rules_file, PHP_INI_USER, PHP_INI_STAGE_RUNTIME);
}

if (!ddtrace_disable && strcmp(sapi_module.name, "cli") == 0 && !get_DD_TRACE_CLI_ENABLED()) {
ddtrace_disable = 2;
if (!ddtrace_disable && strcmp(sapi_module.name, "cli") == 0) {
if (zai_config_memoized_entries[DDTRACE_CONFIG_DD_TRACE_CLI_ENABLED].name_index < 0 && SG(request_info).argv && dd_is_cli_autodisabled(SG(request_info).argv[0])) {
zend_string *zero = zend_string_init("0", 1, 0);
zend_alter_ini_entry(zai_config_memoized_entries[DDTRACE_CONFIG_DD_TRACE_CLI_ENABLED].ini_entries[0]->name, zero,
ZEND_INI_USER, ZEND_INI_STAGE_RUNTIME);
zend_string_release(zero);
}
if (!get_DD_TRACE_CLI_ENABLED()) {
ddtrace_disable = 2;
}
}

if (ddtrace_disable) {
Expand Down
4 changes: 2 additions & 2 deletions loader/tests/functional/test_ddtrace_is_fully_loaded.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
require_once __DIR__."/includes/autoload.php";
skip_if_php5();

$output = runCLI(__DIR__.'/fixtures/ddtrace.php');
$output = runCLI('-ddatadog.trace.cli_enabled=0 '.__DIR__.'/fixtures/ddtrace.php');
assertEquals($output, <<<EOS
foo
using passthru
Expand All @@ -13,7 +13,7 @@
EOS
);

$output = runCLI('-ddatadog.trace.cli_enabled=1 '.__DIR__.'/fixtures/ddtrace.php');
$output = runCLI(__DIR__.'/fixtures/ddtrace.php');
assertMatchesFormat($output, <<<EOS
foo
using passthru
Expand Down
2 changes: 1 addition & 1 deletion tests/Common/CLITestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,12 @@ abstract protected function getScriptLocation();
protected static function getEnvs()
{
$envs = [
'DD_TRACE_CLI_ENABLED' => 'true',
'DD_AGENT_HOST' => 'test-agent',
'DD_TRACE_AGENT_PORT' => '9126',
// Uncomment to see debug-level messages
'DD_TRACE_DEBUG' => 'true',
'DD_TEST_INTEGRATION' => 'true',
'DD_TRACE_AUTO_FLUSH_ENABLED' => 'false',
'DD_TRACE_EXEC_ENABLED' => 'false',
'DD_TRACE_SHUTDOWN_TIMEOUT' => '666666', // Arbitrarily high value to avoid flakiness
'DD_TRACE_AGENT_RETRIES' => '3',
Expand Down
1 change: 0 additions & 1 deletion tests/Common/TracerTestTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,6 @@ public function executeCli($scriptPath, $customEnvs = [], $customInis = [], $arg
$envs = (string) new EnvSerializer(array_merge(
[
'DD_AUTOLOAD_NO_COMPILE' => getenv('DD_AUTOLOAD_NO_COMPILE'),
'DD_TRACE_CLI_ENABLED' => 'true',
'DD_AGENT_HOST' => 'test-agent',
'DD_TRACE_AGENT_PORT' => '9126',
// Uncomment to see debug-level messages
Expand Down
2 changes: 2 additions & 0 deletions tests/bootstrap_phpunit.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,5 @@
require __DIR__ . '/bootstrap_common.php';

require_once __DIR__ . '/Appsec/Mock.php';

ini_set("datadog.trace.auto_flush_enabled", "false");
1 change: 1 addition & 0 deletions tests/ext/autoload-php-files/dd_init_open_basedir.phpt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
--TEST--
Calling dd_init.php is confined to open_basedir settings
--ENV--
DD_TRACE_AUTO_FLUSH_ENABLED=0
DD_TRACE_LOG_LEVEL=info,startup=off,datadog_sidecar=off
DD_AUTOLOAD_NO_COMPILE=1
--INI--
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
--TEST--
Errors in ddtrace autoloader do not affect error_get_last()
--ENV--
DD_TRACE_AUTO_FLUSH_ENABLED=0
DD_TRACE_LOG_LEVEL=info,startup=off
DD_AUTOLOAD_NO_COMPILE=1
--INI--
Expand Down
1 change: 1 addition & 0 deletions tests/ext/autoload-php-files/file_not_found.phpt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
--TEST--
Do not fail when PHP code couldn't be loaded
--ENV--
DD_TRACE_AUTO_FLUSH_ENABLED=0
DD_TRACE_LOG_LEVEL=info,startup=off
DD_AUTOLOAD_NO_COMPILE=1
--INI--
Expand Down
1 change: 1 addition & 0 deletions tests/ext/autoload-php-files/ignores_exceptions.phpt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
--TEST--
Request init hook ignores exceptions
--ENV--
DD_TRACE_AUTO_FLUSH_ENABLED=0
DD_TRACE_LOG_LEVEL=info,startup=off
DD_AUTOLOAD_NO_COMPILE=1
--INI--
Expand Down
1 change: 1 addition & 0 deletions tests/ext/autoload-php-files/ignores_fatal_errors.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ Request init hook ignores fatal errors
--SKIPIF--
<?php if (getenv('USE_ZEND_ALLOC') === '0') die('skip Zend MM must be enabled'); ?>
--ENV--
DD_TRACE_AUTO_FLUSH_ENABLED=0
DD_TRACE_LOG_LEVEL=info,startup=off
DD_AUTOLOAD_NO_COMPILE=1
--INI--
Expand Down
1 change: 0 additions & 1 deletion tests/ext/background-sender/agent_headers.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ DD_TRACE_AGENT_FLUSH_AFTER_N_REQUESTS=1
DD_TRACE_AGENT_FLUSH_INTERVAL=666
DD_TRACE_GENERATE_ROOT_SPAN=0
DD_INSTRUMENTATION_TELEMETRY_ENABLED=0
DD_TRACE_AUTO_FLUSH_ENABLED=1
--INI--
datadog.trace.agent_test_session_token=background-sender/agent_headers
--FILE--
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ DD_TRACE_AGENT_FLUSH_AFTER_N_REQUESTS=1
DD_TRACE_AGENT_FLUSH_INTERVAL=666
DD_TRACE_GENERATE_ROOT_SPAN=0
DD_INSTRUMENTATION_TELEMETRY_ENABLED=0
DD_TRACE_AUTO_FLUSH_ENABLED=1
--INI--
ddtrace.cgroup_file={PWD}/stubs/cgroup.docker
datadog.trace.agent_test_session_token=background-sender/agent_headers_container_id
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ DD_TRACE_AGENT_FLUSH_AFTER_N_REQUESTS=1
DD_TRACE_AGENT_FLUSH_INTERVAL=333
DD_TRACE_GENERATE_ROOT_SPAN=0
DD_INSTRUMENTATION_TELEMETRY_ENABLED=0
DD_TRACE_AUTO_FLUSH_ENABLED=1
--INI--
ddtrace.cgroup_file={PWD}/stubs/cgroup.empty
datadog.trace.agent_test_session_token=background-sender/agent_headers_container_id_empty
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ DD_TRACE_AGENT_FLUSH_AFTER_N_REQUESTS=1
DD_TRACE_AGENT_FLUSH_INTERVAL=333
DD_TRACE_GENERATE_ROOT_SPAN=0
DD_INSTRUMENTATION_TELEMETRY_ENABLED=0
DD_TRACE_AUTO_FLUSH_ENABLED=1
--INI--
ddtrace.cgroup_file={PWD}/stubs/cgroup.fargate.1.4
datadog.trace.agent_test_session_token=background-sender/agent_headers_container_id_fargate
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ DD_TRACE_AGENT_FLUSH_AFTER_N_REQUESTS=1
DD_TRACE_AGENT_FLUSH_INTERVAL=333
DD_TRACE_GENERATE_ROOT_SPAN=0
DD_INSTRUMENTATION_TELEMETRY_ENABLED=0
DD_TRACE_AUTO_FLUSH_ENABLED=1
DD_REMOTE_CONFIG_ENABLED=0
--INI--
datadog.trace.agent_test_session_token=background-sender/agent_headers_unix_domain_socket
Expand Down
1 change: 0 additions & 1 deletion tests/ext/background-sender/agent_sampling.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ DD_TRACE_AGENT_FLUSH_INTERVAL=333
DD_TRACE_GENERATE_ROOT_SPAN=0
DD_INSTRUMENTATION_TELEMETRY_ENABLED=0
DD_TRACE_SIDECAR_TRACE_SENDER=0
DD_TRACE_AUTO_FLUSH_ENABLED=1
--INI--
datadog.trace.agent_test_session_token=background-sender/agent_sampling
--FILE--
Expand Down
1 change: 0 additions & 1 deletion tests/ext/background-sender/agent_sampling_sidecar.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ DD_TRACE_AGENT_FLUSH_INTERVAL=333
DD_TRACE_GENERATE_ROOT_SPAN=0
DD_INSTRUMENTATION_TELEMETRY_ENABLED=0
DD_TRACE_SIDECAR_TRACE_SENDER=1
DD_TRACE_AUTO_FLUSH_ENABLED=1
--INI--
datadog.trace.agent_test_session_token=background-sender/agent_sampling_sidecar
--FILE--
Expand Down
1 change: 1 addition & 0 deletions tests/ext/close_spans_until.phpt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
--TEST--
Test DDTrace\close_spans_until
--ENV--
DD_TRACE_AUTO_FLUSH_ENABLED=0
DD_TRACE_LOG_LEVEL=info,span=trace,startup=off
--FILE--
<?php
Expand Down
1 change: 1 addition & 0 deletions tests/ext/dd_trace_serialize_msgpack_error.phpt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
--TEST--
dd_trace_serialize_msgpack() error conditions
--ENV--
DD_TRACE_AUTO_FLUSH_ENABLED=0
DD_TRACE_LOG_LEVEL=info,startup=off
--FILE--
<?php
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
--TEST--
Transmit distributed header information to spans
--ENV--
DD_TRACE_AUTO_FLUSH_ENABLED=0
HTTP_X_DATADOG_TRACE_ID=foo
HTTP_X_DATADOG_PARENT_ID=bar
HTTP_X_DATADOG_ORIGIN=datadog
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
--TEST--
Transmit distributed header information to spans
--ENV--
DD_TRACE_AUTO_FLUSH_ENABLED=0
HTTP_X_DATADOG_TRACE_ID=42
HTTP_X_DATADOG_PARENT_ID=10
HTTP_X_DATADOG_ORIGIN=datadog
Expand Down
Loading
Loading