• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
benchmarking request between index.php and other controllers

#1
Hi
in Ci3 can I place:

PHP Code:
$this->benchmark->mark('code_start'); 

in the "index.php" page, so I start my benchmark the moment the request gets in. Then at the target controller (in the function of interest) i will place the rest:


PHP Code:
$this->benchmark->mark('code_end');
  
echo $this->benchmark->elapsed_time('code_start''code_end'); 

Will that be accurate, do I need to load, pre-load? any ideas on this?

Thx guys.
Reply

#2
@mike433,

Looks like you using it correctly. I can't think of anything else to add.
Reply


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.