a php extension for monitor your code performance.
- php5.6
- php7
phpize
./configure
make && make install
//add the extension
extension="group_apm.so"
//default is 1;
group_apm.enabled = 1;
<?php
/*
* your code
* do something
*
*
*/
//get the monitor
$data = group_apm();
array (
't' => 0.0019829273223876953,
'cf' => 'Group\\App\\App::__construct=>/private/var/www/Group/vendor/group/group-framework/core/Group/App/App.php:78',
'id' => 29,
'pf_id' => 22,
)
- t => the func call time
- cf => func name and filename:line
- id => current func id
- pf_id => parent func id
It will record the func calltime > 1ms.
php example/group_res.php
php example/group_apm.php