roxblnfk / yiigregator
Buggregator integration for Yii
Fund package maintenance!
Patreon
Requires
- php: >=8.1
- psr/http-server-middleware: ^1.0
- spiral-packages/profiler: ^1.2
Requires (Dev)
- buggregator/trap: ^1.9
This package is auto-updated.
Last update: 2024-11-13 18:19:07 UTC
README
Integration package for Buggregator with Yii.
Installation
Install the package via composer:
composer require roxblnfk/yiigregator
If you use Yii with composer-config-plugin
, the package might be configured via environment variables only.
Usage
Profiling
- Add the
Roxblnfk\Yiigregator\Middleware\ProfilerMiddleware
middleware to the top of the middlewares list (possibly in the$params['middlewares']
). - Turn on the profiler and set the Buggregator endpoint using environment variables:
PROFILER_ENABLED=true PROFILER_ENDPOINT=http://127.0.0.1:8000/api/profiler/store
Note
http://127.0.0.1:8000/api/profiler/store
is the default value for the Buggregator endpoint.
Note
Depending on your environment, you may need to set the PROFILER_ENDPOINT
to a different value.
For example, if you are using Docker, you may need to set it to http://buggregator:8000/api/profiler/store
.
By default, XHProf is used for profiling. Make sure it is installed and enabled in your PHP configuration.
License
Yiigregator is open-sourced software licensed under the BSD-3 license.