1
Hello,
I wonder if there is any open source tool for me to analyze memory/processing usage allocated by my methods in production.
I would like to know what methods need attention and improvements, and so decrease the use of resources by my applications.
My production environments are composed of php-5.6 or php-7 (depends on the application), Nginx as reverse proxy, Apache2 behind NGINX (by limitations on some applications) and Linux (Ubuntu/Centos) as S.O.
You can see some information with the Xdebug (free) and the Blackbird (paid) both make Profiling.
– rray
In the case of XDEBUG it will not slow down my application?
– Hiago Souza
Any profiler will make your application (maybe even) slow, you run only to detect the bottlenecks then turn off, make the proper modifications and turn on again to see whether or not it has effected.
– rray
Oh yes I understood, I thought there could be something like Sentry (which makes analysis of errors) so that it could be turned on in production without affecting performance... (but I found it very magical in the case of the Profiling) I will do some tests.
– Hiago Souza
In the case of Xdebug, you run that chunk of code and it measures how long each operation (called methods/functions) took to be performed and amount of mémoria allocated. Then it generates a file with this information is necessary another tool to analyze this log, the webgrind is an example there are other options.
– rray
Open-Source don’t know. There is Newrelic and the like, which monitor the whole server and the application. It is able to list the average response time, which were the slowest and why were, which function took the most time to be processed, even the query that took to be processed and, of course, also reports execution errors... It can usually be kept on "forever". However it is paid.
– Inkeliz