Presentation is loading. Please wait.

Presentation is loading. Please wait.

Performance testing and engineering Raja Gourav Kokkiligadda, Performance Architect, Domestic and General.

Similar presentations


Presentation on theme: "Performance testing and engineering Raja Gourav Kokkiligadda, Performance Architect, Domestic and General."— Presentation transcript:

1 Performance testing and engineering Raja Gourav Kokkiligadda, Performance Architect, Domestic and General.

2 PERFORMANCE TESTING VS PERFORMANCE ENGINEERING Performance Testing: Performance testing is the process of determining the speed or effectiveness of a computer, network, software program or device. This process can involve quantitativetests done in a lab, such as measuring the response time or the number of MIPS (millions of instructions per second) at which a system functions. Performance Engineering: Performance engineering or SPE (Systems Performance Engineering or Software Performance Engineering) within systems engineering, encompasses the set of roles, skills, activities, practices, tools, and deliverables applied at every phase of the systems development life cycle which ensures that a solution will be designed, implemented, and operationally supported to meet the non- functional requirements for performance (such as throughput, latency, or memory usage).systems engineeringsystems development life cyclenon- functional requirementsthroughputlatencymemory Wikipedia

3 WHAT IT REALLY MEANS? You call it Performance Testing when the process involved is at the end of life cycle and often only “Tested”  Outcomes would be test reports and few end of the gate performance improvements made such as a little tweak in configurations, code or hardware / software tuning  Especially unfit in the case of multi-tier architecture You call it Performance Engineering when the process involved is from the beginning of life cycle till end  Performance engineer would be involved from Architectural idea, design phase, implementations, modular design and engineering, integration phases and finally at the end of the life cycle  The reason for this process is “often software performance does not degrade because of one reason but because of cause and action. Each outcome is designed, developed and tested for performance with availability of latest code base”

4 FUNDAMENTAL ARCHITECTURE Load Tools: Jmeter / Soapui

5 FUNDAMENTAL BLOCKS OF PERFORMANCE TESTING Client Side  Often simulated using load testing tools such as jmeter, load runner, load ui etc  At the end of the day it is nothing but simulating requests from client to server  Client side metrics are Response Time, Throughput  In fact tests are designed observing client side activities and they are two fold  Throughput based testing (volume)  Time based testing (regular load testing) Server Side  Often server side metrics are monitored, analysed and reported for fixing performance issues  They can broadly be divided into two segments  Server or System Health  Application specific metrics such as jvm memory or fault code

6 REAL FUNDAMENTAL BLOCKS OF PERFORMANCE At the end of the day performance testing boils down to manipulating requests  What is a request?  A request as it named is client asking for some resources from servers be it web server or DB  http request  The Hypertext Transfer Protocol (HTTP) is an application protocol for distributed, collaborative, hypermedia information systems. HTTP is the foundation of data communication for the World Wide Web. Hypertext is structured text that uses logical links (hyperlinks) between nodes containing text. – Wikipedia  There are two kinds of http requests that are most popular 1.A Get Request and 2.A Post Request A get request as a nomenclature is triggered when you want a kind of resource from the system A post request is triggered when you want to save some kind of data onto the systems

7 A GET REQUEST GET http://www.cooltoad.com/ HTTP/1.1 Headers: Host: www.cooltoad.comwww.cooltoad.com Proxy-Connection: keep-alive Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8 Upgrade- Insecure-Requests: 1 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.112 Safari/537.36 Accept-Encoding: gzip, deflate, sdch Accept-Language: en-US,en;q=0.8 Cookie: PHPSESSID=3l49gq03gs6h44sie9echh3c67; _ga=GA1.2.1715845449.1461066242; _gat=1

8 A POST REQUEST POST http://cooltoad.com/account/sign_up HTTP/1.1 Headers: Host: cooltoad.com Proxy-Connection: keep-alive Content-Length: 177 Cache-Control: max-age=0 Form Data: username=raja.gourav&password=suryateja19&password1=suryateja19&name=raja&city= swindon&province=Wiltshire&country=UK&gender=m&alt_eml=gourav.performance%40yah oo.com&age=y&x=48&y=8

9 SOAP REQUEST – POST REQUEST POST http://cooltoad.com/account/sign_up HTTP/1.1 Headers: Host: cooltoad.com Proxy-Connection: keep-alive Content-Length: 177 Cache-Control: max-age=0 Form Data: ----------- Body Request -----------

10 DYNAMIC DATA MANIPULATION REQUESTS Dynamic data manipulation is the process of manipulating the request for dynamic parameters such as username, password or session ids. There are two ways you can handle data manipulation in any of load testing tools depending on the kind of data to be handled and this forms MOST IMPORTANT part of writing performance test scripts. 1.Parameterization 1.Parameterization is done when you know the End user data. for example you can assume end user data such as username, passwords or any of the form data while you are posting a request 2.Correlation 1.Mostly this data cannot be assumed and is almost often sent from the server. For example session id’s. we will not be able to create a session id that matches with server issued id. 2.The other place where we can correlate stuff is when you want automate some links or values. For example if there are 1000 links you will not write 1000 lines of code for testing instead you write 1 line of code for correlating and use some kind of logic to click on all 1000 lines.

11 THINGS TO CONSIDER WHILE PLANNING PERFORMANCE TEST / ENGINEERING Objective: The most important. If you understand the objective of the tests the rest of things fall in place. It is most important for a performance engineer to understand objective of the testing Approach: There are many ways on how you approach a problem. There are many different kind of test scenarios that you can design such as Load Tests, Stress Tests and Endurance Tests. Also there are many different ways of approaching Performance Engineering problem such as Benchmarking, Agile Performance Engineering, Component Engineering, Baselining, Scalability, Capacity planning etc Methodology: mostly Industry adapts to water fall models when designing Performance engineering but Agile methodology is more useful. This is because a little change in the code, component or environment can adversely affect the performance of the system and should be monitored and tested continuously Tools: There are many tools out there for both testing and engineering but I have designed a process called EPOC which effectively assess tools both in terms of budget and usage Plan: A plan should not only cover the Business scenarios or Work Loads but should also take into account the future usage of the application which with time might degrade its performance

12 EPOC & SERVER SIDE PERFORMANCE EPOC stands for Proof of concept in elevation process. This is a process where you start assessing tools for usage starting from open source tools to premium tools. Server Side Performance: There are two pieces of puzzles in assessing server side performance Server Health – (Tools such as Perfmon, vmstat etc can be used) Application Stats – (Tools such as Jconsole, Java Heap, New Relic can be used)


Download ppt "Performance testing and engineering Raja Gourav Kokkiligadda, Performance Architect, Domestic and General."

Similar presentations


Ads by Google