We recently moved our infra to K8s, and since I have issue to get Traces of my Exceptions
We're on Symfony 3.4, and my Exception traces only gaves me web/app.php
, but not root cause
Error: Call to a member function send() on null
#0 web/app.php(19): null
app.php is classic Symfony file, nothing relevent inside:
$kernel = new AppKernel('prod', false);
$request = Request::createFromGlobals();
$response = $kernel->handle($request);
$response->send();
$kernel->terminate($request, $response);
I tried to connect my localhost to my production DB, to see if I had the same issue, but no. I have correct full trace of my Exception
If I try in production with "app_dev.php" (which I enabled only for this test), I have same issue with no trace
Do you know what could cause this issue?
A PHP configuration? I checked differences between php -i
on previous infra & new one, but I don't see any relevant difference
Edit:
Monolog in config.yml
:
monolog:
handlers:
main:
type: rotating_file
max_files: 10
path: '%kernel.logs_dir%/%kernel.environment%.general.log'
level: INFO
formatter: myapp.monolog.formatter.json_message
Edit 2: We bring part of old infra alive. And here the difference : Old infra, for Fatal Errors, we have the full trace: On new infra, same fatal error is displayed without any more detail
CodePudding user response:
The issue seems to comes from datadog agent that we added on our new infra.
Edit: Issue has been fixed in https://github.com/DataDog/dd-trace-php/releases/tag/0.79.0