Skip to content

Commit

Permalink
Merge pull request #950 from samchon/feature/benchmark
Browse files Browse the repository at this point in the history
Close #938: separate `@nestia/benchmark` from `@nestia/e2e`.
  • Loading branch information
samchon authored Jul 9, 2024
2 parents 9f66379 + bfc67ab commit 787ffdd
Show file tree
Hide file tree
Showing 216 changed files with 2,111 additions and 391 deletions.
5 changes: 3 additions & 2 deletions benchmark/package.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
{
"name": "@nestia/benchmark",
"private": true,
"name": "@samchon/nestia-benchmark",
"version": "0.1.0",
"description": "Benchmark Nestia",
"main": "bin/index.js",
"main": "lib/index.js",
"scripts": {
"build": "rimraf bin && tsc",
"generate": "ts-node src/generate && npm run prettier && npm run build",
Expand Down
1 change: 1 addition & 0 deletions packages/benchmark/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
BENCHMARK.md
21 changes: 21 additions & 0 deletions packages/benchmark/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2024 Jeongho Nam

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
52 changes: 52 additions & 0 deletions packages/benchmark/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
{
"name": "@nestia/benchmark",
"version": "0.1.0",
"description": "NestJS Performance Benchmark Program",
"main": "lib/index.js",
"typings": "lib/index.d.ts",
"scripts": {
"build": "npm run build:main && npm run build:test",
"build:main": "rimraf lib && tsc",
"build:test": "rimraf bin && tsc -p test/tsconfig.json",
"dev": "npm run build:test -- --watch",
"prepare": "ts-patch install && typia patch",
"test": "node bin/test"
},
"keywords": [
"e2e",
"nestia",
"nestjs",
"Performance",
"benchmark"
],
"author": "Jeongho Nam",
"license": "MIT",
"devDependencies": {
"@nestia/core": "^3.5.0",
"@nestia/e2e": "^0.7.0",
"@nestia/sdk": "^3.5.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",
"ts-node": "^10.9.2",
"ts-patch": "^3.2.1",
"typescript": "^5.5.3",
"typescript-transform-paths": "^3.4.7",
"typia": "^6.4.3",
"uuid": "^10.0.0"
},
"dependencies": {
"@nestia/fetcher": "^3.5.0",
"tgrid": "^1.0.2",
"tstl": "^3.0.0"
},
"files": [
"lib",
"src",
"README.md",
"LICENSE",
"package.json"
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import os from "os";
import { Driver, WorkerConnector, WorkerServer } from "tgrid";
import { HashMap, hash } from "tstl";

import { IBenchmarkEvent } from "./structures/IBenchmarkEvent";
import { IBenchmarkMaster } from "./structures/IBenchmarkMaster";
import { IBenchmarkServant } from "./structures/IBenchmarkServant";
import { IBenchmarkEvent } from "./IBenchmarkEvent";
import { IBenchmarkMaster } from "./internal/IBenchmarkMaster";
import { IBenchmarkServant } from "./internal/IBenchmarkServant";

/**
* Dynamic benchmark executor running prefixed functions.
Expand Down
File renamed without changes.
2 changes: 2 additions & 0 deletions packages/benchmark/src/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
export * from "./DynamicBenchmarker";
export * from "./IBenchmarkEvent";
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
export interface IBenchmarkMaster {}
export interface IBenchmarkMaster {
filter: (name: string) => boolean;
progress: (current: number) => void;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { IBenchmarkEvent } from "./IBenchmarkEvent";
import { IBenchmarkEvent } from "../IBenchmarkEvent";

export interface IBenchmarkServant {
execute(props: {
Expand Down
1 change: 1 addition & 0 deletions packages/benchmark/test/api/HttpError.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export { HttpError } from "@nestia/fetcher";
1 change: 1 addition & 0 deletions packages/benchmark/test/api/IConnection.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export type { IConnection } from "@nestia/fetcher";
1 change: 1 addition & 0 deletions packages/benchmark/test/api/Primitive.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export type { Primitive } from "@nestia/fetcher";
Loading

0 comments on commit 787ffdd

Please sign in to comment.