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

XHProf profiler for laravel #23

Closed
webard opened this issue Mar 19, 2023 · 6 comments
Closed

XHProf profiler for laravel #23

webard opened this issue Mar 19, 2023 · 6 comments

Comments

@webard
Copy link

webard commented Mar 19, 2023

Hello,
is it possible to combine the xhrof viewer with laravel?

@webard webard changed the title XHProf profiler for laravel #13 XHProf profiler for laravel Mar 19, 2023
@butschster butschster added the help wanted Extra attention is needed label Apr 25, 2023
@butschster butschster self-assigned this Apr 25, 2023
@butschster
Copy link
Member

Hello.

Yes, you can use the Profiler package to integrate XHProf profiler with your Laravel application.

To bind the Profiler classes into the Laravel container, you can refer to the example in the ProfilerBootloader.php file. This example demonstrates how to bootstrap the Profiler and bind it to the Laravel container.
I hope this helps! Let me know if you have any further questions.

@maantje
Copy link

maantje commented Oct 18, 2023

Created a basic repo to kick off Laravel support. Check it out here. It's functional, but still a work in progress. Your input is welcome! 🛠️

@butschster
Copy link
Member

Created a basic repo to kick off Laravel support. Check it out here. It's functional, but still a work in progress. Your input is welcome! 🛠️

Hi @maantje

Thx for the package. I've added it to the project readme!

@maantje
Copy link

maantje commented Oct 18, 2023

Hey @butschster,

It's great to know that the package found its way into the project readme.

I've just rolled out a new release that automatically registers the middleware but also introduces support for toggling the profiler using a header, similar to the spiral/profiler package.

I noticed that the "Using buggregator with Docker Compose" section in the project readme is incomplete for Laravel. To make it work with Sail, make sure to add it to the sail network. Without this step, the framework won't be able to establish a connection with the server.

services:
    # ...

    buggregator:
        image: ghcr.io/buggregator/server:dev
        ports:
            - 8000:8000
            - 1025:1025
            - 9912:9912
            - 9913:9913
     networks:
         - sail

Thank you for the effort you put into this; I'm really enjoying using it!

@butschster
Copy link
Member

13:9913
networks:
- sail

It would be great if you create a PR with instruction for Laravel in readme!

@butschster
Copy link
Member

Instruction can be found here https://docs.buggregator.dev/config/xhprof.html#laravel

Thx @maantje!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

No branches or pull requests

3 participants