Will enabling XDebug on a production server make PHP slower?

后端 未结 11 1558
孤独总比滥情好
孤独总比滥情好 2020-11-28 12:47

The title pretty much says it all...is it a bad idea ? I\'d like to have the enhanced debug messages that XDebug provides on the server.

[edit] Just to make things c

11条回答
  •  独厮守ぢ
    2020-11-28 13:11

    Removing xdebug completely (even when it was not enabled) gave us 50% in page load boost (down from 60ms to 30ms). We had xdebug sitting "dormant" (waiting for trigger). We thought that since it's dormant it won't cause any harm, but boy were we wrong.

    We commented out the zend_extension line in the php config at around 21:43. Average load dropped from 0.4 to 0.2 per core as well:

提交回复
热议问题