diff --git a/packages/benchmark/package.json b/packages/benchmark/package.json index bcc4804ad..265feecfd 100644 --- a/packages/benchmark/package.json +++ b/packages/benchmark/package.json @@ -1,6 +1,6 @@ { "name": "@nestia/benchmark", - "version": "0.1.1", + "version": "0.1.2", "description": "NestJS Performance Benchmark Program", "main": "lib/index.js", "typings": "lib/index.d.ts", @@ -22,14 +22,14 @@ "author": "Jeongho Nam", "license": "MIT", "devDependencies": { - "@nestia/core": "^3.6.1", + "@nestia/core": "^3.7.0", "@nestia/e2e": "^0.7.0", - "@nestia/sdk": "^3.6.1", + "@nestia/sdk": "^3.7.0", "@nestjs/common": "^10.3.10", "@nestjs/core": "^10.3.10", "@nestjs/platform-express": "^10.3.10", "@types/uuid": "^10.0.0", - "nestia": "^5.3.1", + "nestia": "^5.4.0", "ts-node": "^10.9.2", "ts-patch": "^3.2.1", "typescript": "^5.5.3", @@ -38,7 +38,7 @@ "uuid": "^10.0.0" }, "dependencies": { - "@nestia/fetcher": "^3.6.1", + "@nestia/fetcher": "^3.7.0", "tgrid": "^1.0.2", "tstl": "^3.0.0" }, diff --git a/packages/benchmark/src/DynamicBenchmarker.ts b/packages/benchmark/src/DynamicBenchmarker.ts index cfd97afe1..2b5ad6813 100644 --- a/packages/benchmark/src/DynamicBenchmarker.ts +++ b/packages/benchmark/src/DynamicBenchmarker.ts @@ -304,7 +304,7 @@ export namespace DynamicBenchmarker { ].join(" | "); return [ `# Benchmark Report`, - "> Generated by [`@nestia/e2e`](https://github.com/samchon/nestia)", + "> Generated by [`@nestia/benchmark`](https://github.com/samchon/nestia)", ``, ` - Specifications`, ` - CPU: ${os.cpus()[0].model}`, diff --git a/website/pages/docs/e2e/benchmark.mdx b/website/pages/docs/e2e/benchmark.mdx index 39e0171b5..523d5307c 100644 --- a/website/pages/docs/e2e/benchmark.mdx +++ b/website/pages/docs/e2e/benchmark.mdx @@ -3,9 +3,9 @@ import { Tabs, Tab } from 'nextra-theme-docs' ## Outline Benchmark your backend server with e2e test functions. -If you've developed e2e test functions utilizing [SDK library of `@nestia/sdk`](../sdk/sdk), you can re-use those e2e test functions in the benchmark program supported by `@nestia/e2e`. The benchmark program will run these e2e test functions in parellel and randomly to measure the performance of your backend server. +If you've developed e2e test functions utilizing [SDK library of `@nestia/sdk`](../sdk/sdk), you can re-use those e2e test functions in the benchmark program supported by `@nestia/benchmark`. The benchmark program will run these e2e test functions in parellel and randomly to measure the performance of your backend server. -If you want to pre-exprience the benchmark program utliizng the e2e test functions of `@nestia/sdk`, visit below playground website. Also, here is the benchmark report example generated by the benchmark program of `@nestia/e2e` executed in the below playgroud link. +If you want to pre-exprience the benchmark program utliizng the e2e test functions of `@nestia/sdk`, visit below playground website. Also, here is the benchmark report example generated by the benchmark program of `@nestia/benchmark` executed in the below playgroud link. > 💻 [https://stackblitz.com/~/github.com/samchon/nestia-start](https://stackblitz.com/~/github.com/samchon/nestia-start?file=README.md,docs/benchmarks/AMD%20Ryzen%209%207940HS%20w%20Radeon%20780M%20Graphics.md!,test/benchmark/index.ts,test/benchmark/servant.ts,test/features/api/bbs/test_api_bbs_article_create.ts&startScript=build:test,benchmark&view=editor) > @@ -28,7 +28,7 @@ If you want to pre-exprience the benchmark program utliizng the e2e test functio ]}> ```typescript filename="test/benchmark/index.ts" showLineNumbers {76-94} -import { DynamicBenchmarker } from "@nestia/e2e"; +import { DynamicBenchmarker } from "@nestia/benchmark"; import cliProgress from "cli-progress"; import fs from "fs"; import os from "os"; @@ -152,7 +152,7 @@ main().catch((exp) => { ```typescript filename="test/benchmark/servant.ts" showLineNumbers -import { DynamicBenchmarker } from "@nestia/e2e"; +import { DynamicBenchmarker } from "@nestia/benchmark"; import { MyConfiguration } from "../../src/MyConfiguration"; @@ -171,7 +171,7 @@ DynamicBenchmarker.servant({ -To compose the benchmark program of `@nestia/e2e` on your backend application, you have to create two executable TypeScript programs; the main program and the servant program. +To compose the benchmark program of `@nestia/benchmark` on your backend application, you have to create two executable TypeScript programs; the main program and the servant program. The main program is executed by user (`npm run benchmark` command in the playground project), and centralizes the benchmark progress. It creates multiple servant programs parallel, and aggregate the benchmark results from them. After the aggregation, it publishes the benchmark report with markdown format. diff --git a/website/pages/docs/e2e/why.mdx b/website/pages/docs/e2e/why.mdx index b34f772f7..2ba431519 100644 --- a/website/pages/docs/e2e/why.mdx +++ b/website/pages/docs/e2e/why.mdx @@ -5,7 +5,7 @@ E2E test functions rather than unit test functions. When developing a test program for NestJS developed backend server, I recommend to adapt E2E test paradigm instead of unit test paradigm. It's because with the [`@nestia/sdk` generated SDK library](../sdk/sdk), E2E test functions can be much easier, safer and efficient for production than the traditional unit test functions. -Furthermore, if you develop test functions utilizing the SDK library, you can easily switch the e2e test functions to the performance benchmark functions. Just by utilizing `@nestia/e2e` library, you can easily measure your NestJS developed backend server's performance through the SDK library utilizing e2e test functions. +Furthermore, if you develop test functions utilizing the SDK library, you can easily switch the e2e test functions to the performance benchmark functions. Just by utilizing `@nestia/e2e` nd `@nestia/benchmark` libraries, you can easily measure your NestJS developed backend server's performance through the SDK library utilizing e2e test functions. - [E2E Test Function Example](https://github.com/samchon/nestia-start/blob/master/test/features/api/bbs/test_api_bbs_article_create.ts) - [Benchmark Result Example](https://github.com/samchon/nestia-start/blob/master/docs/benchmarks/AMD%20Ryzen%209%207940HS%20w%20Radeon%20780M%20Graphics.md) @@ -429,7 +429,7 @@ If you want to experience the test program earlier, visit below playground websi selectedIndex={1}> ```typescript filename="test/benchmark/index.ts" showLineNumbers {76-94} -import { DynamicBenchmarker } from "@nestia/e2e"; +import { DynamicBenchmarker } from "@nestia/benchmark"; import cliProgress from "cli-progress"; import fs from "fs"; import os from "os"; @@ -553,7 +553,7 @@ main().catch((exp) => { ```typescript filename="test/benchmark/servant.ts" showLineNumbers -import { DynamicBenchmarker } from "@nestia/e2e"; +import { DynamicBenchmarker } from "@nestia/benchmark"; import { MyConfiguration } from "../../src/MyConfiguration";