How to do performance Testing for AngularJs application

Hi, All Performance Experts,

I am new to Performance/Load/Stress Testing. I have an application developed in:

Front-end: AngularJs TypeScript & DevExpress,
Application logic: In C# (Microsoft .Net environment),
Database: Sql server.

What are the tools available to test Performance/Load/Stress testing for this application? Is there is a tutorial / Blog/Book which can help me with some example.

Hi @shailendra1979

Two of the most popular performance testing tools you should probably start looking into are Gatling: or JMeter:

Both should allow you to do what you require. In my experience an important factor is to ask around your workplace to see if your colleagues have any prior experience or preference for either.

Hope that gives you a starting place to continue your research

Also try and make the tests a realistic as possible.

For example, just constantly hitting your application with random activity will not give you any real value.

It has to match the user journey for your customers.

Any example / Blog which may guide me to use gatling or Jmeter for Angularjs application?

It will be great if you may give some example for AngularJS application

Any tool which supports HTTP protocol will fit, if you don’t have anything in mind you can consider one of the following:

  • The Grinder
  • Gatling
  • Locust
  • Tsung
  • Apache JMeter

You can check outOpen Source Load Testing Tools: Which One Should You Use? The latter one is the most friendly option for beginners as

  • it provides record-and-replay functionality via HTTP(S) Test Script Recorder
  • no programming languages knowledge is required - you can create the test in GUI form
  • Angular often means AJAX and JMeter supports AJAX requests firing via Parallel Controller

As front-end performance testing is connected to client-side issues, its impact is more visible to the end user and directly affects the browsing experience. After having tested the performance of the entire front-end, in theory a QA team should end up with a stable and fully functional build ready to be brought to market.

In AngularJS application, Web HTTP/HTML gives you the performance of web services and TruClient gives you the end-to-end performance for single Vuser. To validate the performance, you need to blend two protocol approach.

  1. Create a TruClient script with 1 Vuser to validate the end user performance
  2. Create a Web HTTP/HTML script to achieve target transactions to validate the web service
  3. Name the transactions uniquely to differentiate Web HTTP/HTML and Truclient. E.g. T01_Launch_WebHTTP_HTML and T01_Launch_TruClient
  4. Create a scenario and add above two scripts and configure the vusers
  5. Execute it for the defined duration
  6. This will give the overall performance of web service and end-to-end performance

To know the server side performance, you can either use the APM tools or use the below formula:

T01_Launch_TruClient = 2 seconds ( C + S)
T01_Launch_WebHTTP_HTML = 0.5 second (S)
T01_Launch = T01_Launch_TruClient – T01_Launch_WebHTTP_HTML
C – Client side metrics
S – Server/Service Call metrics
T01_Launch = (C+S) – S
T01_Launch = C

i.e. T01_Launch = 0.5 second is the pure client side metrics