Hello @True Scoop
One of the reasons could be the network latency, which is higher compared to an on-premises deployment. Reducing network round trips can greatly improve performance.
To reduce round-trips, consolidate applications that have high transactions or chatty apps on the same virtual machine.
Another reason could be the server dependencies. Consider the geographical locations of your components.
For example, if you're using Azure, make sure the web server and the database are in the same region. Do queries retrieve more information than they need? Would caching or batching help? Here are a few tips that you can follow to reduce the server response time:
- Use virtual machines with accelerated networking for better network performance.
- Optimize your application for a large number of small values, rather than a few large values.
- Use Redis pipelining to make efficient use of the network and get the best throughput possible.
- Avoid expensive operations like the KEYS command.
- Choose an appropriate tier for your cache.
- Use a Redis client that supports Redis pipelining.
- Monitor performance characteristics on the server carefully and optimize where necessary. If you have already tried these steps and still cannot reduce the server response time, you may need to consider other factors such as the size of your VM, the number of connection objects your application uses, and the CPU usage on client hosts.
- Regarding your question about the correlation between Web App and Virtual Machine, it is difficult to say without more information. However, it is possible that the shift from Web App to Virtual Machine could have affected the server response time.
I hope that this response has addressed your query and helped you overcome your challenges. If so, please mark this response as Answered. This will not only acknowledge our efforts, but also assist other community members who may be looking for similar solutions.