Sunday, February 19, 2012

Use VSTS to load test Azure based app

How to do load test on Azure based app? Using VSTS in Azure is a natural choice, since both the test rig and servers been tested would be in cloud and be freely scaled out. However, testing with VSTS in Azure today could be painful, mainly due to the network issues. We acturally did such a test recently. Below is our findings.


(The to-be-released new persistent VM role, as well as the improved Azure network capabilities like Brooklyn and internal DNS, will hopefully make the VSTS testing in Auzre much easier in the future.)
  • Can we do VSTS load test from Azure and test App in Azure?
    • Yes
  • Deployment architecture
    • (this is the design works for us, but not necessarily the best design.)
    • Test Controller in Azure, worker role
    • Test Agents in Azure, worker role
    • Controller and Agents are in the same worker role, on different instances
    • Use Azure connect to group Test Controller and Test Agents so that they can see each other
    • VSTS test DB in SQL Azure
    • App server (being tested) in Azure, whatever role
  • Workarounds and Pains
    • VSTS DB doesn’t work directly in SQL Azure
    • We used customized DB scripts
    • Test Rig (Agent/Controller/TestedServer) is very unstable in Azure
    • Controller may lose connection to Agent. Agent may not start.
    • If this happens during the test, the test will fail.
    • We are forced to use only up to 3 agents.
    • Every time this happens, we need to restart the service in Agents or controller.
  • Hard to collect performance counters