Skip to content
Closed
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
28 changes: 21 additions & 7 deletions manifests/php.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1765,12 +1765,22 @@ manifest:
- weblog_declaration:
laravel11x: incomplete_test_app
symfony7x: incomplete_test_app
tests/test_baggage.py::Test_Baggage_Headers_Basic: incomplete_test_app (/make_distant_call endpoint is not correctly implemented)
tests/test_baggage.py::Test_Baggage_Headers_Malformed: incomplete_test_app (/make_distant_call endpoint is not correctly implemented)
tests/test_baggage.py::Test_Baggage_Headers_Malformed2: incomplete_test_app (/make_distant_call endpoint is not correctly implemented)
tests/test_baggage.py::Test_Baggage_Headers_Basic:
- declaration: incomplete_test_app (/make_distant_call endpoint is not correctly implemented)
excluded_weblog: [laravel11x]
tests/test_baggage.py::Test_Baggage_Headers_Malformed:
- declaration: incomplete_test_app (/make_distant_call endpoint is not correctly implemented)
excluded_weblog: [laravel11x]
tests/test_baggage.py::Test_Baggage_Headers_Malformed2:
- declaration: incomplete_test_app (/make_distant_call endpoint is not correctly implemented)
excluded_weblog: [laravel11x]
tests/test_baggage.py::Test_Baggage_Headers_Max_Bytes: incomplete_test_app (/make_distant_call endpoint is not correctly implemented)
tests/test_baggage.py::Test_Baggage_Headers_Max_Items: incomplete_test_app (/make_distant_call endpoint is not correctly implemented)
tests/test_baggage.py::Test_Only_Baggage_Header: incomplete_test_app (/make_distant_call endpoint is not correctly implemented)
tests/test_baggage.py::Test_Baggage_Headers_Max_Items:
- declaration: incomplete_test_app (/make_distant_call endpoint is not correctly implemented)
excluded_weblog: [laravel11x]
tests/test_baggage.py::Test_Only_Baggage_Header:
- declaration: incomplete_test_app (/make_distant_call endpoint is not correctly implemented)
excluded_weblog: [laravel11x]
tests/test_config_consistency.py::Test_Config_ClientIPHeaderEnabled_False: v1.5.1
tests/test_config_consistency.py::Test_Config_ClientIPHeader_Configured: v1.4.0
tests/test_config_consistency.py::Test_Config_ClientIPHeader_Precedence: v1.4.0
Expand Down Expand Up @@ -1822,7 +1832,9 @@ manifest:
tests/test_identify.py::Test_Propagate_Legacy: v0.85.0
tests/test_library_conf.py::Test_ExtractBehavior_Default: missing_feature (default extract behavior does not create a span link for conflicting/terminated trace contexts)
tests/test_library_conf.py::Test_ExtractBehavior_Default::test_single_tracecontext: v1.17.0
tests/test_library_conf.py::Test_ExtractBehavior_Ignore: incomplete_test_app (/make_distant_call endpoint is not correctly implemented)
tests/test_library_conf.py::Test_ExtractBehavior_Ignore:
- declaration: incomplete_test_app (/make_distant_call endpoint is not correctly implemented)
excluded_weblog: [laravel11x]
tests/test_library_conf.py::Test_ExtractBehavior_Restart: v1.24.0
tests/test_library_conf.py::Test_ExtractBehavior_Restart_Otel:
- weblog_declaration:
Expand All @@ -1834,7 +1846,9 @@ manifest:
php-fpm-8.1: v1.24.0
php-fpm-8.2: v1.24.0
php-fpm-8.5: v1.24.0
tests/test_library_conf.py::Test_ExtractBehavior_Restart_With_Extract_First: incomplete_test_app (/make_distant_call endpoint is not correctly implemented)
tests/test_library_conf.py::Test_ExtractBehavior_Restart_With_Extract_First:
- declaration: incomplete_test_app (/make_distant_call endpoint is not correctly implemented)
excluded_weblog: [laravel11x]
tests/test_library_conf.py::Test_HeaderTags: v0.68.2
tests/test_library_conf.py::Test_HeaderTags_Colon_Leading: v0.74.0
tests/test_library_conf.py::Test_HeaderTags_Colon_Trailing: v0.74.0
Expand Down
27 changes: 21 additions & 6 deletions utils/build/docker/php/weblogs/laravel11x/routes/web.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,13 +89,28 @@
return response()->json(['error' => 'url parameter required'], 400);
}

$debugStream = fopen('php://temp', 'w+');
$response = Http::withOptions(['debug' => $debugStream])->get($url);

rewind($debugStream);
$debug = stream_get_contents($debugStream);
fclose($debugStream);

$requestHeaders = [];
$response = Http::beforeSending(function ($outgoingRequest) use (&$requestHeaders) {
foreach ($outgoingRequest->headers() as $name => $values) {
$requestHeaders[strtolower($name)] = implode(', ', $values);
}
})
->get($url);
$inRequest = false;
foreach (explode("\n", $debug) as $line) {
$line = rtrim($line);
if (str_starts_with($line, '> ')) {
$inRequest = true;
$line = substr($line, 2);
} elseif ($inRequest && (str_starts_with($line, '< ') || $line === '')) {
break;
}
if ($inRequest && str_contains($line, ':')) {
[$key, $value] = explode(':', $line, 2);
$requestHeaders[strtolower(trim($key))] = trim($value);
}
}

$responseHeaders = [];
foreach ($response->headers() as $name => $values) {
Expand Down