Skip to content

feat: Enhance Laravel auto-instrumentation #336

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

Draft
wants to merge 23 commits into
base: main
Choose a base branch
from

Conversation

cedricziel
Copy link
Contributor

@cedricziel cedricziel commented Mar 26, 2025

This PR improves the Laravel auto-instrumentation with several key enhancements:

  • Add controller method instrumentation for better request tracing
  • Improve view rendering instrumentation with exception handling
  • Add event debugging capabilities
  • Fix middleware instrumentation to prevent double-hooking
  • Enhance HTTP client and request tracing
  • Improve span naming and protocol handling
  • Add helper methods for trace structure assessment
  • Various bug fixes and code style improvements

The changes focus on making the Laravel instrumentation more robust and providing better observability into Laravel applications.

Copy link

codecov bot commented Mar 26, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 81.35%. Comparing base (ea137c0) to head (558ca93).

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff              @@
##               main     #336      +/-   ##
============================================
+ Coverage     79.45%   81.35%   +1.90%     
+ Complexity     1772     1631     -141     
============================================
  Files           137      113      -24     
  Lines          7568     6704     -864     
============================================
- Hits           6013     5454     -559     
+ Misses         1555     1250     -305     
Flag Coverage Δ
Aws 92.24% <ø> (ø)
Context/Swoole 0.00% <ø> (ø)
Instrumentation/CakePHP 20.27% <ø> (ø)
Instrumentation/CodeIgniter 73.77% <ø> (ø)
Instrumentation/Curl 90.42% <ø> (ø)
Instrumentation/Doctrine 93.25% <ø> (ø)
Instrumentation/ExtAmqp 89.26% <ø> (ø)
Instrumentation/ExtRdKafka 86.23% <ø> (ø)
Instrumentation/Guzzle 69.51% <ø> (ø)
Instrumentation/HttpAsyncClient 78.31% <ø> (ø)
Instrumentation/IO 70.68% <ø> (ø)
Instrumentation/Laravel ?
Instrumentation/MongoDB 74.28% <ø> (ø)
Instrumentation/MySqli 95.81% <ø> (ø)
Instrumentation/OpenAIPHP 87.31% <ø> (ø)
Instrumentation/PDO 90.15% <ø> (ø)
Instrumentation/Psr14 77.14% <ø> (ø)
Instrumentation/Psr15 89.41% <ø> (ø)
Instrumentation/Psr16 97.56% <ø> (ø)
Instrumentation/Psr18 77.77% <ø> (ø)
Instrumentation/Psr3 59.49% <ø> (ø)
Instrumentation/Psr6 97.67% <ø> (ø)
Instrumentation/Slim 86.30% <ø> (ø)
Instrumentation/Symfony 84.93% <ø> (ø)
Instrumentation/Yii 77.68% <ø> (ø)
Logs/Monolog 100.00% <ø> (ø)
Propagation/ServerTiming ?
Propagation/TraceResponse 100.00% <100.00%> (ø)
ResourceDetectors/Azure 91.66% <ø> (ø)
ResourceDetectors/Container 93.02% <ø> (ø)
Sampler/RuleBased 33.51% <ø> (ø)
Shims/OpenTracing 92.45% <ø> (ø)
Symfony 87.81% <ø> (ø)
Utils/Test 70.49% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
...tion/TraceResponse/src/TraceResponsePropagator.php 100.00% <100.00%> (ø)

... and 24 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ea137c0...558ca93. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@cedricziel cedricziel changed the title feat: Enhance Laravel instrumentation feat: Enhance Laravel auto-instrumentation Mar 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant