DataDog / dd-trace-php

Datadog PHP Clients
https://docs.datadoghq.com/tracing/setup/php
Other
490 stars 152 forks source link

[Bug]: laravel.request traces/operations no longer being reported #2252

Closed Magic-Mayo closed 1 year ago

Magic-Mayo commented 1 year ago

Bug report

After updating to the latest release, 0.91.0, we longer see any laravel.request operations in APM. At the same time we now see a few different eloquent (eloquent.get, eloquent.update, etc.) operations coming thru where we had never seen them before. We have a few different apps that are all exhibiting the same behavior and for now we are just pinning to the previous release as we seem to still get laravel.request traces on 0.90.0.

PHP version

8.1.17,8.0.30

Tracer or profiler version

0.91.0

Installed extensions

No response

Output of phpinfo()

No response

Upgrading from

0.90.0

luizeduardocostaml commented 1 year ago

It's happening here too in my applications. It's only recognizing database operations.

PROFeNoM commented 1 year ago

Hi 👋

What version of Laravel are you using?

When setting DD_TRACE_DEBUG=1, do you see an exception? Otherwise, when receiving a request, do you see any Loaded integration DDTrace\\Integrations\\Laravel\\LaravelIntegration in the first place?

Magic-Mayo commented 1 year ago

I will go check all the versions we're using across the apps that were affected and report back. We haven't changed anything with our process on how the datadog trace library is installed and run ( very basically - download the datadog-setup.php script from this repo and run it ). I can also add the env var to a test run and see if any errors come up.

Magic-Mayo commented 1 year ago

Versions 9.52.12, 10.7.1, 9.37.0, 8.83.27 are the versions of the apps I can confirm were affected. ~The one that was running 9.37.0 is still not showing traces so I am going to start troubleshooting with that app first.~ It is showing traces, they just didn't pull in our fix until yesterday and I wasn't including it in my search.

aolol commented 1 year ago

Hi 👋 In our case when setting DD_TRACE_DEBUG=1 no new errors can be seen, but I notice that the new version created a new service under APM, but with a different icon and the name instead of group.service it's just service. The original group.service name contains the resources and traces before the update and the one with the new service name service contains the resources and traces after the update. (0.86.0 => 0.91.0)

PROFeNoM commented 1 year ago

Hi everyone :wave:

Thanks for these additional details 💎 There was indeed a mistake introduced in the last release. Could any of you please try out this artifact (CI Job - Related PR)?

With this, the service name should now be appropriately retrieved if available 😃 Please let me know if it addresses the issue :+1:

FYI, to install the artifact, if you followed the extension installation doc, simply change the URL of the official installer by the URL of the artifact and you're good to go 👍

Magic-Mayo commented 1 year ago

I will get this tested out and report back to you. Thanks for getting something in so quickly!

Magic-Mayo commented 1 year ago

Looks like it works with that artifact!

PROFeNoM commented 1 year ago

Hey there :wave: The latest release - 0.91.2 - includes the fix :+1: