[Tiki-devel] Measuring request time (RE: Performance with Xdebug (and PhpStorm))

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Tiki-devel] Measuring request time (RE: Performance with Xdebug (and PhpStorm))

Cloutier, Philippe (DGARI-Consultant)
I see. Well, FYI, the Network tab of Chrome's developer tools allow you to see the time any request takes (even AJAX).

>De : Roberto Kirschbaum [mailto:[hidden email]]
>Envoyé : 24 juillet 2017 17:19
>À : Tiki developers <[hidden email]>
>Objet : Re: [Tiki-devel] Performance with Xdebug (and PhpStorm)
>
>Yes Philipe, the search box isn't ajax, I guess it was too fast and I didn't notice the result page to load.
>I use Chrome latest version, 64-bit, in a Linux machine. But I tested also on firefox with basically the same results.
>As an IDE I use Atom but I have disabled it's xDebug module.
>
>>On Mon, Jul 24, 2017 at 6:08 PM, Cloutier, Philippe (DGARI-Consultant) <[hidden email]> wrote:
>>Thank you Roberto.
>>
>>The search box in tiki-admin.php is not AJAX, at least by default. By the way, I would not be too surprised if a specific task took twice the normal time or more with Xdebug. I investigated my issue because all pages are affected.
>>Which browser do you use?
>>
>>>De : Roberto Kirschbaum [mailto:[hidden email]]
>>>Envoyé : 24 juillet 2017 16:56
>>>À : Tiki developers <[hidden email]>
>>>Objet : Re: [Tiki-devel] Performance with Xdebug (and PhpStorm)
>>>
>>>Thanks Philippe!
>>>
>>>My report, maybe it helps us get the big picture.
>>>
>>>Environments: 2 Tiki17 environments running with exactly the same code and the same database (2 dockers). The only difference between environments being a flag XDEBUG ON in one and not in the other.
>>>
>>>Loading and editing wiki pages, listing pages, the environment with Xdebug was almost always a few 5% slower. Nothing really noticeable.
>>>
>>>However in tiki-admin.php, if I search for "alias" in the search box, for example. Without Xdebug it works,  WITH Xdebug: "Fatal error: Maximum execution time of 30 seconds exceeded in /var/www/html/tiki-admin.php on line 222". Notice that in this case the Server load module didn't quite help as it works once the page is loaded, whilst the search box in this page is Ajax so the module doesn't have a chance to work.
>>>
>>>cheers!
>>>Roberto
>>>
>>>
>>>
>>>
>>>
>>>>On Mon, Jul 24, 2017 at 5:03 PM, Cloutier, Philippe (DGARI-Consultant) <[hidden email]> wrote:
>>>>Hi Roberto,
>>>>This information is in the loadstats (Server load) module.
>>>>
>>>>Good luck
>>>>
>>>>>De : Roberto Kirschbaum [mailto:[hidden email]]
>>>>>Envoyé : 24 juillet 2017 15:57
>>>>>À : Tiki developers <[hidden email]>
>>>>>Objet : Re: [Tiki-devel] Performance with Xdebug (and PhpStorm)
>>>>>
>>>>>Hi everyone,
>>>>>
>>>>>I have the feeling that xDebug leaves my tiki installs slower, and I'd like to compare the load time in identical environments except for xDebug on/off. Please what's the feature that makes "Execution time: 0.57 secs " appear on the bottom of tiki pages?
>>>>>
>>>>>Thanks!
>>>>>Roberto
>>>>>
>>>>>>On Fri, Jul 21, 2017 at 4:36 PM, Cloutier, Philippe (DGARI-Consultant) <[hidden email]> wrote:
>>>>>>For some reason I wish I knew, this no longer happens. I now get the search form in 900 ms to 1.4 s. Still with Xdebug and XAMPP 5.6.30. The only software change is an upgrade of PhpStorm from 2017.1 to 2017.2.
>>>>>>
>>>>>>> -----Message d'origine-----
>>>>>>> De : Cloutier, Philippe (DGARI-Consultant) [mailto:[hidden email]]
>>>>>>> Envoyé : 12 juillet 2017 08:48
>>>>>>> À : Tiki developers <[hidden email]>
>>>>>>> Objet : Re: [Tiki-devel] Performance with Xdebug (and PhpStorm)
>>>>>>>
>>>>>>> tiki-searchresults.php is very light. I am pretty sure no request for a regular Tiki script using tiki-
>>>>>>> setup.php completes in less than 4.5 s here.
>>>>>>> I could use timings for any page. For example, tiki-contact on trunk just took 6.13 s, and 6.07 s on a
>>>>>>> second request.
>>>>>>>
>>>>>>> > -----Message d'origine-----
>>>>>>> > De : Jonny Bradley [mailto:[hidden email]]
>>>>>>> > Envoyé : 12 juillet 2017 08:02
>>>>>>> > À : Tiki developers <[hidden email]>
>>>>>>> > Objet : Re: [Tiki-devel] Performance with Xdebug (and PhpStorm)
>>>>>>> >
>>>>>>> >
>>>>>>> > Sorry, i don't use that old fulltext mysql search any more (since about tiki 10) and tiki-
>>>>>>> searchindex.php
>>>>>>> > loads about the same speed with or without debug running.
>>>>>>> >
>>>>>>> > Any other test pages we could use?
>>>>>>> >
>>>>>>> > jb
>>>>>>> >
>>>>>>> >
>>>>>>> >
>>>>>>> > > On 11 Jul 2017, at 15:37, Cloutier, Philippe (DGARI-Consultant) <Philippe.Cloutier.externe@mern-
>>>>>>> > mffp.gouv.qc.ca> wrote:
>>>>>>> > >
>>>>>>> > > Thank you Jonny,
>>>>>>> > > I get the same performance (5.04 s, then 4.80 refreshing tiki-searchresults.php right after) with
>>>>>>> your
>>>>>>> > settings.
>>>>>>> > > collect_params allows seeing the values of function parameters in traces.
>>>>>>> > >
>>>>>>> > > Thanks for your relative estimate. Can someone share the absolute time they need for that page
>>>>>>> or
>>>>>>> > others with Xdebug?
>>>>>>> > >
>>>>>>> > >> De : Jonny Bradley [mailto:[hidden email]]
>>>>>>> > >> Envoyé : 11 juillet 2017 08:13
>>>>>>> > >> À : Tiki developers <[hidden email]>
>>>>>>> > >> Objet : Re: [Tiki-devel] Performance with Xdebug (and PhpStorm)
>>>>>>> > >>
>>>>>>> > >> Hi Chealer,
>>>>>>> > >>
>>>>>>> > >> Here's my debug php.ini settings and it runs only slightly slower than when not debugging, like
>>>>>>> 20%
>>>>>>> > slower? (guessing)
>>>>>>> > >>
>>>>>>> > >> [xdebug]
>>>>>>> > >> xdebug.remote_enable = On
>>>>>>> > >> xdebug.remote_autostart = On
>>>>>>> > >> xdebug.idekey = PHPSTORM
>>>>>>> > >> xdebug.collect_return = On
>>>>>>> > >> xdebug.collect_vars = On
>>>>>>> > >> xdebug.show_local_vars = On
>>>>>>> > >> xdebug.profiler_enable = Off
>>>>>>> > >> xdebug.profiler_enable_trigger = On
>>>>>>> > >> xdebug.profiler_aggregate = Off
>>>>>>> > >> xdebug.show_mem_delta = On
>>>>>>> > >>
>>>>>>> > >> Not sure what xdebug.collect_params does, maybe it's that?
>>>>>>> > >>
>>>>>>> > >> HTH
>>>>>>> > >>
>>>>>>> > >> jonny
>>>>>>> > >>
>>>>>>> > >>
>>>>>>> > >>
>>>>>>> > >> On 10 Jul 2017, at 18:57, Cloutier, Philippe (DGARI-Consultant) <Philippe.Cloutier.externe@mern-
>>>>>>> > mffp.gouv.qc.ca> wrote:
>>>>>>> > >>
>>>>>>> > >> Hi,
>>>>>>> > >> I am experiencing severe performance degradation when using Xdebug on my Tiki development
>>>>>>> > PC. I have experienced big degradations with Xdebug on other projects, which are probably more
>>>>>>> > performant than Tiki, but I still find it difficult to accept my experience as normal.
>>>>>>> > >>
>>>>>>> > >> I use a fairly modern desktop with 8 GB of RAM. I use PHP 5.6 from XAMPP 5.6.30. httpd and
>>>>>>> > MySQL are local.
>>>>>>> > >>
>>>>>>> > >> Without Xdebug, simple page loads take under 1 second. I am generally using the initial tiki-
>>>>>>> > searchresults.php (without a query) as a reference. Once Xdebug is enabled, the request only
>>>>>>> > completes fully in 5 s or more. This happens on all my local Tikis, which are fairly close to default
>>>>>>> > installs. For example, tiki-searchresults.php on branch 12.x just took 4.97 s. Repeating with freshly
>>>>>>> > populated cache yields 4.93 s. The results are similar with other versions (6.24 s in trunk).
>>>>>>> > >>
>>>>>>> > >> Before I switched to PhpStorm, I used Eclipse and loads would often take more than 30 seconds
>>>>>>> > when Xdebug was enabled. There was clearly a bug then, but I now wonder if I am still experiencing
>>>>>>> a
>>>>>>> > smaller bug. Xdebug is configured this way:
>>>>>>> > >> xdebug.collect_params = 2
>>>>>>> > >> xdebug.remote_enable = On
>>>>>>> > >> xdebug.remote_cookie_expire_time = 100000 ; 1 day
>>>>>>> > >> xdebug.remote_autostart = 1
>>>>>>> > >>
>>>>>>> > >> I did not debug during the last days and the PC has rebooted since the last debug session. No
>>>>>>> > PhpStorm instance has a debugger running.
>>>>>>> > >>
>>>>>>> > >> This is so bad that on heavier pages, such as tiki-admin.php?page=fgal, I get timeouts with the
>>>>>>> > default 30 s max_execution_time:
>>>>>>> > >>
>>>>>>> > >> Fatal error: Maximum execution time of 30 seconds exceeded in
>>>>>>> >
>>>>>>> C:\xampp\htdocs\tiki\17\vendor_bundled\vendor\smarty\smarty\libs\sysplugins\smarty_internal_t
>>>>>>> > emplate.php on line 732
>>>>>>> > >> Call Stack
>>>>>>> > >> #             Time      Memory              Function              Location
>>>>>>> > >> 1             30.1261 40934080             Smarty_Internal_Template->__destruct( )
>>>>>>> > ..\smarty_internal_template.php:0
>>>>>>> > >>
>>>>>>> > >> This fatal error happens on branch 12 too. If it is normal that Xdebug slows by tenfold, then this
>>>>>>> > excess is normal, since a request for tiki-admin.php?page=fgal already takes 4.72 s without Xdebug.
>>>>>>> > >> And what is most intriguing is that during most of the content download phase, the page is
>>>>>>> > showing. It does look like Smarty has trouble cleaning up. For example, after a mere 765 ms Waiting
>>>>>>> > phase (TTFB), the Content Download phase takes an incredible 5.42 s. On the contrary, without
>>>>>>> > Xdebug, content download is a lot faster than TTFB (for as tiki-admin.php?page=fgal, I have 4.67 s
>>>>>>> TTFB
>>>>>>> > vs a 52 ms Content Download).
>>>>>>> > >>
>>>>>>> > >> How normal does the above sound to other Xdebug users? How long do you wait for tiki-
>>>>>>> > admin.php?page=fgal ? Am I missing some configuration issue?
>>
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
TikiWiki-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [Tiki-devel] Measuring request time (RE: Performance with Xdebug (and PhpStorm))

Roberto Kirschbaum

On Mon, Jul 24, 2017 at 6:34 PM, Cloutier, Philippe (DGARI-Consultant) <[hidden email]> wrote:
I see. Well, FYI, the Network tab of Chrome's developer tools allow you to see the time any request takes (even AJAX).


Yeah, thanks! But you see, I wanted to do some dogfooding!

cheers!

 
>De : Roberto Kirschbaum [mailto:[hidden email]]
>Envoyé : 24 juillet 2017 17:19
>À : Tiki developers <[hidden email]>
>Objet : Re: [Tiki-devel] Performance with Xdebug (and PhpStorm)
>
>Yes Philipe, the search box isn't ajax, I guess it was too fast and I didn't notice the result page to load.
>I use Chrome latest version, 64-bit, in a Linux machine. But I tested also on firefox with basically the same results.
>As an IDE I use Atom but I have disabled it's xDebug module.
>
>>On Mon, Jul 24, 2017 at 6:08 PM, Cloutier, Philippe (DGARI-Consultant) <[hidden email]> wrote:
>>Thank you Roberto.
>>
>>The search box in tiki-admin.php is not AJAX, at least by default. By the way, I would not be too surprised if a specific task took twice the normal time or more with Xdebug. I investigated my issue because all pages are affected.
>>Which browser do you use?
>>
>>>De : Roberto Kirschbaum [mailto:[hidden email]]
>>>Envoyé : 24 juillet 2017 16:56
>>>À : Tiki developers <[hidden email]>
>>>Objet : Re: [Tiki-devel] Performance with Xdebug (and PhpStorm)
>>>
>>>Thanks Philippe!
>>>
>>>My report, maybe it helps us get the big picture.
>>>
>>>Environments: 2 Tiki17 environments running with exactly the same code and the same database (2 dockers). The only difference between environments being a flag XDEBUG ON in one and not in the other.
>>>
>>>Loading and editing wiki pages, listing pages, the environment with Xdebug was almost always a few 5% slower. Nothing really noticeable.
>>>
>>>However in tiki-admin.php, if I search for "alias" in the search box, for example. Without Xdebug it works,  WITH Xdebug: "Fatal error: Maximum execution time of 30 seconds exceeded in /var/www/html/tiki-admin.php on line 222". Notice that in this case the Server load module didn't quite help as it works once the page is loaded, whilst the search box in this page is Ajax so the module doesn't have a chance to work.
>>>
>>>cheers!
>>>Roberto
>>>
>>>
>>>
>>>
>>>
>>>>On Mon, Jul 24, 2017 at 5:03 PM, Cloutier, Philippe (DGARI-Consultant) <[hidden email]> wrote:
>>>>Hi Roberto,
>>>>This information is in the loadstats (Server load) module.
>>>>
>>>>Good luck
>>>>
>>>>>De : Roberto Kirschbaum [mailto:[hidden email]]
>>>>>Envoyé : 24 juillet 2017 15:57
>>>>>À : Tiki developers <[hidden email]>
>>>>>Objet : Re: [Tiki-devel] Performance with Xdebug (and PhpStorm)
>>>>>
>>>>>Hi everyone,
>>>>>
>>>>>I have the feeling that xDebug leaves my tiki installs slower, and I'd like to compare the load time in identical environments except for xDebug on/off. Please what's the feature that makes "Execution time: 0.57 secs " appear on the bottom of tiki pages?
>>>>>
>>>>>Thanks!
>>>>>Roberto
>>>>>
>>>>>>On Fri, Jul 21, 2017 at 4:36 PM, Cloutier, Philippe (DGARI-Consultant) <[hidden email]> wrote:
>>>>>>For some reason I wish I knew, this no longer happens. I now get the search form in 900 ms to 1.4 s. Still with Xdebug and XAMPP 5.6.30. The only software change is an upgrade of PhpStorm from 2017.1 to 2017.2.
>>>>>>
>>>>>>> -----Message d'origine-----
>>>>>>> De : Cloutier, Philippe (DGARI-Consultant) [mailto:[hidden email]]
>>>>>>> Envoyé : 12 juillet 2017 08:48
>>>>>>> À : Tiki developers <[hidden email]>
>>>>>>> Objet : Re: [Tiki-devel] Performance with Xdebug (and PhpStorm)
>>>>>>>
>>>>>>> tiki-searchresults.php is very light. I am pretty sure no request for a regular Tiki script using tiki-
>>>>>>> setup.php completes in less than 4.5 s here.
>>>>>>> I could use timings for any page. For example, tiki-contact on trunk just took 6.13 s, and 6.07 s on a
>>>>>>> second request.
>>>>>>>
>>>>>>> > -----Message d'origine-----
>>>>>>> > De : Jonny Bradley [mailto:[hidden email]]
>>>>>>> > Envoyé : 12 juillet 2017 08:02
>>>>>>> > À : Tiki developers <[hidden email]>
>>>>>>> > Objet : Re: [Tiki-devel] Performance with Xdebug (and PhpStorm)
>>>>>>> >
>>>>>>> >
>>>>>>> > Sorry, i don't use that old fulltext mysql search any more (since about tiki 10) and tiki-
>>>>>>> searchindex.php
>>>>>>> > loads about the same speed with or without debug running.
>>>>>>> >
>>>>>>> > Any other test pages we could use?
>>>>>>> >
>>>>>>> > jb
>>>>>>> >
>>>>>>> >
>>>>>>> >
>>>>>>> > > On 11 Jul 2017, at 15:37, Cloutier, Philippe (DGARI-Consultant) <Philippe.Cloutier.externe@mern-
>>>>>>> > mffp.gouv.qc.ca> wrote:
>>>>>>> > >
>>>>>>> > > Thank you Jonny,
>>>>>>> > > I get the same performance (5.04 s, then 4.80 refreshing tiki-searchresults.php right after) with
>>>>>>> your
>>>>>>> > settings.
>>>>>>> > > collect_params allows seeing the values of function parameters in traces.
>>>>>>> > >
>>>>>>> > > Thanks for your relative estimate. Can someone share the absolute time they need for that page
>>>>>>> or
>>>>>>> > others with Xdebug?
>>>>>>> > >
>>>>>>> > >> De : Jonny Bradley [mailto:[hidden email]]
>>>>>>> > >> Envoyé : 11 juillet 2017 08:13
>>>>>>> > >> À : Tiki developers <[hidden email]>
>>>>>>> > >> Objet : Re: [Tiki-devel] Performance with Xdebug (and PhpStorm)
>>>>>>> > >>
>>>>>>> > >> Hi Chealer,
>>>>>>> > >>
>>>>>>> > >> Here's my debug php.ini settings and it runs only slightly slower than when not debugging, like
>>>>>>> 20%
>>>>>>> > slower? (guessing)
>>>>>>> > >>
>>>>>>> > >> [xdebug]
>>>>>>> > >> xdebug.remote_enable = On
>>>>>>> > >> xdebug.remote_autostart = On
>>>>>>> > >> xdebug.idekey = PHPSTORM
>>>>>>> > >> xdebug.collect_return = On
>>>>>>> > >> xdebug.collect_vars = On
>>>>>>> > >> xdebug.show_local_vars = On
>>>>>>> > >> xdebug.profiler_enable = Off
>>>>>>> > >> xdebug.profiler_enable_trigger = On
>>>>>>> > >> xdebug.profiler_aggregate = Off
>>>>>>> > >> xdebug.show_mem_delta = On
>>>>>>> > >>
>>>>>>> > >> Not sure what xdebug.collect_params does, maybe it's that?
>>>>>>> > >>
>>>>>>> > >> HTH
>>>>>>> > >>
>>>>>>> > >> jonny
>>>>>>> > >>
>>>>>>> > >>
>>>>>>> > >>
>>>>>>> > >> On 10 Jul 2017, at 18:57, Cloutier, Philippe (DGARI-Consultant) <Philippe.Cloutier.externe@mern-
>>>>>>> > mffp.gouv.qc.ca> wrote:
>>>>>>> > >>
>>>>>>> > >> Hi,
>>>>>>> > >> I am experiencing severe performance degradation when using Xdebug on my Tiki development
>>>>>>> > PC. I have experienced big degradations with Xdebug on other projects, which are probably more
>>>>>>> > performant than Tiki, but I still find it difficult to accept my experience as normal.
>>>>>>> > >>
>>>>>>> > >> I use a fairly modern desktop with 8 GB of RAM. I use PHP 5.6 from XAMPP 5.6.30. httpd and
>>>>>>> > MySQL are local.
>>>>>>> > >>
>>>>>>> > >> Without Xdebug, simple page loads take under 1 second. I am generally using the initial tiki-
>>>>>>> > searchresults.php (without a query) as a reference. Once Xdebug is enabled, the request only
>>>>>>> > completes fully in 5 s or more. This happens on all my local Tikis, which are fairly close to default
>>>>>>> > installs. For example, tiki-searchresults.php on branch 12.x just took 4.97 s. Repeating with freshly
>>>>>>> > populated cache yields 4.93 s. The results are similar with other versions (6.24 s in trunk).
>>>>>>> > >>
>>>>>>> > >> Before I switched to PhpStorm, I used Eclipse and loads would often take more than 30 seconds
>>>>>>> > when Xdebug was enabled. There was clearly a bug then, but I now wonder if I am still experiencing
>>>>>>> a
>>>>>>> > smaller bug. Xdebug is configured this way:
>>>>>>> > >> xdebug.collect_params = 2
>>>>>>> > >> xdebug.remote_enable = On
>>>>>>> > >> xdebug.remote_cookie_expire_time = 100000 ; 1 day
>>>>>>> > >> xdebug.remote_autostart = 1
>>>>>>> > >>
>>>>>>> > >> I did not debug during the last days and the PC has rebooted since the last debug session. No
>>>>>>> > PhpStorm instance has a debugger running.
>>>>>>> > >>
>>>>>>> > >> This is so bad that on heavier pages, such as tiki-admin.php?page=fgal, I get timeouts with the
>>>>>>> > default 30 s max_execution_time:
>>>>>>> > >>
>>>>>>> > >> Fatal error: Maximum execution time of 30 seconds exceeded in
>>>>>>> >
>>>>>>> C:\xampp\htdocs\tiki\17\vendor_bundled\vendor\smarty\smarty\libs\sysplugins\smarty_internal_t
>>>>>>> > emplate.php on line 732
>>>>>>> > >> Call Stack
>>>>>>> > >> #             Time      Memory              Function              Location
>>>>>>> > >> 1             30.1261 40934080             Smarty_Internal_Template->__destruct( )
>>>>>>> > ..\smarty_internal_template.php:0
>>>>>>> > >>
>>>>>>> > >> This fatal error happens on branch 12 too. If it is normal that Xdebug slows by tenfold, then this
>>>>>>> > excess is normal, since a request for tiki-admin.php?page=fgal already takes 4.72 s without Xdebug.
>>>>>>> > >> And what is most intriguing is that during most of the content download phase, the page is
>>>>>>> > showing. It does look like Smarty has trouble cleaning up. For example, after a mere 765 ms Waiting
>>>>>>> > phase (TTFB), the Content Download phase takes an incredible 5.42 s. On the contrary, without
>>>>>>> > Xdebug, content download is a lot faster than TTFB (for as tiki-admin.php?page=fgal, I have 4.67 s
>>>>>>> TTFB
>>>>>>> > vs a 52 ms Content Download).
>>>>>>> > >>
>>>>>>> > >> How normal does the above sound to other Xdebug users? How long do you wait for tiki-
>>>>>>> > admin.php?page=fgal ? Am I missing some configuration issue?
>>
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
TikiWiki-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel



--
Roberto Kirschbaum
TACG Sistemas Web
11-9-9661-8185

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
TikiWiki-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel
Loading...