Jump to content

Debugging code beyond basic?


iarp

Recommended Posts

Hi all,

 

I'm trying to work with SugarCRM's REST service, whenever you add a new email it passes the email off to a class called HTMLPurifier

 

I'm having issues though, passing emails to the service causes a huge delay and the web server time's out on me event if i set the timeout to 15minutes.

 

I installed xdebug to maybe see a reason, or if there were any error messages, using kcachegrind i can look at the output file and see, with a timeout of 2 minutes, what i think i read here is that array_splice is using 97% of that time and being called 6,461 times. Even worse would be array_shift being called 12,223 times.

 

There has to be some reason why this is taking so long to process emails through this class. 

 

I'm just stuck here because i don't know where to go next. I don't know Sugar's source well enough to pick it apart and figure out why it's bugging out like this.

 

What's next for me to look at?

Link to comment
https://forums.phpfreaks.com/topic/277364-debugging-code-beyond-basic/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.