Slow responses when not in listening mode (mac osx, PhpStrom 4.0.3, MAMP2.0)

Hello,

I'm developing my own framework to generate html code completle OOP.
Zo every html element is a object bevore its al formated as html code and send to the browser.

I dont know is its becouse i have now lots of objects bevore i generate html code, but i experiense when testing it on my develop laptop very slow responces.
But when i hit the listening button, and start debugging, the pages run muts muts faster.

I was wondering how this can be, becouse i dont always want my listning mode on in PhpStorm when do some testing.

0

Hi there,

The way how you described it .... sounds like xdebug configuration issue to me (xdebug.remote_connect_back and/or xdebug.remote_autostart in particular). Post your xdebug settings please (from php.ini ... or at very least from phpinfo() output)

0

Hello Andriy,

This is my xdebug conf in the php.ini

[xdebug]
xdebug.default_enable=1
xdebug.remote_enable=1
xdebug.remote_handler=dbgp
xdebug.remote_host=localhost
xdebug.remote_port=9000
xdebug.remote_autostart=1
zend_extension="/Applications/MAMP/bin/php/php5.3.6/lib/php/extensions/no-debug-non-zts-20090626/xdebug.so"



And this from my phpinfo()

xdebug

xdebug support enabled
Version 2.1.0

Supported protocols Revision
DBGp - Common DeBuGger Protocol $Revision: 1.145 $
0

Hi there,

Try xdebug.remote_autostart=0

You can check what this option does when set to enabled (1) here: http://xdebug.org/docs/all_settings#remote_autostart

Right now xdebug initiates debugger session automatically for every single request. Hence the delay, because nothing is listening for incoming debugging connections and xdebug allows some certain amount of time for connection to succeed (to see if connection was establised or not). WIth that option turned off, there will be no automatic attempt to create debug session --- you will have to initiate it manually (using browser bookmarklets or browser extension/etc for that).

0

Thanks for your reply,

I wil test this later this evening.

P.S. if i read corectly this sessting only will be good, becouse of all default values on local debugging
xdebug.remote_enable=1

I post the results when i get them.

0

This was the solution.

I now have only this line active : xdebug.remote_enable=1

The only thing i needed to figure out was that it was not hitting the breakpoints anymore.
I needed to add the bookmarklets to my browser in order to get debugging to work again.
The generator for this i found at : http://www.jetbrains.com/phpstorm/marklets/

Many thanks.

0

请先登录再写评论。