Slow Webservice request in Windows server 2016


(Micho23) #1

I have been using Yii 1.1 successfully on one of my applications for several years. Recently we had to upgrade the servers from Windows 2008 R2 to Windows Server 2016. The web application (via web browser) is still running properly and all queries respond in the correct way. However, the web service requests now take 5-8 seconds to complete instead of less than 100ms as before.

I have tried to use PHP 5.3 and PHP 7.1 with no difference in performance for the web service response time.

Previously used: PHP 5.3, Windows 2008 R2, IIS 7.5, SQL server database. Web server is connecting to database server to perform queries (different physical server)
Now using: PHP 5.3 and also tested PHP 7.1, Windows 2016, IIS 10, SQL server database copied from previous environment to Windows 2016. Web server is connecting to database server to perform queries (different physical server)

Any ideas of what could be causing this?


(Micho23) #2

Most of the delay is happening in the POST while the GET still responds in approx. 20ms. The feeling is that there is something in the save process to the database causing this delay.


(Micho23) #3

I have identified the issue:
I have 2 queries running using ActiveRecord. When I comment these out then everything work perfectly. The other queries running without ActiveRecord are fast as normal.
I am connecting to the database with ip address. Any idea if there is some routing issue? I would like to avoid rewriting these queries.