Application Performance Engineering

Subscribe to Application Performance Engineering: eMailAlertsEmail Alerts newslettersWeekly Newsletters
Get Application Performance Engineering: homepageHomepage mobileMobile rssRSS facebookFacebook twitterTwitter linkedinLinkedIn


A.P.E. Authors: Sarah Watkins, Yeshim Deniz, Stackify Blog, Larry Dragich, Lori MacVittie

Related Topics: SOA & WOA Magazine, Java Developer Magazine, Application Performance Engineering

Article

Performance Requirements Analysis

How AWStats, a Web Log Analysis tool, can help in extracting performance requirements for any application

Performance is one of the key non-functional needs for any application and performance requirements needs to to be captured as part of requirements & analysis phase in a way that is understandable by all application stakeholders. In this article, we will see the key aspects of performance engineering and how AWStats, a Web Log Analysis tool, can help in extracting performance requirements for any application.

Performance Engineering - Phases
Performance Engineering is a discipline encompassing activities like Performance modeling, Performance testing and Performance tuning spanning across the development lifecycle of any application. This discipline can be approached in sequential phases: Planning & preparation, Execution & Reporting, Review & Closure.

The planning & preparation is a major phase during which the performance requirements are elicited and the performance tests are designed. Performance modeling skills are applied during this phase to gather and detail the performance requirements for the application in scope. It involves capturing details on key transactions that are performance intensive, peak & moderate loads, external system dependencies, data growth and infrastructure specific to system under test.

Execution & Reporting is the next phase where in the performance testing, reporting and tuning activities are done. And during the final phase of Review & Closure, summary of performance testing is reviewed with key stakeholders and a go/no-go decision is arrived at for the system under test.

Performance Requirements Elicitation
The primary activity of performance engineering is to collect information in order to be able to help stakeholders make informed decisions related to the overall quality of the application being tested. Performance requirements for “first of its kind” application within organization can be evolved by discussing with business/marketing teams or derived from statistics of similar applications in market. For those applications which are getting enhanced or migrated or re-written, the performance requirements can be extracted from the existing applications in use. If the existing application is web based, then meaningful & useful information around performance can be extracted from web server logs which will help in defining the performance requirements for the application under consideration. Web Log Analyzers are handy in this scenario; it provides insight into usage of application by analyzing web server logs and generating meaningful reports. The next section focuses on providing an overview of such a tool, AWStats that generates statistics reports based on server logs.

AWStats - Features
AWStats is very easy to setup, configure and generate reports. It’s written in Perl so ActivePerl needs to be installed in the machine for running AWStats.

There are so many other web log analyzers but big advantage with AWStats is its ease of use and its ability to generate reports not only from Apache or IIS web server log formats but also any custom format used by the server to log data.

AWStats can be configured to generate reports either online from actual running servers or offline from server log files. The reports can be generated for a specific day/month/year.

AWStats analyzes the log files and generates reports providing insight into below key stats:

Workload - The report includes details of workload in terms of pages, hits and bandwidth at various levels like workload spread by monthly basis, days of month, days of week and hours of day. Typically the report can be used to first identify peak day of peak month and then look at how the workload is distributed across hours of peak day. This provides us insight into hours of peak load, moderate load and minimal load volumes that can be used in load testing of the application.

Summary - It provides summary details like period for which the report is generated, unique visitors, number of visits, pages, hits and bandwidth.

Unique visitors - The unique visitors is derived based on IP address in the log file, each IP address is considered as a unique visitor. Reports details of IP addresses with no of pages and hits by each IP.

Pages-URL - This is another key information that reports the list of application URLs hit during the period along with number of hits & average size. This info is critical to identify the key transactions for performance testing. The top ‘n’ transactions can be derived from the page URLs hit and is the most used transactions in the application. Pages denote the actual number of hits to HTML/JSP pages excluding images/JS/CSS.

Visits duration - Provides the average visit duration considering the total number of visits. It also provides details on number of visits & its duration during different time ranges like 0-30s, 30s-2 min, 2min-5min etc. This detail provides us with insight into the time spent by customers on the website and can be useful info for business & marketing teams. Also, the average duration spent by majority of customers helps us deduce the average session time that can be used during performance testing scenarios in test scripts.

Operating Systems & Browsers - It provides details on number of hits from different Operating systems & web browsers. This info is highly useful as an input for functional testers, business teams as they can focus their testing efforts on OS & browsers that are highly used by consumers. Also, the report provides the specific versions of browsers used by customers which again helps narrow down the testing effort better.

Connect to site - This info is useful for business & marketing teams, as it shows the number of hits & its distribution by customers accessing the application website from favorites, bookmarks or from other external web sites (URLs for these external sites are also provided).

HTTP Status Codes - It provides the hits & its percentage distribution of various http status codes. It helps us understand the usage of http controls like re-directs by the application

AWStates also has few utilities such as below that are very handy:

BuildStaticPages - This script allows building all possible reports allowed by AWStats.

LogResolveMerge - This is a very useful utility. Generally, in a production environment there will be multiple web servers balanced by load balancers, so it will be good to have single web analyzer report from these load balanced web servers. This utility takes in the log files from different web servers and provides us with one unique server log file sorted by date.

Summary
As seen, AWStats tool is useful in analyzing an existing application’s performance statistics and helping arrive at performance requirements for the target application, which is re-engineering or upgrade of existing application.

References

http://awstats.sourceforge.net/

More Stories By Ravi M

M.Ravi is a Senior Technical Architect, specialized in providing architecture and design solutions on broad of spectrum of areas such as JEE, SOA, ESB, BI, CRM & SAS.