The is the missing profiler for C5 and an extension of http://phpdebugbar.com/
Concrete 5.8 and PHP7.4+ compatible add-on to analyze in realtime system and performance information
There are 2 ways to install this package
Please download the repo and copy and paste just the package folder mt_profiler
into the packages directory.
You can use composer to get the latest version and keep upto date
Add this to you composer.json:
"require": {
"matt9mg/c5-profiler": "^1.0",
"slowprog/composer-copy-file": "~0.3"
},
"scripts": {
"post-install-cmd": [
"SlowProg\\CopyFile\\ScriptHandler::copy"
],
"post-update-cmd": [
"SlowProg\\CopyFile\\ScriptHandler::copy"
]
},
"extra": {
"copy-file": {
"vendor/matt9mg/c5-profiler": "/packages/"
}
}
The copy-file /packages/ DIR location may differ per installation and which composer file location this resides, you'll need to update that accordingly.
Run composer install
- Custom messages
- Custom timelines
- Request information
- Session information
- Monolog
- DB Queries
- Logs
- Events
- Config
- Route
- User
- Blocks
- Memory Usage
- Load time
- PHP version
- Comparable history
Upon package installation a new dashboard page is includes called /dashboard/mt_profiler, within here you can control to show the profiler and what you wish to profile. This information is stored within generated_overrides.
If you wish to control this if the config DIR instead of using the dashboard screen you can do by adding in you config directory for the application application/config
an mt_profiler.php. This will also honour environment based config files such as local.mt_profiler.php, staging.mt_profiler.php, production.mt_profiler.php etc.
<?php
return [
'active' => true,
'profilers' => [
'php_info' => true,
'messages' => true,
'time' => true,
'memory' => true,
'request' => true,
'session' => true,
'monolog' => true,
'db' => true,
'logs' => true,
'env' => true,
'events' => true,
'config' => true,
'route' => true,
'user' => true,
'blocks' => true,
'mail' => true
]
];
You can add custom profiler tabs by simply listening for the event mt_profiler_add_data_collector
Please raise a PR.