This week I was trying to find out what is the cause of the error that degrades the performance of Monkey. With the help of Eduardo (my mentor), I found out a few errors.
Web server benchmarking :
Server side profiling : I used a new tool of the name kcachegrind, which is a variation of valgrind, that helps find out how many times each function in the source code has been called and which function takes the maximum processing time.
- For the purpose of debugging, I had been printing messages to the standard out, from the various functions of the caching plugin. I was also configuring the server with the trace mode on. This greatly slowed down the performance of the server.
- Also, at the end of stage_30 of the plugin, inspite of the request being successfully being handled by the plugin, it returned MK_PLUGIN_RET_NOT_ME, which meant that it would be handled by monkey core. This also affected the performance. I’m still working on fixing this issue and returning MK_PLUGIN_END at some point so that the request would be completely processed.