fix report

This commit is contained in:
Urko 2023-04-10 21:28:55 +02:00
parent 84e8ea1ff9
commit e9141e0f11
1 changed files with 13 additions and 14 deletions

View File

@ -35,11 +35,11 @@ Standard go library is pretty easy to use as you will see in the following examp
### startup
`NestJS` application takes between 15 and 25 seconds to startup. Ive created a bash script that counts the whole process since you run npm start until API is reachable
**NestJS** application takes between **15** and **25 seconds** to startup. Ive created a bash script that counts the whole process since you run npm start until API is reachable
![startup](./assets/1.png)
`go` API server startup takes couple milliseconds to start up
**go** API server startup takes couple milliseconds to start up
![startup](./assets/2.png)
@ -72,11 +72,12 @@ NestJS graphql took 40612ms to handle all requests. There is a huge difference:
Testing each one isolated we can see that:
**nest** takes **16417ms** to handle 1000 requests
![startup](./assets/7.png)
**go** takes 1410ms to handle 1000 requests this means go is 11.64 times faster than nest handling requests
![startup](./assets/8.png)
@ -84,40 +85,38 @@ Testing each one isolated we can see that:
Testing each one isolated we can see that:
**nest** takes 75536ms to handle 5000 requests
![startup](./assets/9.png)
**go** takes 6191ms to handle 5000 requests this means go is 12.200 times faster than nest handling requests
![startup](./assets/010.png)
## 1000 requests per second on 3 seconds duration
**nest**
nest
![startup](./assets/011.png)
**go**
![startup](./assets/012.png)
## 1000 requests per second on 5 seconds duration
**nest** it tooks really long to handle all requests. These are some output results. I had to manually stop the test because It was going to crash my machine.
![startup](./assets/013.png)
**go** the first request is just 5 seconds, and then it increases up to 20 seconds due to resources. But handling this traffic with this response times, with 4-6h of development is insane.
![startup](./assets/014.png)
## 1000 requests per second on 10 seconds duration
**nest**
```bash
+---+---------------------------+------------+
| # | DESCRIPTION | ELAPSED |
@ -725,7 +724,7 @@ As we can see comparing these results that go is the most efficient language to
## go benchmark
Using go test -bench mode we are able to test both servers at same time and compare results. We can see go test can handle 1 operation in **4.42ms** which is a great response time while nest is 3 times more **13.94ms**
![startup](./assets/015.png)
## Database used