I have a webpage including 3 ajax GET requests calling when openning the page.
The 3 requests refer to the same controller/view while the parameters are totally different. It means that most of the php code for the 3 requests are different. And in every request MYSQL query is needed.
In the browser developer tool, I found that the 3 requests cannot be handled asynchronously. I don't know what factors block them. This problem happens both in Chrome and Firefox, hence it may not be a browser problem.
To make sure that it is a background problem. Three "sleep(3);" have been added to 3 parts of the code (refered to the 3 requests) in the view file. From the browser, the waiting times are 3.xx, 6.xx and 9.xx seconds. Moreover, I open two browsers to open this page at the same time. The waiting time for the two browsers are both 3.xx, 6.xx, 9.xx, but not one browser are 3.xx, 6.xx, 9.xx while the another's are 12.xx, 15.xx, 18.xx.
I don't know whether the causes are from Phalcon or Apache settings.
Could any one help me solve this problem, thanks!