There is no such thing as a bug-free software!
Although nice to think about, bug-free software seems to be a tomorrow that will never come. Problems can come from anywhere. There’s always a little chance of error when it comes to speed and performance in a web application, particularly when it involves customers and revenue. Though it is inevitable to evade any errors, we can definitely prevent it with some proactive actions like post-production performance testing. Some of the most common issues identified are:
- Long user response time
- Long server response time
- Memory leaks
- High CPU usage
- Length queues for requests
- HTTP errors
- Pages not available
It is rightly said that prevention is better than cure. As an experienced software testing company, we thought of drafting guidelines on some of the most common performance issues one can encounter and how to resolve it.
Poorly Written Code:
Poorly written code can cause memory leaks and application deadlocks. Sometimes the old version of a software or integrated legacy system can also drag performance down.
- Solution: Make sure an application has passed through white box testing, teams are using all the tools at their disposal – from automated tools like profilers to best programming practices like code reviews.
Production Environment can be destroyed by an un-optimized database output. Missing indexes also slow down the performance of SQL queries.
- Solution: Make sure developer has used the scripts and file statistics to check for any inefficient queries.
DNS, Firewall, and Network Connectivity:
The DNS queries take the majority of web traffic. Sometimes outside visitors also face the problem of opening the site and resulting errors, 404 and incorrect pathway.
- Solution: Use DNS monitoring safeguards to pinpoint problems at hand. Also, revise switches, check VLAN tags, and distribute tasks between servers.
Slow 3rd Party Search Service:
Sometimes 3rd party tools slow down and gets out of control. It’s hard to determine that the problem is on our side or that of the third party user. If you decide to continue using the third-party service, look at making some design changes to protect your site from at least some of the effects of a third-party service issue.
- Solution: Make sure that your off-service provider guarantees performance.
Extreme XML processing:
If data is too long to process than XML processing can be long process after fetching data from database and it takes so much time and resulting the slowness of server and creates bad effect in performance of application.
- Solution: Make sure the server configuration is also high so that multiple requests and responses can be handled in minimum amount of time.
Excessive SQL Queries:
SQL queries requests come from an application and fulfilled by database that sometimes application throws so many requests at a time. Stack will create on application pool and as per request priority, database gives output to application. It may be possible that so many client requests are on application pool and it takes too long time to render request of application and resulting into slowness of server.
- Solution: Server configuration should be high so that so many Queries can be handled in less amount of time.
Mail Server Connectivity:
Application uses the Mail server for communication. Sometimes it takes long time to connect mail server and resulting into slowness.
- Solution: We can use continuous ingression tools available in market like, “New Relic” (End-to-end transaction tracing, code-level visibility, and Key transaction).
Below are few points for resolution this post production performance issue:
Web Application Performance tuning
- Turn off Tracing unless until required
- Turn off Session State, if not required
- Disable View State of a page if possible
- Set debug=false in web.config
- Avoid Response.Redirect
- Use the String builder to concatenate string
- Avoid throwing exceptions
- Use Finally Method to kill resources
- Use Client Side Scripts for validations
- Avoid unnecessary round trips to the server
- Use Page.ISPostBack
- Include Return Statements within the function/method
- Use “ArrayLists” in place of arrays
- Avoid unnecessary indirection
Tips for Database operations
- Return multiple result sets
- Connection Pooling and Object Pooling
- Use SqlDataReader Instead of Dataset wherever it is possible
- Keep your datasets lean
- Avoid inefficient queries
- Unnecessary round trips
- Too many open connections
- Avoid transaction misuse
- Avoid over normalized tables
- Reduce serialization
- Do not use command builder at run time
- Use stored procedures whenever possible
- Avoid auto-generated commands
Web applications are becoming complex day by day and at the same time, the identification of their performance bottlenecks is becoming a tough task. Various factors contribute to the performance issues and knowledge of those issues & their symptoms are mandatory to rectify the performance bottlenecks. Web server, application server, database server hardware, software and design along with network configurations can be major contributors to performance bottlenecks. Moreover, client-side design and third party components can also affect web application performance. Knowledge of a performance testing and complete list of symptoms of all potential problematic areas will help in identifying the root cause and its remedy.
Vishal Shah has an extensive understanding of multiple application development frameworks and holds an upper hand with newer trends in order to strive and thrive in the dynamic market. He has nurtured his managerial growth in both technical and business aspects and gives his expertise through his blog posts.
Subscribe to our Newsletter
Signup for our newsletter and join 2700+ global business executives and technology experts to receive handpicked industry insights and latest news
Build your Team
Want to Hire Skilled Developers