Cannot debug zed classes triggered by yves request


#1

I stuck again on debugging a zed class and it seems IntelliJ IDE or Xdebug is blocking each other. I use the vagrant box with the spryker suite.

What i wanted to do is to add an item into cart via yves frontend and stop with a breakpoint in the Zed gatewaycontroller (addItemAction) to see whats going on.
For that in my IDE I click on “start listening for PHP debug connections” and click on the debug symbol with the Zed config (as described in documentation).
When i now add the item via frontend I can see that debugger is connected (marks on the breakpoints in IntelliJ) but the request in browser is loading and loading and the debugger never stops on the lines in zed … until the request runs into timeout.

I configured xdebug like its shown in the docs (especially setting max simultaneous connections to 2)

I don’t know the whole ping pong request process between yves and zed but i suggest that an yves request is coming in and blocks the debug connection. Meanwhile zed wants to connect with IntelliJ but can’t because yves request is still there. But yves cant go on because it’s waiting for the zed request. So factual its in a deadlock.
If I don’t start debugging at all, it works perfect.

Here is an excerpt for what happens in the debug log:

This is the Yves request after clicking on “add item” in yves frontend…

I: Connecting to configured address/port: 10.10.0.1:9002.
I: Connected to client. :-)
-> <init xmlns="urn:debugger_protocol_v1" xmlns:xdebug="http://xdebug.org/dbgp/xdebug" fileuri="file:///data/shop/development/current/public/Yves/index.php" language="PHP" xdebug:language_version="7.2.1-1+0~20180105151615.16+stretch~1.gbpd3910a" protocol_version="1.0" appid="5066" idekey="PHPSTORM"><engine version="2.6.0"><![CDATA[Xdebug]]></engine><author><![CDATA[Derick Rethans]]></author><url><![CDATA[http://xdebug.org]]></url><copyright><![CDATA[Copyright (c) 2002-2018 by Derick Rethans]]></copyright></init>

<- feature_set -i 1 -n show_hidden -v 1
-> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="http://xdebug.org/dbgp/xdebug" command="feature_set" transaction_id="1" feature="show_hidden" success="1"></response>

<- feature_set -i 2 -n max_depth -v 1
-> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="http://xdebug.org/dbgp/xdebug" command="feature_set" transaction_id="2" feature="max_depth" success="1"></response>

<- feature_set -i 3 -n max_children -v 100
-> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="http://xdebug.org/dbgp/xdebug" command="feature_set" transaction_id="3" feature="max_children" success="1"></response>
...

After that there is the Zed request

I: Connecting to configured address/port: 10.10.0.1:9002.
I: Connected to client. :-)
-> <init xmlns="urn:debugger_protocol_v1" xmlns:xdebug="http://xdebug.org/dbgp/xdebug" fileuri="file:///data/shop/development/current/public/Zed/index.php" language="PHP" xdebug:language_version="7.2.1-1+0~20180105151615.16+stretch~1.gbpd3910a" protocol_version="1.0" appid="5068" idekey="PHPSTORM"><engine version="2.6.0"><![CDATA[Xdebug]]></engine><author><![CDATA[Derick Rethans]]></author><url><![CDATA[http://xdebug.org]]></url><copyright><![CDATA[Copyright (c) 2002-2018 by Derick Rethans]]></copyright></init>

And from here its waiting until timeout

Has anybody experienced a similar issue?

Thanks