230304 TIL

William Parker·2023년 3월 6일
0

nGrinder : nGrinder is an open source project developed by Naver for server load testing. It helps to measure server performance by requesting how many users the server can accommodate before servicing the application.

I will try to apply this tool for our project's load balance test.

  1. Install

https://github.com/naver/ngrinder/releases

download ngrinder-controller-{version}.war file.

In the terminal page:

$ java -jar ngrinder-controller-{version}.war --port=8300
example : java -jar ngrinder-controller-3.5.8.war --port=8300

remember the port number, it could use for acceess nGrinder website.

If the terminal seems to have finished running
Go to localhost:8300 in your browser.

Initial ID, PW is admin, admin
Next you need to install the agent.

// Unzip the downloaded file.
$ tar -xvf ngrinder-agent-3.5.8-localhost.tar
// Navigate to the unzipped agent folder
$ cd ngrinder-agent

Now we need to run the agent.

if you use the mac try this code.

./run_agent.sh

if you use the window try this code.

run_agent.bat

If you finish the start to run_agent.bat.
Go to localhost:8300
check Agent Management page.

The preparation work is now almost complete.
Next, we need to write a test script.
It is said that it is written in a language called Groovy, but it is based on Junit5 and is similar to Java, so it is not difficult.

I tried to take the test in the localhost environment.

TPS : Transaction per second.
Mean Test time : Increasing average test time vuser increases MTT proportionally.

As a result, TPS is about how many transactions can be processed per second, so higher is better and the goal is to process more than 100 transactions per second.

And since MTT is a graph showing how much delay there is, we will improve the test within 1000 ms.

profile
Developer who does not give up and keeps on going.

0개의 댓글