From e29d390451e405c84aee1f8a2c5213732c373f01 Mon Sep 17 00:00:00 2001 From: Meysam Hadeli <35596795+meysamhadeli@users.noreply.github.com> Date: Thu, 26 Dec 2024 00:45:41 +0330 Subject: [PATCH 1/3] feat: update all packages --- src/booking/.eslintrc.js | 25 -- src/booking/.prettierignore | 3 + src/booking/.prettierrc | 10 +- src/booking/eslint.config.js | 12 + src/booking/nest-cli.json | 5 +- src/booking/package.json | 64 +++-- src/booking/src/app.module.ts | 64 ++--- src/booking/src/booking/booking.module.ts | 58 ++-- src/booking/src/booking/dtos/booking.dto.ts | 24 +- .../src/booking/entities/booking.entity.ts | 56 ++-- .../v1/create-booking/create-booking.ts | 197 +++++++------ .../services/flight/flight.client.ts | 101 +++---- .../services/passenger/passenger-client.ts | 40 ++- src/booking/src/booking/mappings.ts | 114 ++++---- src/booking/src/data/data-source.ts | 24 +- .../1702506382196-create-booking-table.ts | 19 +- .../data/repositories/booking.repository.ts | 13 +- src/booking/src/main.ts | 63 ++-- src/booking/tsconfig.json | 42 ++- src/building-blocks/.eslintignore | 2 - src/building-blocks/.eslintrc | 16 -- src/building-blocks/.lintstagedrc | 3 - src/building-blocks/.prettierignore | 3 + src/building-blocks/configs/configs.js | 47 +-- src/building-blocks/configs/configs.js.map | 2 +- src/building-blocks/configs/configs.ts | 209 +++++++------- src/building-blocks/context/context.d.ts | 3 +- src/building-blocks/context/context.js.map | 2 +- src/building-blocks/context/context.ts | 12 +- .../contracts/booking.contract.d.ts | 2 +- .../contracts/booking.contract.ts | 2 +- .../contracts/flight.contract.d.ts | 2 +- .../contracts/flight.contract.ts | 2 +- .../contracts/identity.contract.d.ts | 2 +- .../contracts/identity.contract.ts | 2 +- src/building-blocks/eslint.config.js | 12 + .../monitoring/prometheus.metrics.js | 24 +- .../monitoring/prometheus.metrics.js.map | 2 +- .../monitoring/request-counter.middleware.js | 28 +- .../request-counter.middleware.js.map | 2 +- .../monitoring/request-counter.middleware.ts | 48 ++-- .../monitoring/request-duration.middleware.js | 26 +- .../request-duration.middleware.js.map | 2 +- .../monitoring/request-duration.middleware.ts | 30 +- .../open-telemetry-tracer.js.map | 2 +- .../openTelemetry/open-telemetry-tracer.ts | 32 +-- .../openTelemetry/open-telemetry.module.js | 6 +- .../open-telemetry.module.js.map | 2 +- .../openTelemetry/open-telemetry.module.ts | 15 +- src/building-blocks/package.json | 87 +++--- src/building-blocks/passport/jwt.guard.d.ts | 2 +- src/building-blocks/passport/jwt.guard.js | 1 - .../rabbitmq/rabbitmq-connection.js | 24 +- .../rabbitmq/rabbitmq-connection.js.map | 2 +- .../rabbitmq/rabbitmq-connection.ts | 2 - .../rabbitmq/rabbitmq-publisher.js | 4 +- .../rabbitmq/rabbitmq-publisher.js.map | 2 +- .../rabbitmq/rabbitmq-publisher.ts | 10 +- .../rabbitmq/rabbitmq-subscriber.js | 4 +- .../rabbitmq/rabbitmq-subscriber.js.map | 2 +- .../rabbitmq/rabbitmq-subscriber.ts | 8 +- .../rabbitmq/rabbitmq.module.js.map | 2 +- .../rabbitmq/rabbitmq.module.ts | 12 +- .../postgres/postgres-container.d.ts | 2 +- .../postgres/postgres-container.js.map | 2 +- .../container/postgres/postgres-container.ts | 15 +- .../rabbitmq/rabbitmq-container.d.ts | 2 +- .../rabbitmq/rabbitmq-container.js.map | 2 +- .../container/rabbitmq/rabbitmq-container.ts | 16 +- src/building-blocks/tsconfig.json | 43 ++- src/building-blocks/tsconfig.tsbuildinfo | 1 - .../exeptions/application.exception.js.map | 2 +- .../types/exeptions/application.exception.ts | 32 +-- .../exeptions/http-client.exception.js.map | 2 +- .../types/exeptions/http-client.exception.ts | 2 +- src/building-blocks/utils/encryption.js | 24 +- src/building-blocks/utils/encryption.js.map | 2 +- src/building-blocks/utils/encryption.ts | 3 +- src/building-blocks/utils/serilization.js.map | 2 +- src/building-blocks/utils/serilization.ts | 20 +- src/building-blocks/utils/time.js | 3 +- src/building-blocks/utils/time.js.map | 2 +- src/flight/.eslintrc.js | 25 -- src/flight/.prettierignore | 3 + src/flight/.prettierrc | 10 +- src/flight/eslint.config.js | 12 + src/flight/nest-cli.json | 5 +- src/flight/package.json | 62 ++-- src/flight/src/aircraft/aircraft.module.ts | 37 +-- .../src/aircraft/entities/aircraft.entity.ts | 2 +- .../v1/create-aircraft/create-aircraft.ts | 161 ++++++----- src/flight/src/aircraft/mappings.ts | 4 +- src/flight/src/airport/airport.module.ts | 37 +-- .../src/airport/entities/airport.entity.ts | 2 +- .../v1/create-airport/create-airport.ts | 161 ++++++----- src/flight/src/airport/mappings.ts | 4 +- src/flight/src/app.module.ts | 115 ++++---- src/flight/src/data/data-source.ts | 24 +- .../1702506607390-create-flight-table.ts | 85 ++++-- .../data/repositories/aircraftRepository.ts | 11 +- .../data/repositories/airportRepository.ts | 11 +- .../src/data/repositories/flightRepository.ts | 11 +- .../src/data/repositories/seatRepository.ts | 13 +- src/flight/src/data/seeds/data-seeder.ts | 189 ++++++------ src/flight/src/flight/dtos/flight.dto.ts | 2 +- .../src/flight/entities/flight.entity.ts | 8 +- .../v1/create-flight/create-flight.ts | 271 +++++++++--------- .../v1/get-flight-by-id/get-flight-by-id.ts | 93 +++--- src/flight/src/flight/flight.module.ts | 83 +++--- src/flight/src/flight/mappings.ts | 2 +- src/flight/src/main.ts | 62 ++-- src/flight/src/seat/dtos/seat.dto.ts | 4 +- src/flight/src/seat/entities/seat.entity.ts | 6 +- .../features/v1/create-seat/create-seat.ts | 191 ++++++------ .../get-available-seats.ts | 43 ++- .../features/v1/reserve-seat/reserve-seat.ts | 163 ++++++----- src/flight/src/seat/mappings.ts | 4 +- src/flight/src/seat/seat.module.ts | 59 ++-- src/flight/tsconfig.json | 42 ++- src/identity/.eslintrc.js | 25 -- src/identity/.prettierignore | 3 + src/identity/.prettierrc | 10 +- src/identity/eslint.config.js | 12 + src/identity/nest-cli.json | 5 +- src/identity/package.json | 62 ++-- src/identity/src/app.module.ts | 89 +++--- src/identity/src/auth/auth.module.ts | 65 +++-- src/identity/src/auth/dtos/auth.dto.ts | 2 +- .../src/auth/entities/token.entity.ts | 48 ++-- .../src/auth/enums/token-type.enum.ts | 4 +- .../v1/generate-token/generate-token.ts | 23 +- .../src/auth/features/v1/login/login.ts | 111 ++++--- .../src/auth/features/v1/logout/logout.ts | 101 ++++--- .../v1/refresh-token/refresh-token.ts | 102 ++++--- .../v1/validate-token/validate-token.ts | 42 ++- src/identity/src/auth/mappings.ts | 5 +- src/identity/src/data/data-source.ts | 24 +- ....ts => 1735158168560-create-user-table.ts} | 6 +- .../src/data/repositories/auth.repository.ts | 39 ++- .../src/data/repositories/user.repository.ts | 23 +- src/identity/src/data/seeds/data-seeder.ts | 51 ++-- src/identity/src/main.ts | 70 ++--- src/identity/src/user/dtos/user.dto.ts | 2 +- src/identity/src/user/entities/user.entity.ts | 56 ++-- src/identity/src/user/enums/role.enum.ts | 4 +- .../features/v1/create-user/create-user.ts | 109 +++---- .../v1/delete-user-by-id/delete-user-by-id.ts | 115 ++++---- .../v1/get-user-by-id/get-user-by-id.ts | 94 +++--- .../user/features/v1/get-users/get-users.ts | 76 +++-- .../features/v1/update-user/update-user.ts | 214 +++++++------- src/identity/src/user/mapping.ts | 2 +- src/identity/src/user/user.module.ts | 57 ++-- .../user/features/create-user.test.d.ts | 1 + .../user/features/create-user.test.js | 23 ++ .../user/features/create-user.test.js.map | 1 + .../user/features/create-user.test.ts | 6 +- .../user/features/create-user.test.d.ts | 1 + .../user/features/create-user.test.js | 23 ++ .../user/features/create-user.test.js.map | 1 + .../user/features/create-user.test.ts | 6 +- .../user/fake-create-user-request.dto.d.ts | 4 + .../user/fake-create-user-request.dto.js | 22 ++ .../user/fake-create-user-request.dto.js.map | 1 + .../user/fake-create-user-request.dto.ts | 4 +- .../shared/fakes/user/fake-create-user.d.ts | 5 + .../shared/fakes/user/fake-create-user.js | 19 ++ .../shared/fakes/user/fake-create-user.js.map | 1 + .../shared/fakes/user/fake-create-user.ts | 6 +- .../shared/fakes/user/fake-user.entity.d.ts | 4 + .../shared/fakes/user/fake-user.entity.js | 26 ++ .../shared/fakes/user/fake-user.entity.js.map | 1 + .../shared/fakes/user/fake-user.entity.ts | 4 +- .../shared/fixtures/end-to-end.fixture.d.ts | 3 + .../shared/fixtures/end-to-end.fixture.js | 8 + .../shared/fixtures/end-to-end.fixture.js.map | 1 + .../shared/fixtures/end-to-end.fixture.ts | 2 +- .../fixtures/integration-test.fixture.d.ts | 25 ++ .../fixtures/integration-test.fixture.js | 95 ++++++ .../fixtures/integration-test.fixture.js.map | 1 + .../fixtures/integration-test.fixture.ts | 79 +++-- .../user/features/create-user.test.d.ts | 1 + .../user/features/create-user.test.js | 68 +++++ .../user/features/create-user.test.js.map | 1 + .../user/features/create-user.test.ts | 17 +- src/identity/tsconfig.json | 42 ++- src/passenger/.eslintrc.js | 25 -- src/passenger/.prettierignore | 3 + src/passenger/.prettierrc | 10 +- src/passenger/eslint.config.js | 12 + src/passenger/nest-cli.json | 5 +- src/passenger/package.json | 62 ++-- src/passenger/src/app.module.ts | 26 +- .../src/passenger/passenger.module.ts | 2 - src/passenger/tsconfig.json | 42 ++- 194 files changed, 3333 insertions(+), 2839 deletions(-) delete mode 100644 src/booking/.eslintrc.js create mode 100644 src/booking/.prettierignore create mode 100644 src/booking/eslint.config.js delete mode 100644 src/building-blocks/.eslintignore delete mode 100644 src/building-blocks/.eslintrc delete mode 100644 src/building-blocks/.lintstagedrc create mode 100644 src/building-blocks/.prettierignore create mode 100644 src/building-blocks/eslint.config.js delete mode 100644 src/building-blocks/tsconfig.tsbuildinfo delete mode 100644 src/flight/.eslintrc.js create mode 100644 src/flight/.prettierignore create mode 100644 src/flight/eslint.config.js delete mode 100644 src/identity/.eslintrc.js create mode 100644 src/identity/.prettierignore create mode 100644 src/identity/eslint.config.js rename src/identity/src/data/migrations/{1702504925976-create-user-table.ts => 1735158168560-create-user-table.ts} (84%) create mode 100644 src/identity/test/end-to-end-test/user/features/create-user.test.d.ts create mode 100644 src/identity/test/end-to-end-test/user/features/create-user.test.js create mode 100644 src/identity/test/end-to-end-test/user/features/create-user.test.js.map create mode 100644 src/identity/test/integration-test/user/features/create-user.test.d.ts create mode 100644 src/identity/test/integration-test/user/features/create-user.test.js create mode 100644 src/identity/test/integration-test/user/features/create-user.test.js.map create mode 100644 src/identity/test/shared/fakes/user/fake-create-user-request.dto.d.ts create mode 100644 src/identity/test/shared/fakes/user/fake-create-user-request.dto.js create mode 100644 src/identity/test/shared/fakes/user/fake-create-user-request.dto.js.map create mode 100644 src/identity/test/shared/fakes/user/fake-create-user.d.ts create mode 100644 src/identity/test/shared/fakes/user/fake-create-user.js create mode 100644 src/identity/test/shared/fakes/user/fake-create-user.js.map create mode 100644 src/identity/test/shared/fakes/user/fake-user.entity.d.ts create mode 100644 src/identity/test/shared/fakes/user/fake-user.entity.js create mode 100644 src/identity/test/shared/fakes/user/fake-user.entity.js.map create mode 100644 src/identity/test/shared/fixtures/end-to-end.fixture.d.ts create mode 100644 src/identity/test/shared/fixtures/end-to-end.fixture.js create mode 100644 src/identity/test/shared/fixtures/end-to-end.fixture.js.map create mode 100644 src/identity/test/shared/fixtures/integration-test.fixture.d.ts create mode 100644 src/identity/test/shared/fixtures/integration-test.fixture.js create mode 100644 src/identity/test/shared/fixtures/integration-test.fixture.js.map create mode 100644 src/identity/test/unit-test/user/features/create-user.test.d.ts create mode 100644 src/identity/test/unit-test/user/features/create-user.test.js create mode 100644 src/identity/test/unit-test/user/features/create-user.test.js.map delete mode 100644 src/passenger/.eslintrc.js create mode 100644 src/passenger/.prettierignore create mode 100644 src/passenger/eslint.config.js diff --git a/src/booking/.eslintrc.js b/src/booking/.eslintrc.js deleted file mode 100644 index b88d1be..0000000 --- a/src/booking/.eslintrc.js +++ /dev/null @@ -1,25 +0,0 @@ -module.exports = { - parser: '@typescript-eslint/parser', - parserOptions: { - project: 'tsconfig.json', - sourceType: 'module', - }, - plugins: ['@typescript-eslint/eslint-plugin'], - extends: [ - 'plugin:@typescript-eslint/recommended', - 'plugin:prettier/recommended', - ], - root: true, - env: { - node: true, - jest: true, - }, - ignorePatterns: ['.eslintrc.js'], - rules: { - '@typescript-eslint/interface-name-prefix': 'off', - '@typescript-eslint/explicit-function-return-type': 'off', - '@typescript-eslint/explicit-module-boundary-types': 'off', - '@typescript-eslint/no-explicit-any': 'off', - "@typescript-eslint/no-var-requires": "off" - }, -}; diff --git a/src/booking/.prettierignore b/src/booking/.prettierignore new file mode 100644 index 0000000..a7db0d7 --- /dev/null +++ b/src/booking/.prettierignore @@ -0,0 +1,3 @@ +node_modules/ +dist/ +build/ \ No newline at end of file diff --git a/src/booking/.prettierrc b/src/booking/.prettierrc index f4f39af..c6f2a11 100644 --- a/src/booking/.prettierrc +++ b/src/booking/.prettierrc @@ -1,5 +1,7 @@ { - "singleQuote": true, - "trailingComma": "all", - "tabWidth": 4 -} + "semi": true, + "tabWidth": 2, + "printWidth": 100, + "singleQuote": true, + "trailingComma": "none" +} \ No newline at end of file diff --git a/src/booking/eslint.config.js b/src/booking/eslint.config.js new file mode 100644 index 0000000..53c4d9d --- /dev/null +++ b/src/booking/eslint.config.js @@ -0,0 +1,12 @@ +// https://denar90.github.io/eslint.github.io/docs/rules/ +export default [ + { + rules: { + semi: 'error', + 'prefer-const': 'warn', + 'no-unused-vars': 'warn', + 'no-debugger': 'warn', + 'no-console': 'warn' + } + } +]; diff --git a/src/booking/nest-cli.json b/src/booking/nest-cli.json index 2e1000f..9ec46b7 100644 --- a/src/booking/nest-cli.json +++ b/src/booking/nest-cli.json @@ -1,7 +1,8 @@ { "collection": "@nestjs/schematics", - "sourceRoot": "src", + "sourceRoot": "booking/src", + "entryFile": "main", "compilerOptions": { "plugins": ["@nestjs/swagger/plugin"] } -} +} \ No newline at end of file diff --git a/src/booking/package.json b/src/booking/package.json index 2bb566b..e081540 100644 --- a/src/booking/package.json +++ b/src/booking/package.json @@ -3,13 +3,13 @@ "description": "booking service", "version": "1.0.0", "main": "src/main.ts", - "author": "Meysam Hadeli", + "author": "Meysam", "license": "MIT", "scripts": { "build": "nest build", - "dev": "tsc -p tsconfig.json && nodemon src/main.ts --watch", - "format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"", - "lint": "eslint \"{src,apps,libs,test}/**/*.ts\" --fix", + "dev": "nest start --watch", + "format": "prettier --write \"**/*.{ts,js}\"", + "lint": "eslint . --fix", "typeorm": "npm run build && npx typeorm -d ./dist/data/data-source.js", "migration:generate": "npm run typeorm -- migration:generate", "migration:run": "npm run typeorm -- migration:run", @@ -17,40 +17,42 @@ "test": "jest" }, "dependencies": { - "@nestjs/cli": "10.2.1", - "@nestjs/config": "^3.1.1", - "@nestjs/core": "10.2.10", - "@nestjs/cqrs": "^10.2.6", + "@nestjs/cli": "10.4.9", + "@nestjs/config": "^3.3.0", + "@nestjs/core": "10.4.15", + "@nestjs/cqrs": "^10.2.8", "@nestjs/jwt": "^10.2.0", - "@nestjs/mapped-types": "2.0.4", - "@nestjs/microservices": "^10.2.10", - "@nestjs/passport": "^10.0.2", - "@nestjs/platform-express": "^10.2.10", - "@nestjs/schematics": "10.0.3", - "@nestjs/swagger": "^7.1.16", - "@nestjs/terminus": "^10.1.1", - "@nestjs/testing": "10.2.10", - "@nestjs/typeorm": "^10.0.1", - "axios": "^1.6.2", + "@nestjs/mapped-types": "2.0.6", + "@nestjs/microservices": "^10.4.15", + "@nestjs/passport": "^10.0.3", + "@nestjs/platform-express": "^10.4.15", + "@nestjs/schematics": "10.2.3", + "@nestjs/swagger": "^8.1.0", + "@nestjs/terminus": "^10.2.3", + "@nestjs/testing": "10.4.15", + "@nestjs/typeorm": "^10.0.2", + "axios": "^1.7.9", "building-blocks": "file:../building-blocks", "class-transformer": "^0.5.1", - "class-validator": "^0.14.0", - "joi": "^17.10.1", - "moment": "^2.29.4", - "nodemon": "^3.0.2", - "pg": "^8.11.3", - "testcontainers": "^10.3.2", + "class-validator": "^0.14.1", + "joi": "^17.13.3", + "moment": "^2.30.1", + "nodemon": "^3.1.9", + "pg": "^8.13.1", + "testcontainers": "^10.16.0", "ts-mapper": "^1.2.4" }, "devDependencies": { - "@faker-js/faker": "^8.3.1", - "@types/express": "^4.17.21", - "@types/jest": "29.5.10", - "@types/supertest": "2.0.16", + "@faker-js/faker": "^9.3.0", + "@types/express": "^5.0.0", + "@types/jest": "29.5.14", + "@types/supertest": "6.0.2", "jest": "29.7.0", "jest-serial-runner": "^1.2.1", - "supertest": "6.3.3", - "ts-jest": "29.1.1", - "typemoq": "^2.1.0" + "supertest": "7.0.0", + "ts-jest": "29.2.5", + "typemoq": "^2.1.0", + "prettier": "3.4.2", + "eslint": "9.17.0" } } diff --git a/src/booking/src/app.module.ts b/src/booking/src/app.module.ts index 7c5ea92..6e49d51 100644 --- a/src/booking/src/app.module.ts +++ b/src/booking/src/app.module.ts @@ -1,38 +1,36 @@ -import {RouterModule} from '@nestjs/core'; -import {TypeOrmModule} from '@nestjs/typeorm'; -import {postgresOptions} from './data/data-source'; -import {PassportModule} from "@nestjs/passport"; -import {JwtModule} from "@nestjs/jwt"; -import {OpenTelemetryModule} from "building-blocks/openTelemetry/open-telemetry.module"; -import {JwtStrategy} from "building-blocks/passport/jwt.strategy"; -import {BookingModule} from "./booking/booking.module"; -import configs from "building-blocks/configs/configs"; -import {MiddlewareConsumer, Module, NestModule} from "@nestjs/common"; -import {HttpContextMiddleware} from "building-blocks/context/context"; +import { RouterModule } from '@nestjs/core'; +import { TypeOrmModule } from '@nestjs/typeorm'; +import { postgresOptions } from './data/data-source'; +import { PassportModule } from '@nestjs/passport'; +import { JwtModule } from '@nestjs/jwt'; +import { OpenTelemetryModule } from 'building-blocks/openTelemetry/open-telemetry.module'; +import { JwtStrategy } from 'building-blocks/passport/jwt.strategy'; +import { BookingModule } from './booking/booking.module'; +import configs from 'building-blocks/configs/configs'; +import { MiddlewareConsumer, Module, NestModule } from '@nestjs/common'; +import { HttpContextMiddleware } from 'building-blocks/context/context'; @Module({ - imports: [ - PassportModule, - JwtModule.register({ - secret: configs.jwt.secret, - signOptions: {expiresIn: configs.jwt.refreshExpirationDays}, - }), - OpenTelemetryModule.forRoot(), - TypeOrmModule.forRoot(postgresOptions), - BookingModule, - RouterModule.register([ - { - path: '/', - module: BookingModule, - } - ]), - ], - providers: [JwtStrategy], + imports: [ + PassportModule, + JwtModule.register({ + secret: configs.jwt.secret, + signOptions: { expiresIn: configs.jwt.refreshExpirationDays } + }), + OpenTelemetryModule.forRoot(), + TypeOrmModule.forRoot(postgresOptions), + BookingModule, + RouterModule.register([ + { + path: '/', + module: BookingModule + } + ]) + ], + providers: [JwtStrategy] }) export class AppModule implements NestModule { - configure(consumer: MiddlewareConsumer) { - consumer - .apply(HttpContextMiddleware) - .forRoutes('*'); - } + configure(consumer: MiddlewareConsumer) { + consumer.apply(HttpContextMiddleware).forRoutes('*'); + } } diff --git a/src/booking/src/booking/booking.module.ts b/src/booking/src/booking/booking.module.ts index a932b2b..3fe6d42 100644 --- a/src/booking/src/booking/booking.module.ts +++ b/src/booking/src/booking/booking.module.ts @@ -1,32 +1,34 @@ -import {Module} from '@nestjs/common'; -import {CqrsModule} from '@nestjs/cqrs'; -import {TypeOrmModule} from '@nestjs/typeorm'; -import {RabbitmqModule} from "building-blocks/rabbitmq/rabbitmq.module"; -import {Booking} from "./entities/booking.entity"; -import {BookingRepository} from "../data/repositories/booking.repository"; -import {PassengerClient} from "./http-client/services/passenger/passenger-client"; -import {FlightClient} from "./http-client/services/flight/flight.client"; -import {CreateBookingController, CreateBookingHandler} from "./features/v1/create-booking/create-booking"; - - +import { Module } from '@nestjs/common'; +import { CqrsModule } from '@nestjs/cqrs'; +import { TypeOrmModule } from '@nestjs/typeorm'; +import { RabbitmqModule } from 'building-blocks/rabbitmq/rabbitmq.module'; +import { Booking } from './entities/booking.entity'; +import { BookingRepository } from '../data/repositories/booking.repository'; +import { PassengerClient } from './http-client/services/passenger/passenger-client'; +import { FlightClient } from './http-client/services/flight/flight.client'; +import { + CreateBookingController, + CreateBookingHandler +} from './features/v1/create-booking/create-booking'; @Module({ - imports: [CqrsModule, RabbitmqModule.forRoot(), TypeOrmModule.forFeature([Booking])], - controllers: [CreateBookingController], - providers: [ CreateBookingHandler, - { - provide: 'IBookingRepository', - useClass: BookingRepository, - }, - { - provide: 'IPassengerClient', - useClass: PassengerClient, - }, - { - provide: 'IFlightClient', - useClass: FlightClient, - } - ], - exports: [], + imports: [CqrsModule, RabbitmqModule.forRoot(), TypeOrmModule.forFeature([Booking])], + controllers: [CreateBookingController], + providers: [ + CreateBookingHandler, + { + provide: 'IBookingRepository', + useClass: BookingRepository + }, + { + provide: 'IPassengerClient', + useClass: PassengerClient + }, + { + provide: 'IFlightClient', + useClass: FlightClient + } + ], + exports: [] }) export class BookingModule {} diff --git a/src/booking/src/booking/dtos/booking.dto.ts b/src/booking/src/booking/dtos/booking.dto.ts index 32aa6a0..2477e1b 100644 --- a/src/booking/src/booking/dtos/booking.dto.ts +++ b/src/booking/src/booking/dtos/booking.dto.ts @@ -1,14 +1,14 @@ export class BookingDto { - id: number; - flightNumber: string; - aircraftId: number; - departureAirportId: number; - arriveAirportId: number; - flightDate: Date; - price: number; - description: string; - seatNumber: string; - passengerName: string; - createdAt: Date; - updatedAt?: Date | null; + id: number; + flightNumber: string; + aircraftId: number; + departureAirportId: number; + arriveAirportId: number; + flightDate: Date; + price: number; + description: string; + seatNumber: string; + passengerName: string; + createdAt: Date; + updatedAt?: Date | null; } diff --git a/src/booking/src/booking/entities/booking.entity.ts b/src/booking/src/booking/entities/booking.entity.ts index 292ed79..add2a8c 100644 --- a/src/booking/src/booking/entities/booking.entity.ts +++ b/src/booking/src/booking/entities/booking.entity.ts @@ -2,44 +2,44 @@ import { Column, Entity, ManyToOne, PrimaryGeneratedColumn } from 'typeorm'; @Entity() export class Booking { - @PrimaryGeneratedColumn() - id: number; + @PrimaryGeneratedColumn() + id: number; - @Column() - flightNumber: string; + @Column() + flightNumber: string; - @Column() - aircraftId: number; + @Column() + aircraftId: number; - @Column() - departureAirportId: number; + @Column() + departureAirportId: number; - @Column() - arriveAirportId: number; + @Column() + arriveAirportId: number; - @Column() - flightDate: Date; + @Column() + flightDate: Date; - @Column() - price: number; + @Column() + price: number; - @Column() - description: string; + @Column() + description: string; - @Column() - seatNumber: string; + @Column() + seatNumber: string; - @Column() - passengerName: string; + @Column() + passengerName: string; - @Column() - createdAt: Date; + @Column() + createdAt: Date; - @Column({ nullable: true }) - updatedAt?: Date | null; + @Column({ nullable: true }) + updatedAt?: Date | null; - constructor(partial?: Partial) { - Object.assign(this, partial); - this.createdAt = partial?.createdAt ?? new Date(); - } + constructor(partial?: Partial) { + Object.assign(this, partial); + this.createdAt = partial?.createdAt ?? new Date(); + } } diff --git a/src/booking/src/booking/features/v1/create-booking/create-booking.ts b/src/booking/src/booking/features/v1/create-booking/create-booking.ts index 548d528..e6bbf30 100644 --- a/src/booking/src/booking/features/v1/create-booking/create-booking.ts +++ b/src/booking/src/booking/features/v1/create-booking/create-booking.ts @@ -1,124 +1,131 @@ -import Joi from "joi"; -import {ApiBearerAuth, ApiProperty, ApiResponse, ApiTags} from "@nestjs/swagger"; -import {Body, Controller, HttpStatus, Inject, NotFoundException, Post, Res, UseGuards} from "@nestjs/common"; -import {CommandBus, CommandHandler, ICommandHandler} from "@nestjs/cqrs"; -import {BookingDto} from "../../../dtos/booking.dto"; -import {JwtGuard} from "building-blocks/passport/jwt.guard"; -import {Response} from "express"; -import {IRabbitmqPublisher} from "building-blocks/rabbitmq/rabbitmq-publisher"; -import {IFlightClient} from "../../../http-client/services/flight/flight.client"; -import {IPassengerClient} from "../../../http-client/services/passenger/passenger-client"; -import {IBookingRepository} from "../../../../data/repositories/booking.repository"; -import {Booking} from "../../../entities/booking.entity"; -import {BookingCreated} from "building-blocks/contracts/booking.contract"; -import mapper from "../../../mappings"; +import Joi from 'joi'; +import { ApiBearerAuth, ApiProperty, ApiResponse, ApiTags } from '@nestjs/swagger'; +import { + Body, + Controller, + HttpStatus, + Inject, + NotFoundException, + Post, + Res, + UseGuards +} from '@nestjs/common'; +import { CommandBus, CommandHandler, ICommandHandler } from '@nestjs/cqrs'; +import { BookingDto } from '../../../dtos/booking.dto'; +import { JwtGuard } from 'building-blocks/passport/jwt.guard'; +import { Response } from 'express'; +import { IRabbitmqPublisher } from 'building-blocks/rabbitmq/rabbitmq-publisher'; +import { IFlightClient } from '../../../http-client/services/flight/flight.client'; +import { IPassengerClient } from '../../../http-client/services/passenger/passenger-client'; +import { IBookingRepository } from '../../../../data/repositories/booking.repository'; +import { Booking } from '../../../entities/booking.entity'; +import { BookingCreated } from 'building-blocks/contracts/booking.contract'; +import mapper from '../../../mappings'; export class CreateBooking { - passengerId: number; - flightId: number; - description: string; + passengerId: number; + flightId: number; + description: string; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } - export class CreateBookingRequestDto { - @ApiProperty() - passengerId: number; + @ApiProperty() + passengerId: number; - @ApiProperty() - flightId: number; + @ApiProperty() + flightId: number; - @ApiProperty() - description: string; + @ApiProperty() + description: string; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } const createBookingValidations = Joi.object({ - passengerId: Joi.number().required(), - flightId: Joi.number().required(), - description: Joi.string().required() + passengerId: Joi.number().required(), + flightId: Joi.number().required(), + description: Joi.string().required() }); @ApiBearerAuth() @ApiTags('Bookings') @Controller({ - path: `/booking`, - version: '1', + path: `/booking`, + version: '1' }) export class CreateBookingController { - - constructor(private readonly commandBus: CommandBus) {} - - @Post('create') - @UseGuards(JwtGuard) - @ApiResponse({status: 401, description: 'UNAUTHORIZED'}) - @ApiResponse({status: 400, description: 'BAD_REQUEST'}) - @ApiResponse({status: 403, description: 'FORBIDDEN'}) - @ApiResponse({status: 201, description: 'CREATED'}) - public async createBooking(@Body() request: CreateBookingRequestDto, @Res() res: Response): Promise { - const result = await this.commandBus.execute(new CreateBooking(request)); - - res.status(HttpStatus.CREATED).send(result); - - return result; - } + constructor(private readonly commandBus: CommandBus) {} + + @Post('create') + @UseGuards(JwtGuard) + @ApiResponse({ status: 401, description: 'UNAUTHORIZED' }) + @ApiResponse({ status: 400, description: 'BAD_REQUEST' }) + @ApiResponse({ status: 403, description: 'FORBIDDEN' }) + @ApiResponse({ status: 201, description: 'CREATED' }) + public async createBooking( + @Body() request: CreateBookingRequestDto, + @Res() res: Response + ): Promise { + const result = await this.commandBus.execute(new CreateBooking(request)); + + res.status(HttpStatus.CREATED).send(result); + + return result; + } } @CommandHandler(CreateBooking) export class CreateBookingHandler implements ICommandHandler { + constructor( + private readonly commandBus: CommandBus, + @Inject('IBookingRepository') private bookingRepository: IBookingRepository, + @Inject('IFlightClient') private flightClient: IFlightClient, + @Inject('IPassengerClient') private passengerClient: IPassengerClient, + @Inject('IRabbitmqPublisher') private rabbitmqPublisher: IRabbitmqPublisher + ) {} - constructor( - private readonly commandBus: CommandBus, - @Inject('IBookingRepository') private bookingRepository: IBookingRepository, - @Inject('IFlightClient') private flightClient: IFlightClient, - @Inject('IPassengerClient') private passengerClient: IPassengerClient, - @Inject('IRabbitmqPublisher') private rabbitmqPublisher: IRabbitmqPublisher - ) {} - - async execute(command: CreateBooking): Promise { + async execute(command: CreateBooking): Promise { + await createBookingValidations.validateAsync(command); - await createBookingValidations.validateAsync(command); + const flightDto = await this.flightClient.getFlightById(command.flightId); - const flightDto = await this.flightClient.getFlightById(command.flightId); + const passengerDto = await this.passengerClient.getPassengerById(command.passengerId); - const passengerDto = await this.passengerClient.getPassengerById(command.passengerId); - - const avalibaleSeats = await this.flightClient.getAvalibaleSeats(command.flightId); - - if (avalibaleSeats.length == 0) { - throw new NotFoundException('No seat available!'); - } - - await this.flightClient.reserveSeat({ - seatNumber: avalibaleSeats[0]?.seatNumber, - flightId: flightDto?.id - }); - - const bookingEntity = await this.bookingRepository.createBooking( - new Booking({ - seatNumber: avalibaleSeats[0]?.seatNumber, - flightNumber: flightDto?.flightNumber, - price: flightDto?.price, - passengerName: passengerDto?.name, - description: command?.description, - flightDate: flightDto?.flightDate, - aircraftId: flightDto?.aircraftId, - departureAirportId: flightDto?.departureAirportId, - arriveAirportId: flightDto?.arriveAirportId - }) - ); - - await this.rabbitmqPublisher.publishMessage(new BookingCreated(bookingEntity)); - - const result = mapper.map(bookingEntity, new BookingDto()); - - return result; + const avalibaleSeats = await this.flightClient.getAvalibaleSeats(command.flightId); + if (avalibaleSeats.length == 0) { + throw new NotFoundException('No seat available!'); } -} \ No newline at end of file + + await this.flightClient.reserveSeat({ + seatNumber: avalibaleSeats[0]?.seatNumber, + flightId: flightDto?.id + }); + + const bookingEntity = await this.bookingRepository.createBooking( + new Booking({ + seatNumber: avalibaleSeats[0]?.seatNumber, + flightNumber: flightDto?.flightNumber, + price: flightDto?.price, + passengerName: passengerDto?.name, + description: command?.description, + flightDate: flightDto?.flightDate, + aircraftId: flightDto?.aircraftId, + departureAirportId: flightDto?.departureAirportId, + arriveAirportId: flightDto?.arriveAirportId + }) + ); + + await this.rabbitmqPublisher.publishMessage(new BookingCreated(bookingEntity)); + + const result = mapper.map(bookingEntity, new BookingDto()); + + return result; + } +} diff --git a/src/booking/src/booking/http-client/services/flight/flight.client.ts b/src/booking/src/booking/http-client/services/flight/flight.client.ts index 4cf4c6e..a91d9b7 100644 --- a/src/booking/src/booking/http-client/services/flight/flight.client.ts +++ b/src/booking/src/booking/http-client/services/flight/flight.client.ts @@ -1,59 +1,62 @@ import axios from 'axios'; -import {FlightDto, ReserveSeatRequestDto, SeatDto} from "building-blocks/contracts/flight.contract"; -import {Injectable} from "@nestjs/common"; -import {HttpContext} from "building-blocks/context/context"; -import * as https from "https"; -import {AxiosInstance} from "axios/index"; +import { + FlightDto, + ReserveSeatRequestDto, + SeatDto +} from 'building-blocks/contracts/flight.contract'; +import { Injectable } from '@nestjs/common'; +import { HttpContext } from 'building-blocks/context/context'; +import * as https from 'https'; +import { AxiosInstance } from 'axios/index'; export interface IFlightClient { - getFlightById(id: number): Promise; + getFlightById(id: number): Promise; - getAvalibaleSeats(flightId: number): Promise; + getAvalibaleSeats(flightId: number): Promise; - reserveSeat(request: ReserveSeatRequestDto): Promise; + reserveSeat(request: ReserveSeatRequestDto): Promise; } @Injectable() export class FlightClient implements IFlightClient { - - private readonly client: AxiosInstance; - constructor() { - this.client = axios.create({ - baseURL: 'http://localhost:3344', - timeout: 60000, - maxContentLength: 500 * 1000 * 1000, - httpsAgent: new https.Agent({keepAlive: true}), - }); - } - - async getFlightById(id: number): Promise { - const result = await this.client - .get(`/api/v1/flight/get-by-id?id=${id}`, { - headers: { - Authorization: HttpContext.headers.authorization.toString() - } - }); - - return result?.data; - } - - async getAvalibaleSeats(flightId: number): Promise { - const result = await this.client - .get(`/api/v1/seat/get-available-seats?flightId=${flightId}`, { - headers: { - Authorization: HttpContext.headers.authorization.toString() - } - }); - - return result?.data; - } - - async reserveSeat(request: ReserveSeatRequestDto): Promise { - await this.client - .post(`/api/v1/seat/reserve`, request, { - headers: { - Authorization: HttpContext.headers.authorization.toString() - } - }); - } + private readonly client: AxiosInstance; + constructor() { + this.client = axios.create({ + baseURL: 'http://localhost:3344', + timeout: 60000, + maxContentLength: 500 * 1000 * 1000, + httpsAgent: new https.Agent({ keepAlive: true }) + }); + } + + async getFlightById(id: number): Promise { + const result = await this.client.get(`/api/v1/flight/get-by-id?id=${id}`, { + headers: { + Authorization: HttpContext.headers.authorization.toString() + } + }); + + return result?.data; + } + + async getAvalibaleSeats(flightId: number): Promise { + const result = await this.client.get( + `/api/v1/seat/get-available-seats?flightId=${flightId}`, + { + headers: { + Authorization: HttpContext.headers.authorization.toString() + } + } + ); + + return result?.data; + } + + async reserveSeat(request: ReserveSeatRequestDto): Promise { + await this.client.post(`/api/v1/seat/reserve`, request, { + headers: { + Authorization: HttpContext.headers.authorization.toString() + } + }); + } } diff --git a/src/booking/src/booking/http-client/services/passenger/passenger-client.ts b/src/booking/src/booking/http-client/services/passenger/passenger-client.ts index 31bfc61..a933a39 100644 --- a/src/booking/src/booking/http-client/services/passenger/passenger-client.ts +++ b/src/booking/src/booking/http-client/services/passenger/passenger-client.ts @@ -1,8 +1,8 @@ -import axios, {AxiosInstance} from 'axios'; -import {PassengerDto} from "building-blocks/contracts/passenger.contract"; -import {Injectable} from "@nestjs/common"; -import {HttpContext} from "building-blocks/context/context"; -import https from "https"; +import axios, { AxiosInstance } from 'axios'; +import { PassengerDto } from 'building-blocks/contracts/passenger.contract'; +import { Injectable } from '@nestjs/common'; +import { HttpContext } from 'building-blocks/context/context'; +import https from 'https'; export interface IPassengerClient { getPassengerById(id: number): Promise; @@ -10,25 +10,23 @@ export interface IPassengerClient { @Injectable() export class PassengerClient implements IPassengerClient { - private readonly client: AxiosInstance; + private readonly client: AxiosInstance; - constructor() { - this.client = axios.create({ - baseURL: 'http://localhost:3355', - timeout: 60000, - maxContentLength: 500 * 1000 * 1000, - httpsAgent: new https.Agent({ keepAlive: true }), - }); - } + constructor() { + this.client = axios.create({ + baseURL: 'http://localhost:3355', + timeout: 60000, + maxContentLength: 500 * 1000 * 1000, + httpsAgent: new https.Agent({ keepAlive: true }) + }); + } async getPassengerById(id: number): Promise { - - const result = await this.client - .get(`/api/v1/passenger/get-by-id?id=${id}`, { - headers: { - Authorization: HttpContext.headers.authorization.toString() - } - }); + const result = await this.client.get(`/api/v1/passenger/get-by-id?id=${id}`, { + headers: { + Authorization: HttpContext.headers.authorization.toString() + } + }); return result?.data; } diff --git a/src/booking/src/booking/mappings.ts b/src/booking/src/booking/mappings.ts index 9579bc0..84472d7 100644 --- a/src/booking/src/booking/mappings.ts +++ b/src/booking/src/booking/mappings.ts @@ -1,64 +1,64 @@ import { TypeMapper } from 'ts-mapper'; -import {Booking} from "./entities/booking.entity"; -import {BookingDto} from "./dtos/booking.dto"; +import { Booking } from './entities/booking.entity'; +import { BookingDto } from './dtos/booking.dto'; export class Mapper extends TypeMapper { - constructor() { - super(); - this.config(); - } + constructor() { + super(); + this.config(); + } - private config(): void { - this.createMap() - .map( - (src) => src.id, - (dest) => dest.id - ) - .map( - (src) => src.createdAt, - (dest) => dest.createdAt - ) - .map( - (src) => src?.updatedAt, - (dest) => dest?.updatedAt - ) - .map( - (src) => src.aircraftId, - (dest) => dest.aircraftId - ) - .map( - (src) => src.arriveAirportId, - (dest) => dest.arriveAirportId - ) - .map( - (src) => src.departureAirportId, - (dest) => dest.departureAirportId - ) - .map( - (src) => src.flightDate, - (dest) => dest.flightDate - ) - .map( - (src) => src.description, - (dest) => dest.description - ) - .map( - (src) => src.flightNumber, - (dest) => dest.flightNumber - ) - .map( - (src) => src.passengerName, - (dest) => dest.passengerName - ) - .map( - (src) => src.price, - (dest) => dest.price - ) - .map( - (src) => src.seatNumber, - (dest) => dest.seatNumber - ); - } + private config(): void { + this.createMap() + .map( + (src) => src.id, + (dest) => dest.id + ) + .map( + (src) => src.createdAt, + (dest) => dest.createdAt + ) + .map( + (src) => src?.updatedAt, + (dest) => dest?.updatedAt + ) + .map( + (src) => src.aircraftId, + (dest) => dest.aircraftId + ) + .map( + (src) => src.arriveAirportId, + (dest) => dest.arriveAirportId + ) + .map( + (src) => src.departureAirportId, + (dest) => dest.departureAirportId + ) + .map( + (src) => src.flightDate, + (dest) => dest.flightDate + ) + .map( + (src) => src.description, + (dest) => dest.description + ) + .map( + (src) => src.flightNumber, + (dest) => dest.flightNumber + ) + .map( + (src) => src.passengerName, + (dest) => dest.passengerName + ) + .map( + (src) => src.price, + (dest) => dest.price + ) + .map( + (src) => src.seatNumber, + (dest) => dest.seatNumber + ); + } } const mapper = new Mapper(); diff --git a/src/booking/src/data/data-source.ts b/src/booking/src/data/data-source.ts index 2d6c946..b712de2 100644 --- a/src/booking/src/data/data-source.ts +++ b/src/booking/src/data/data-source.ts @@ -1,19 +1,19 @@ import { DataSource, DataSourceOptions } from 'typeorm'; -import configs from "building-blocks/configs/configs"; +import configs from 'building-blocks/configs/configs'; // use this file for running migration export const postgresOptions: DataSourceOptions = { - type: 'postgres', - host: configs.postgres.host, - port: configs.postgres.port, - username: configs.postgres.username, - password: configs.postgres.password, - database: configs.postgres.database, - synchronize: configs.postgres.synchronize, - entities: [__dirname + configs.postgres.entities], - migrations: [__dirname + configs.postgres.migrations], - logging: configs.postgres.logging, - migrationsRun: configs.postgres.migrationsRun + type: 'postgres', + host: configs.postgres.host, + port: configs.postgres.port, + username: configs.postgres.username, + password: configs.postgres.password, + database: configs.postgres.database, + synchronize: configs.postgres.synchronize, + entities: [__dirname + configs.postgres.entities], + migrations: [__dirname + configs.postgres.migrations], + logging: configs.postgres.logging, + migrationsRun: configs.postgres.migrationsRun }; const dataSource = new DataSource(postgresOptions); diff --git a/src/booking/src/data/migrations/1702506382196-create-booking-table.ts b/src/booking/src/data/migrations/1702506382196-create-booking-table.ts index fe5b7d5..1d3100a 100644 --- a/src/booking/src/data/migrations/1702506382196-create-booking-table.ts +++ b/src/booking/src/data/migrations/1702506382196-create-booking-table.ts @@ -1,14 +1,15 @@ -import { MigrationInterface, QueryRunner } from "typeorm"; +import { MigrationInterface, QueryRunner } from 'typeorm'; export class CreateBookingTable1702506382196 implements MigrationInterface { - name = 'CreateBookingTable1702506382196' + name = 'CreateBookingTable1702506382196'; - public async up(queryRunner: QueryRunner): Promise { - await queryRunner.query(`CREATE TABLE "booking" ("id" SERIAL NOT NULL, "flightNumber" character varying NOT NULL, "aircraftId" integer NOT NULL, "departureAirportId" integer NOT NULL, "arriveAirportId" integer NOT NULL, "flightDate" TIMESTAMP NOT NULL, "price" integer NOT NULL, "description" character varying NOT NULL, "seatNumber" character varying NOT NULL, "passengerName" character varying NOT NULL, "createdAt" TIMESTAMP NOT NULL, "updatedAt" TIMESTAMP, CONSTRAINT "PK_49171efc69702ed84c812f33540" PRIMARY KEY ("id"))`); - } - - public async down(queryRunner: QueryRunner): Promise { - await queryRunner.query(`DROP TABLE "booking"`); - } + public async up(queryRunner: QueryRunner): Promise { + await queryRunner.query( + `CREATE TABLE "booking" ("id" SERIAL NOT NULL, "flightNumber" character varying NOT NULL, "aircraftId" integer NOT NULL, "departureAirportId" integer NOT NULL, "arriveAirportId" integer NOT NULL, "flightDate" TIMESTAMP NOT NULL, "price" integer NOT NULL, "description" character varying NOT NULL, "seatNumber" character varying NOT NULL, "passengerName" character varying NOT NULL, "createdAt" TIMESTAMP NOT NULL, "updatedAt" TIMESTAMP, CONSTRAINT "PK_49171efc69702ed84c812f33540" PRIMARY KEY ("id"))` + ); + } + public async down(queryRunner: QueryRunner): Promise { + await queryRunner.query(`DROP TABLE "booking"`); + } } diff --git a/src/booking/src/data/repositories/booking.repository.ts b/src/booking/src/data/repositories/booking.repository.ts index 0f3775c..6e9a1ff 100644 --- a/src/booking/src/data/repositories/booking.repository.ts +++ b/src/booking/src/data/repositories/booking.repository.ts @@ -1,17 +1,18 @@ import { Repository } from 'typeorm'; -import {InjectRepository} from "@nestjs/typeorm"; -import {Booking} from "../../booking/entities/booking.entity"; +import { InjectRepository } from '@nestjs/typeorm'; +import { Booking } from '../../booking/entities/booking.entity'; export interface IBookingRepository { createBooking(booking: Booking): Promise; } export class BookingRepository implements IBookingRepository { - constructor(@InjectRepository(Booking) - private readonly bookingRepository: Repository) { - } + constructor( + @InjectRepository(Booking) + private readonly bookingRepository: Repository + ) {} async createBooking(booking: Booking): Promise { - return await this.bookingRepository.save(booking); + return await this.bookingRepository.save(booking); } } diff --git a/src/booking/src/main.ts b/src/booking/src/main.ts index 503bacf..288a484 100644 --- a/src/booking/src/main.ts +++ b/src/booking/src/main.ts @@ -2,48 +2,47 @@ import { NestFactory } from '@nestjs/core'; import { AppModule } from './app.module'; import { Logger, ValidationPipe, VersioningType } from '@nestjs/common'; import { DocumentBuilder, SwaggerModule } from '@nestjs/swagger'; -import {PrometheusMetrics} from "building-blocks/monitoring/prometheus.metrics"; -import {ErrorHandlersFilter} from "building-blocks/filters/error-handlers.filter"; -import configs from "building-blocks/configs/configs"; -import {Request, Response} from "express"; - +import { PrometheusMetrics } from 'building-blocks/monitoring/prometheus.metrics'; +import { ErrorHandlersFilter } from 'building-blocks/filters/error-handlers.filter'; +import configs from 'building-blocks/configs/configs'; +import { Request, Response } from 'express'; async function bootstrap() { - const app = await NestFactory.create(AppModule); + const app = await NestFactory.create(AppModule); - app.enableShutdownHooks(); + app.enableShutdownHooks(); - const globalPrefix = 'api'; - app.setGlobalPrefix(globalPrefix); - const port = configs.port || 3366; + const globalPrefix = 'api'; + app.setGlobalPrefix(globalPrefix); + const port = configs.port || 3366; - app.enableVersioning({ - type: VersioningType.URI, - }); + app.enableVersioning({ + type: VersioningType.URI + }); - const config = new DocumentBuilder() - .setTitle(`${configs.serviceName}`) - .setDescription(`${configs.serviceName} api description`) - .setVersion('1.0') - .addBearerAuth() - .build(); - const document = SwaggerModule.createDocument(app, config); - SwaggerModule.setup('swagger', app, document); + const config = new DocumentBuilder() + .setTitle(`${configs.serviceName}`) + .setDescription(`${configs.serviceName} api description`) + .setVersion('1.0') + .addBearerAuth() + .build(); + const document = SwaggerModule.createDocument(app, config); + SwaggerModule.setup('swagger', app, document); - app.useGlobalPipes(new ValidationPipe({ transform: true })); + app.useGlobalPipes(new ValidationPipe({ transform: true })); - app.use((req: Request, res: Response, next: any) => { - if (req.originalUrl == '/' || req.originalUrl.includes('favicon.ico')) { - return res.send(configs.serviceName); - } - return next(); - }); + app.use((req: Request, res: Response, next: any) => { + if (req.originalUrl == '/' || req.originalUrl.includes('favicon.ico')) { + return res.send(configs.serviceName); + } + return next(); + }); - PrometheusMetrics.registerMetricsEndpoint(app); + PrometheusMetrics.registerMetricsEndpoint(app); - app.useGlobalFilters(new ErrorHandlersFilter()); + app.useGlobalFilters(new ErrorHandlersFilter()); - await app.listen(port); - Logger.log(`🚀 Application is running on: http://localhost:${port}`); + await app.listen(port); + Logger.log(`🚀 Application is running on: http://localhost:${port}`); } bootstrap(); diff --git a/src/booking/tsconfig.json b/src/booking/tsconfig.json index a9f66b1..cff40bc 100644 --- a/src/booking/tsconfig.json +++ b/src/booking/tsconfig.json @@ -1,16 +1,32 @@ { "compilerOptions": { - "module": "commonjs", - "declaration": true, - "removeComments": true, - "emitDecoratorMetadata": true, - "experimentalDecorators": true, - "allowSyntheticDefaultImports": true, - "target": "es2017", - "sourceMap": true, - "outDir": "./dist", - "baseUrl": "./", - "incremental": true, - "esModuleInterop": true + // Language and Environment + "target": "es2022", // Modern JavaScript features + "module": "commonjs", // Module system for Node.js + "lib": ["es2022"], // Include all ES2022 features + + // Modules and Output + "moduleResolution": "node", // Use Node.js module resolution + "baseUrl": "./", // Base directory for paths + "outDir": "./dist", // Output directory + "removeComments": true, // Remove comments in output + + // Decorators (needed for NestJS) + "experimentalDecorators": true, // Enable decorators + "emitDecoratorMetadata": true, // Emit decorator metadata + + // Type Checking + "strict": false, // Enable all strict type checking + "skipLibCheck": true, // Skip type checking of declaration files + "forceConsistentCasingInFileNames": true, // Ensure consistent casing in imports + + // Interop Constraints + "esModuleInterop": true, // Enable ES Module interop + "allowSyntheticDefaultImports": true, // Allow default imports from modules + + // Advanced + "incremental": true, // Enable incremental compilation + "preserveConstEnums": true, // Keep const enums in output + "resolveJsonModule": true // Allow importing JSON files } -} +} \ No newline at end of file diff --git a/src/building-blocks/.eslintignore b/src/building-blocks/.eslintignore deleted file mode 100644 index 9e87c05..0000000 --- a/src/building-blocks/.eslintignore +++ /dev/null @@ -1,2 +0,0 @@ -node_modules -bin \ No newline at end of file diff --git a/src/building-blocks/.eslintrc b/src/building-blocks/.eslintrc deleted file mode 100644 index 580b595..0000000 --- a/src/building-blocks/.eslintrc +++ /dev/null @@ -1,16 +0,0 @@ -{ - "parser": "@typescript-eslint/parser", - "extends": [ - "plugin:@typescript-eslint/recommended", - "plugin:prettier/recommended" - ], - "parserOptions": { - "ecmaVersion": 2018, - "sourceType": "module" - }, - "rules": { - "@typescript-eslint/no-explicit-any": "off", - "@typescript-eslint/no-var-requires": "off", - "@typescript-eslint/no-unused-vars": "off" - } -} diff --git a/src/building-blocks/.lintstagedrc b/src/building-blocks/.lintstagedrc deleted file mode 100644 index c49a88c..0000000 --- a/src/building-blocks/.lintstagedrc +++ /dev/null @@ -1,3 +0,0 @@ -{ - "*.ts": "eslint" -} \ No newline at end of file diff --git a/src/building-blocks/.prettierignore b/src/building-blocks/.prettierignore new file mode 100644 index 0000000..a7db0d7 --- /dev/null +++ b/src/building-blocks/.prettierignore @@ -0,0 +1,3 @@ +node_modules/ +dist/ +build/ \ No newline at end of file diff --git a/src/building-blocks/configs/configs.js b/src/building-blocks/configs/configs.js index 1a08bef..a40ba4b 100644 --- a/src/building-blocks/configs/configs.js +++ b/src/building-blocks/configs/configs.js @@ -11,8 +11,7 @@ dotenv_1.default.config({ path: path_1.default.join(process.cwd(), `.env.${nodeE dotenv_1.default.config({ override: true }); const envVarsSchema = joi_1.default.object() .keys({ - NODE_ENV: joi_1.default.string() - .required(), + NODE_ENV: joi_1.default.string().required(), SERVICE_NAME: joi_1.default.string(), PORT: joi_1.default.number().default(3000), JWT_SECRET: joi_1.default.string() @@ -25,16 +24,10 @@ const envVarsSchema = joi_1.default.object() JWT_REFRESH_EXPIRATION_DAYS: joi_1.default.string() .default('1 days') .description('days after which refresh tokens expire'), - POSTGRES_HOST: joi_1.default.string() - .default('localhost') - .description('Postgres host'), + POSTGRES_HOST: joi_1.default.string().default('localhost').description('Postgres host'), POSTGRES_PORT: joi_1.default.number().default(5432).description('Postgres host'), - POSTGRES_USERNAME: joi_1.default.string() - .default('postgres') - .description('Postgres username'), - POSTGRES_PASSWORD: joi_1.default.string() - .default('postgres') - .description('Postgres password'), + POSTGRES_USERNAME: joi_1.default.string().default('postgres').description('Postgres username'), + POSTGRES_PASSWORD: joi_1.default.string().default('postgres').description('Postgres password'), POSTGRES_Database: joi_1.default.string() .default('default_database') .description('Postgres database name'), @@ -46,27 +39,17 @@ const envVarsSchema = joi_1.default.object() .description('For loading all entities automatically'), POSTGRES_ENTITIES: joi_1.default.string().description('Postgres entities'), POSTGRES_MIGRATIONS: joi_1.default.string().description('Postgres migrations'), - POSTGRES_LOGGING: joi_1.default.boolean() - .default(false) - .description('Postgres logging'), + POSTGRES_LOGGING: joi_1.default.boolean().default(false).description('Postgres logging'), POSTGRES_MIGRATIONS_RUN: joi_1.default.boolean() .default(false) .description('Run migrations after running project'), - RABBITMQ_Host: joi_1.default.string() - .default('localhost') - .description('Rabbitmq host'), + RABBITMQ_Host: joi_1.default.string().default('localhost').description('Rabbitmq host'), RABBITMQ_PORT: joi_1.default.number().default(5672).description('Rabbitmq port'), - RABBITMQ_USERNAME: joi_1.default.string() - .default('guest') - .description('Rabbitmq username'), - RABBITMQ_PASSWORD: joi_1.default.string() - .default('guest') - .description('Rabbitmq password'), + RABBITMQ_USERNAME: joi_1.default.string().default('guest').description('Rabbitmq username'), + RABBITMQ_PASSWORD: joi_1.default.string().default('guest').description('Rabbitmq password'), RABBITMQ_EXCHANGE: joi_1.default.string().description('Rabbitmq exchange'), RETRY_COUNT: joi_1.default.number().default(3).description('Number of retries'), - RETRY_FACTOR: joi_1.default.number() - .default(2) - .description('Exponential backoff factor'), + RETRY_FACTOR: joi_1.default.number().default(2).description('Exponential backoff factor'), RETRY_MIN_TIMEOUT: joi_1.default.number() .default(1000) .description('Minimum time before retrying (1 second)'), @@ -78,7 +61,7 @@ const envVarsSchema = joi_1.default.object() .description('Jaeger Endpoint'), MONITORING_ZIPKIN_ENDPOINT: joi_1.default.string() .default('http://zipkin-server:9411/api/v2/spans') - .description('Zipkin Endpoint'), + .description('Zipkin Endpoint') }) .unknown(); const { value: envVars, error } = envVarsSchema @@ -96,7 +79,7 @@ exports.default = { port: envVars.RABBITMQ_PORT, username: envVars.RABBITMQ_USERNAME, password: envVars.RABBITMQ_PASSWORD, - exchange: envVars.RABBITMQ_EXCHANGE, + exchange: envVars.RABBITMQ_EXCHANGE }, postgres: { host: envVars.POSTGRES_HOST, @@ -114,17 +97,17 @@ exports.default = { jwt: { secret: envVars.JWT_SECRET, accessExpirationMinutes: envVars.JWT_ACCESS_EXPIRATION_MINUTES, - refreshExpirationDays: envVars.JWT_REFRESH_EXPIRATION_DAYS, + refreshExpirationDays: envVars.JWT_REFRESH_EXPIRATION_DAYS }, retry: { count: envVars.RETRY_COUNT, factor: envVars.RETRY_FACTOR, minTimeout: envVars.RETRY_MIN_TIMEOUT, - maxTimeout: envVars.RETRY_MAX_TIMEOUT, + maxTimeout: envVars.RETRY_MAX_TIMEOUT }, monitoring: { jaegerEndpoint: envVars.MONITORING_JAEGER_ENDPOINT, - zipkinEndpoint: envVars.MONITORING_ZIPKIN_ENDPOINT, - }, + zipkinEndpoint: envVars.MONITORING_ZIPKIN_ENDPOINT + } }; //# sourceMappingURL=configs.js.map \ No newline at end of file diff --git a/src/building-blocks/configs/configs.js.map b/src/building-blocks/configs/configs.js.map index 28f3482..5902a9d 100644 --- a/src/building-blocks/configs/configs.js.map +++ b/src/building-blocks/configs/configs.js.map @@ -1 +1 @@ -{"version":3,"file":"configs.js","sourceRoot":"","sources":["configs.ts"],"names":[],"mappings":";;;;;AAAA,oDAA4B;AAC5B,gDAAwB;AACxB,8CAAsB;AAGtB,MAAM,OAAO,GAAG,OAAO,CAAC,GAAG,CAAC,QAAQ,IAAI,aAAa,CAAC;AAGtD,gBAAM,CAAC,MAAM,CAAC,EAAE,IAAI,EAAE,cAAI,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,QAAQ,OAAO,EAAE,CAAC,EAAE,CAAC,CAAC;AACrE,gBAAM,CAAC,MAAM,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAA;AAEjC,MAAM,aAAa,GAAG,aAAG,CAAC,MAAM,EAAE;KAC7B,IAAI,CAAC;IACF,QAAQ,EAAE,aAAG,CAAC,MAAM,EAAE;SACjB,QAAQ,EAAE;IACf,YAAY,EAAE,aAAG,CAAC,MAAM,EAAE;IAC1B,IAAI,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC;IAChC,UAAU,EAAE,aAAG,CAAC,MAAM,EAAE;SACnB,OAAO,CAAC,2BAA2B,CAAC;SACpC,QAAQ,EAAE;SACV,WAAW,CAAC,g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OAAO,CAAC,WAAW;QAC1B,MAAM,EAAE,OAAO,CAAC,YAAY;QAC5B,UAAU,EAAE,OAAO,CAAC,iBAAiB;QACrC,UAAU,EAAE,OAAO,CAAC,iBAAiB;KACtC;IACD,UAAU,EAAE;QACV,cAAc,EAAE,OAAO,CAAC,0BAA0B;QAClD,cAAc,EAAE,OAAO,CAAC,0BAA0B;KACnD;CACF,CAAC"} \ No newline at end of file diff --git a/src/building-blocks/configs/configs.ts b/src/building-blocks/configs/configs.ts index 4d28974..b3d84f0 100644 --- a/src/building-blocks/configs/configs.ts +++ b/src/building-blocks/configs/configs.ts @@ -7,126 +7,109 @@ const nodeEnv = process.env.NODE_ENV || 'development'; // Load the appropriate .env file based on the environment dotenv.config({ path: path.join(process.cwd(), `.env.${nodeEnv}`) }); -dotenv.config({ override: true }) +dotenv.config({ override: true }); const envVarsSchema = Joi.object() - .keys({ - NODE_ENV: Joi.string() - .required(), - SERVICE_NAME: Joi.string(), - PORT: Joi.number().default(3000), - JWT_SECRET: Joi.string() - .default('thisisafakesecretchangeit') - .required() - .description('JWT secret key'), - JWT_ACCESS_EXPIRATION_MINUTES: Joi.number() - .default(30) - .description('minutes after which access tokens expire'), - JWT_REFRESH_EXPIRATION_DAYS: Joi.string() - .default('1 days') - .description('days after which refresh tokens expire'), - POSTGRES_HOST: Joi.string() - .default('localhost') - .description('Postgres host'), - POSTGRES_PORT: Joi.number().default(5432).description('Postgres host'), - POSTGRES_USERNAME: Joi.string() - .default('postgres') - .description('Postgres username'), - POSTGRES_PASSWORD: Joi.string() - .default('postgres') - .description('Postgres password'), - POSTGRES_Database: Joi.string() - .default('default_database') - .description('Postgres database name'), - POSTGRES_SYNCHRONIZE: Joi.boolean() - .default(false) - .description('Synchronize if true it dosent use migrations'), - POSTGRES_AUTO_LOAD_ENTITIES: Joi.boolean() - .default(true) - .description('For loading all entities automatically'), - POSTGRES_ENTITIES: Joi.string().description('Postgres entities'), - POSTGRES_MIGRATIONS: Joi.string().description('Postgres migrations'), - POSTGRES_LOGGING: Joi.boolean() - .default(false) - .description('Postgres logging'), - POSTGRES_MIGRATIONS_RUN: Joi.boolean() - .default(false) - .description('Run migrations after running project'), - RABBITMQ_Host: Joi.string() - .default('localhost') - .description('Rabbitmq host'), - RABBITMQ_PORT: Joi.number().default(5672).description('Rabbitmq port'), - RABBITMQ_USERNAME: Joi.string() - .default('guest') - .description('Rabbitmq username'), - RABBITMQ_PASSWORD: Joi.string() - .default('guest') - .description('Rabbitmq password'), - RABBITMQ_EXCHANGE: Joi.string().description('Rabbitmq exchange'), - RETRY_COUNT: Joi.number().default(3).description('Number of retries'), - RETRY_FACTOR: Joi.number() - .default(2) - .description('Exponential backoff factor'), - RETRY_MIN_TIMEOUT: Joi.number() - .default(1000) - .description('Minimum time before retrying (1 second)'), - RETRY_MAX_TIMEOUT: Joi.number() - .default(60000) - .description('Maximum time before retrying (60 seconds)'), - MONITORING_JAEGER_ENDPOINT: Joi.string() - .default('http://localhost:14268/api/traces') - .description('Jaeger Endpoint'), - MONITORING_ZIPKIN_ENDPOINT: Joi.string() - .default('http://zipkin-server:9411/api/v2/spans') - .description('Zipkin Endpoint'), - }) - .unknown(); + .keys({ + NODE_ENV: Joi.string().required(), + SERVICE_NAME: Joi.string(), + PORT: Joi.number().default(3000), + JWT_SECRET: Joi.string() + .default('thisisafakesecretchangeit') + .required() + .description('JWT secret key'), + JWT_ACCESS_EXPIRATION_MINUTES: Joi.number() + .default(30) + .description('minutes after which access tokens expire'), + JWT_REFRESH_EXPIRATION_DAYS: Joi.string() + .default('1 days') + .description('days after which refresh tokens expire'), + POSTGRES_HOST: Joi.string().default('localhost').description('Postgres host'), + POSTGRES_PORT: Joi.number().default(5432).description('Postgres host'), + POSTGRES_USERNAME: Joi.string().default('postgres').description('Postgres username'), + POSTGRES_PASSWORD: Joi.string().default('postgres').description('Postgres password'), + POSTGRES_Database: Joi.string() + .default('default_database') + .description('Postgres database name'), + POSTGRES_SYNCHRONIZE: Joi.boolean() + .default(false) + .description('Synchronize if true it dosent use migrations'), + POSTGRES_AUTO_LOAD_ENTITIES: Joi.boolean() + .default(true) + .description('For loading all entities automatically'), + POSTGRES_ENTITIES: Joi.string().description('Postgres entities'), + POSTGRES_MIGRATIONS: Joi.string().description('Postgres migrations'), + POSTGRES_LOGGING: Joi.boolean().default(false).description('Postgres logging'), + POSTGRES_MIGRATIONS_RUN: Joi.boolean() + .default(false) + .description('Run migrations after running project'), + RABBITMQ_Host: Joi.string().default('localhost').description('Rabbitmq host'), + RABBITMQ_PORT: Joi.number().default(5672).description('Rabbitmq port'), + RABBITMQ_USERNAME: Joi.string().default('guest').description('Rabbitmq username'), + RABBITMQ_PASSWORD: Joi.string().default('guest').description('Rabbitmq password'), + RABBITMQ_EXCHANGE: Joi.string().description('Rabbitmq exchange'), + RETRY_COUNT: Joi.number().default(3).description('Number of retries'), + RETRY_FACTOR: Joi.number().default(2).description('Exponential backoff factor'), + RETRY_MIN_TIMEOUT: Joi.number() + .default(1000) + .description('Minimum time before retrying (1 second)'), + RETRY_MAX_TIMEOUT: Joi.number() + .default(60000) + .description('Maximum time before retrying (60 seconds)'), + MONITORING_JAEGER_ENDPOINT: Joi.string() + .default('http://localhost:14268/api/traces') + .description('Jaeger Endpoint'), + MONITORING_ZIPKIN_ENDPOINT: Joi.string() + .default('http://zipkin-server:9411/api/v2/spans') + .description('Zipkin Endpoint') + }) + .unknown(); const { value: envVars, error } = envVarsSchema - .prefs({ errors: { label: 'key' } }) - .validate(process.env); + .prefs({ errors: { label: 'key' } }) + .validate(process.env); if (error) { - throw new Error(`Config validation error: ${error.message}`); + throw new Error(`Config validation error: ${error.message}`); } export default { - env: envVars.NODE_ENV, - serviceName: envVars.SERVICE_NAME, - port: envVars.PORT, - rabbitmq: { - host: envVars.RABBITMQ_Host, - port: envVars.RABBITMQ_PORT, - username: envVars.RABBITMQ_USERNAME, - password: envVars.RABBITMQ_PASSWORD, - exchange: envVars.RABBITMQ_EXCHANGE, - }, - postgres: { - host: envVars.POSTGRES_HOST, - port: envVars.POSTGRES_PORT, - username: envVars.POSTGRES_USERNAME, - password: envVars.POSTGRES_PASSWORD, - database: envVars.POSTGRES_Database, - synchronize: envVars.POSTGRES_SYNCHRONIZE, - autoLoadEntities: envVars.POSTGRES_AUTO_LOAD_ENTITIES, - entities: envVars.POSTGRES_ENTITIES, - migrations: envVars.POSTGRES_MIGRATIONS, - logging: envVars.POSTGRES_LOGGING, - migrationsRun: envVars.POSTGRES_MIGRATIONS_RUN - }, - jwt: { - secret: envVars.JWT_SECRET, - accessExpirationMinutes: envVars.JWT_ACCESS_EXPIRATION_MINUTES, - refreshExpirationDays: envVars.JWT_REFRESH_EXPIRATION_DAYS, - }, - retry: { - count: envVars.RETRY_COUNT, - factor: envVars.RETRY_FACTOR, - minTimeout: envVars.RETRY_MIN_TIMEOUT, - maxTimeout: envVars.RETRY_MAX_TIMEOUT, - }, - monitoring: { - jaegerEndpoint: envVars.MONITORING_JAEGER_ENDPOINT, - zipkinEndpoint: envVars.MONITORING_ZIPKIN_ENDPOINT, - }, + env: envVars.NODE_ENV, + serviceName: envVars.SERVICE_NAME, + port: envVars.PORT, + rabbitmq: { + host: envVars.RABBITMQ_Host, + port: envVars.RABBITMQ_PORT, + username: envVars.RABBITMQ_USERNAME, + password: envVars.RABBITMQ_PASSWORD, + exchange: envVars.RABBITMQ_EXCHANGE + }, + postgres: { + host: envVars.POSTGRES_HOST, + port: envVars.POSTGRES_PORT, + username: envVars.POSTGRES_USERNAME, + password: envVars.POSTGRES_PASSWORD, + database: envVars.POSTGRES_Database, + synchronize: envVars.POSTGRES_SYNCHRONIZE, + autoLoadEntities: envVars.POSTGRES_AUTO_LOAD_ENTITIES, + entities: envVars.POSTGRES_ENTITIES, + migrations: envVars.POSTGRES_MIGRATIONS, + logging: envVars.POSTGRES_LOGGING, + migrationsRun: envVars.POSTGRES_MIGRATIONS_RUN + }, + jwt: { + secret: envVars.JWT_SECRET, + accessExpirationMinutes: envVars.JWT_ACCESS_EXPIRATION_MINUTES, + refreshExpirationDays: envVars.JWT_REFRESH_EXPIRATION_DAYS + }, + retry: { + count: envVars.RETRY_COUNT, + factor: envVars.RETRY_FACTOR, + minTimeout: envVars.RETRY_MIN_TIMEOUT, + maxTimeout: envVars.RETRY_MAX_TIMEOUT + }, + monitoring: { + jaegerEndpoint: envVars.MONITORING_JAEGER_ENDPOINT, + zipkinEndpoint: envVars.MONITORING_ZIPKIN_ENDPOINT + } }; diff --git a/src/building-blocks/context/context.d.ts b/src/building-blocks/context/context.d.ts index 11e6998..d5c8391 100644 --- a/src/building-blocks/context/context.d.ts +++ b/src/building-blocks/context/context.d.ts @@ -1,7 +1,6 @@ -/// import { NestMiddleware } from '@nestjs/common'; import { Request, Response, NextFunction } from 'express'; -import { IncomingHttpHeaders } from "http"; +import { IncomingHttpHeaders } from 'http'; export declare class HttpContext { static request: Request; static response: Response; diff --git a/src/building-blocks/context/context.js.map b/src/building-blocks/context/context.js.map index a0dbf20..62223e0 100644 --- a/src/building-blocks/context/context.js.map +++ b/src/building-blocks/context/context.js.map @@ -1 +1 @@ -{"version":3,"file":"context.js","sourceRoot":"","sources":["context.ts"],"names":[],"mappings":";;;AAIA,MAAa,WAAW;CAIvB;AAJD,kCAIC;AAGD,MAAa,qBAAqB;IAChC,GAAG,CAAC,GAAY,EAAE,GAAa,EAAE,IAAkB;QAE/C,WAAW,CAAC,OAAO,GAAG,GAAG,CAAC;QAE1B,WAAW,CAAC,QAAQ,GAAG,GAAG,CAAC;QAE3B,WAAW,CAAC,OAAO,GAAG,GAAG,CAAC,OAAO,CAAC;QAElC,IAAI,EAAE,CAAC;IACX,CAAC;CACF;AAXD,sDAWC"} \ No newline at end of file +{"version":3,"file":"context.js","sourceRoot":"","sources":["context.ts"],"names":[],"mappings":";;;AAIA,MAAa,WAAW;CAIvB;AAJD,kCAIC;AAED,MAAa,qBAAqB;IAChC,GAAG,CAAC,GAAY,EAAE,GAAa,EAAE,IAAkB;QACjD,WAAW,CAAC,OAAO,GAAG,GAAG,CAAC;QAE1B,WAAW,CAAC,QAAQ,GAAG,GAAG,CAAC;QAE3B,WAAW,CAAC,OAAO,GAAG,GAAG,CAAC,OAAO,CAAC;QAElC,IAAI,EAAE,CAAC;IACT,CAAC;CACF;AAVD,sDAUC"} \ No newline at end of file diff --git a/src/building-blocks/context/context.ts b/src/building-blocks/context/context.ts index 75888d2..495c34d 100644 --- a/src/building-blocks/context/context.ts +++ b/src/building-blocks/context/context.ts @@ -1,6 +1,6 @@ import { NestMiddleware } from '@nestjs/common'; import { Request, Response, NextFunction } from 'express'; -import {IncomingHttpHeaders} from "http"; +import { IncomingHttpHeaders } from 'http'; export class HttpContext { static request: Request; @@ -8,16 +8,14 @@ export class HttpContext { static headers: IncomingHttpHeaders; } - export class HttpContextMiddleware implements NestMiddleware { use(req: Request, res: Response, next: NextFunction) { + HttpContext.request = req; - HttpContext.request = req; - - HttpContext.response = res; + HttpContext.response = res; - HttpContext.headers = req.headers; + HttpContext.headers = req.headers; - next(); + next(); } } diff --git a/src/building-blocks/contracts/booking.contract.d.ts b/src/building-blocks/contracts/booking.contract.d.ts index 4b3a4ac..8977cac 100644 --- a/src/building-blocks/contracts/booking.contract.d.ts +++ b/src/building-blocks/contracts/booking.contract.d.ts @@ -1,4 +1,4 @@ -import { IEvent } from "@nestjs/cqrs"; +import { IEvent } from '@nestjs/cqrs'; export declare class BookingCreated implements IEvent { id: number; flightNumber: string; diff --git a/src/building-blocks/contracts/booking.contract.ts b/src/building-blocks/contracts/booking.contract.ts index ad4fd8c..6bbf47d 100644 --- a/src/building-blocks/contracts/booking.contract.ts +++ b/src/building-blocks/contracts/booking.contract.ts @@ -1,4 +1,4 @@ -import { IEvent } from "@nestjs/cqrs"; +import { IEvent } from '@nestjs/cqrs'; export class BookingCreated implements IEvent { id: number; diff --git a/src/building-blocks/contracts/flight.contract.d.ts b/src/building-blocks/contracts/flight.contract.d.ts index 92ce14e..01b0c15 100644 --- a/src/building-blocks/contracts/flight.contract.d.ts +++ b/src/building-blocks/contracts/flight.contract.d.ts @@ -1,4 +1,4 @@ -import { IEvent } from "@nestjs/cqrs"; +import { IEvent } from '@nestjs/cqrs'; export declare class FlightCreated implements IEvent { id: number; flightNumber: string; diff --git a/src/building-blocks/contracts/flight.contract.ts b/src/building-blocks/contracts/flight.contract.ts index 1f52da6..dc56587 100644 --- a/src/building-blocks/contracts/flight.contract.ts +++ b/src/building-blocks/contracts/flight.contract.ts @@ -1,4 +1,4 @@ -import { IEvent } from "@nestjs/cqrs"; +import { IEvent } from '@nestjs/cqrs'; export class FlightCreated implements IEvent { id: number; diff --git a/src/building-blocks/contracts/identity.contract.d.ts b/src/building-blocks/contracts/identity.contract.d.ts index 0402b5a..1017881 100644 --- a/src/building-blocks/contracts/identity.contract.d.ts +++ b/src/building-blocks/contracts/identity.contract.d.ts @@ -1,4 +1,4 @@ -import { IEvent } from "@nestjs/cqrs"; +import { IEvent } from '@nestjs/cqrs'; export declare class UserCreated implements IEvent { id: number; email: string; diff --git a/src/building-blocks/contracts/identity.contract.ts b/src/building-blocks/contracts/identity.contract.ts index dc75f1f..7240636 100644 --- a/src/building-blocks/contracts/identity.contract.ts +++ b/src/building-blocks/contracts/identity.contract.ts @@ -1,4 +1,4 @@ -import { IEvent } from "@nestjs/cqrs"; +import { IEvent } from '@nestjs/cqrs'; export class UserCreated implements IEvent { id: number; diff --git a/src/building-blocks/eslint.config.js b/src/building-blocks/eslint.config.js new file mode 100644 index 0000000..53c4d9d --- /dev/null +++ b/src/building-blocks/eslint.config.js @@ -0,0 +1,12 @@ +// https://denar90.github.io/eslint.github.io/docs/rules/ +export default [ + { + rules: { + semi: 'error', + 'prefer-const': 'warn', + 'no-unused-vars': 'warn', + 'no-debugger': 'warn', + 'no-console': 'warn' + } + } +]; diff --git a/src/building-blocks/monitoring/prometheus.metrics.js b/src/building-blocks/monitoring/prometheus.metrics.js index be0b9af..71ba1b9 100644 --- a/src/building-blocks/monitoring/prometheus.metrics.js +++ b/src/building-blocks/monitoring/prometheus.metrics.js @@ -21,13 +21,23 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key, else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; return c > 3 && r && Object.defineProperty(target, key, r), r; }; -var __importStar = (this && this.__importStar) || function (mod) { - if (mod && mod.__esModule) return mod; - var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); - __setModuleDefault(result, mod); - return result; -}; +var __importStar = (this && this.__importStar) || (function () { + var ownKeys = function(o) { + ownKeys = Object.getOwnPropertyNames || function (o) { + var ar = []; + for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k; + return ar; + }; + return ownKeys(o); + }; + return function (mod) { + if (mod && mod.__esModule) return mod; + var result = {}; + if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]); + __setModuleDefault(result, mod); + return result; + }; +})(); Object.defineProperty(exports, "__esModule", { value: true }); exports.PrometheusMetrics = void 0; const common_1 = require("@nestjs/common"); diff --git a/src/building-blocks/monitoring/prometheus.metrics.js.map b/src/building-blocks/monitoring/prometheus.metrics.js.map index be2e029..9aa3fb2 100644 --- a/src/building-blocks/monitoring/prometheus.metrics.js.map +++ b/src/building-blocks/monitoring/prometheus.metrics.js.map @@ -1 +1 @@ -{"version":3,"file":"prometheus.metrics.js","sourceRoot":"","sources":["prometheus.metrics.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,2CAAoD;AAEpD,wDAA0C;AAC1C,6EAAwE;AACxE,+EAA0E;AAGnE,IAAM,iBAAiB,GAAvB,MAAM,iBAAiB;IAC5B,MAAM,CAAC,uBAAuB,CAAC,GAAQ;QACrC,GAAG,CAAC,GAAG,CAAC,UAAU,EAAE,KAAK,EAAE,GAAY,EAAE,GAA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AC,CAAC;YACnB,CAAC;YAAC,OAAO,KAAK,EAAE,CAAC;gBACf,eAAM,CAAC,KAAK,CAAC,2BAA2B,EAAE,KAAK,CAAC,CAAC;gBACjD,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE,CAAC;YACxB,CAAC;QACH,CAAC,CAAC,CAAC;QAGH,GAAG,CAAC,GAAG,CAAC,qDAAwB,CAAC,CAAC;QAClC,GAAG,CAAC,GAAG,CAAC,uDAAyB,CAAC,CAAC;IACrC,CAAC;CACF,CAAA;AAjBY,8CAAiB;4BAAjB,iBAAiB;IAD7B,IAAA,mBAAU,GAAE;GACA,iBAAiB,CAiB7B"} \ No newline at end of file diff --git a/src/building-blocks/monitoring/request-counter.middleware.js b/src/building-blocks/monitoring/request-counter.middleware.js index ecdf8f6..d4eae5c 100644 --- a/src/building-blocks/monitoring/request-counter.middleware.js +++ b/src/building-blocks/monitoring/request-counter.middleware.js @@ -15,25 +15,35 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( }) : function(o, v) { o["default"] = v; }); -var __importStar = (this && this.__importStar) || function (mod) { - if (mod && mod.__esModule) return mod; - var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); - __setModuleDefault(result, mod); - return result; -}; +var __importStar = (this && this.__importStar) || (function () { + var ownKeys = function(o) { + ownKeys = Object.getOwnPropertyNames || function (o) { + var ar = []; + for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k; + return ar; + }; + return ownKeys(o); + }; + return function (mod) { + if (mod && mod.__esModule) return mod; + var result = {}; + if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]); + __setModuleDefault(result, mod); + return result; + }; +})(); Object.defineProperty(exports, "__esModule", { value: true }); exports.requestCounterMiddleware = void 0; const Prometheus = __importStar(require("prom-client")); const requestCounter = new Prometheus.Counter({ name: 'http_requests_total', help: 'Total number of HTTP requests', - labelNames: ['method', 'path', 'status'], + labelNames: ['method', 'path', 'status'] }); const errorCounter = new Prometheus.Counter({ name: 'http_errors_total', help: 'Total number of HTTP errors', - labelNames: ['method', 'path', 'status'], + labelNames: ['method', 'path', 'status'] }); const requestCounterMiddleware = (err, req, res, next) => { const labels = { method: req.method, path: req.path }; diff --git a/src/building-blocks/monitoring/request-counter.middleware.js.map b/src/building-blocks/monitoring/request-counter.middleware.js.map index 7646e4b..2763a01 100644 --- a/src/building-blocks/monitoring/request-counter.middleware.js.map +++ b/src/building-blocks/monitoring/request-counter.middleware.js.map @@ -1 +1 @@ -{"version":3,"file":"request-counter.middleware.js","sourceRoot":"","sources":["request-counter.middleware.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wDAA0C;AAE1C,MAAM,cAAc,GAAG,IAAI,UAAU,CAAC,OAAO,CAAC;IAC1C,IAAI,EAAE,qBAAqB;IAC3B,IAAI,EAAE,+BAA+B;IACrC,UAAU,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,CAAC;CAC3C,CAAC,CAAC;AAEH,MAAM,YAAY,GAAG,IAAI,UAAU,CAAC,OAAO,CAAC;IACxC,IAAI,EAAE,mBAAmB;IACzB,IAAI,EAAE,6BAA6B;IACnC,UAAU,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,CAAC;CAC3C,CAAC,CAAC;AAEI,MAAM,wBAAwB,GAAG,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,IAAI,EAAE,EAAE;IAC5D,MAAM,MAAM,GAAG,EAAE,MAAM,EAAE,GAAG,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,CAAC,IAAI,EAAE,CAAC;IAEtD,cAAc,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IAE3B,GAAG,CAAC,EAAE,CAAC,QAAQ,EAAE,GAAG,EAAE;QAClB,MAAM,MAAM,GAAG,GAAG,CAAC,UAAU,CAAC,QAAQ,EAAE,CAAC;QAEzC,cAAc,CAAC,GAAG,iCACX,MAAM,KACT,MAAM,IACR,CAAC;QAGH,IAAI,MAAM,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,MAAM,CAAC,UAAU,CAAC,GAAG,CAAC,EAAE,CAAC;YACnD,YAAY,CAAC,GAAG,iCACT,MAAM,KACT,MAAM,IACR,CAAC;QACP,CAAC;IACL,CAAC,CAAC,CAAC;IAEH,IAAI,EAAE,CAAC;AACX,CAAC,CAAC;AAvBW,QAAA,wBAAwB,4BAuBnC"} \ No newline at end of file +{"version":3,"file":"request-counter.middleware.js","sourceRoot":"","sources":["request-counter.middleware.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wDAA0C;AAE1C,MAAM,cAAc,GAAG,IAAI,UAAU,CAAC,OAAO,CAAC;IAC5C,IAAI,EAAE,qBAAqB;IAC3B,IAAI,EAAE,+BAA+B;IACrC,UAAU,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,CAAC;CACzC,CAAC,CAAC;AAEH,MAAM,YAAY,GAAG,IAAI,UAAU,CAAC,OAAO,CAAC;IAC1C,IAAI,EAAE,mBAAmB;IACzB,IAAI,EAAE,6BAA6B;IACnC,UAAU,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,CAAC;CACzC,CAAC,CAAC;AAEI,MAAM,wBAAwB,GAAG,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,IAAI,EAAE,EAAE;IAC9D,MAAM,MAAM,GAAG,EAAE,MAAM,EAAE,GAAG,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,CAAC,IAAI,EAAE,CAAC;IAEtD,cAAc,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IAE3B,GAAG,CAAC,EAAE,CAAC,QAAQ,EAAE,GAAG,EAAE;QACpB,MAAM,MAAM,GAAG,GAAG,CAAC,UAAU,CAAC,QAAQ,EAAE,CAAC;QAEzC,cAAc,CAAC,GAAG,iCACb,MAAM,KACT,MAAM,IACN,CAAC;QAGH,IAAI,MAAM,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,MAAM,CAAC,UAAU,CAAC,GAAG,CAAC,EAAE,CAAC;YACrD,YAAY,CAAC,GAAG,iCACX,MAAM,KACT,MAAM,IACN,CAAC;QACL,CAAC;IACH,CAAC,CAAC,CAAC;IAEH,IAAI,EAAE,CAAC;AACT,CAAC,CAAC;AAvBW,QAAA,wBAAwB,4BAuBnC"} \ No newline at end of file diff --git a/src/building-blocks/monitoring/request-counter.middleware.ts b/src/building-blocks/monitoring/request-counter.middleware.ts index ecfdda2..d24bb9f 100644 --- a/src/building-blocks/monitoring/request-counter.middleware.ts +++ b/src/building-blocks/monitoring/request-counter.middleware.ts @@ -1,38 +1,38 @@ import * as Prometheus from 'prom-client'; const requestCounter = new Prometheus.Counter({ - name: 'http_requests_total', - help: 'Total number of HTTP requests', - labelNames: ['method', 'path', 'status'], + name: 'http_requests_total', + help: 'Total number of HTTP requests', + labelNames: ['method', 'path', 'status'] }); const errorCounter = new Prometheus.Counter({ - name: 'http_errors_total', - help: 'Total number of HTTP errors', - labelNames: ['method', 'path', 'status'], + name: 'http_errors_total', + help: 'Total number of HTTP errors', + labelNames: ['method', 'path', 'status'] }); -export const requestCounterMiddleware = (err, req, res, next) => { - const labels = { method: req.method, path: req.path }; +export const requestCounterMiddleware = (err: any, req: any, res: any, next: any) => { + const labels = { method: req.method, path: req.path }; - requestCounter.inc(labels); + requestCounter.inc(labels); - res.on('finish', () => { - const status = res.statusCode.toString(); + res.on('finish', () => { + const status = res.statusCode.toString(); - requestCounter.inc({ - ...labels, - status, - }); - - // Check if the status code represents an error (4xx or 5xx) - if (status.startsWith('4') || status.startsWith('5')) { - errorCounter.inc({ - ...labels, - status, - }); - } + requestCounter.inc({ + ...labels, + status }); - next(); + // Check if the status code represents an error (4xx or 5xx) + if (status.startsWith('4') || status.startsWith('5')) { + errorCounter.inc({ + ...labels, + status + }); + } + }); + + next(); }; diff --git a/src/building-blocks/monitoring/request-duration.middleware.js b/src/building-blocks/monitoring/request-duration.middleware.js index 8d3e446..2597d4a 100644 --- a/src/building-blocks/monitoring/request-duration.middleware.js +++ b/src/building-blocks/monitoring/request-duration.middleware.js @@ -15,13 +15,23 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( }) : function(o, v) { o["default"] = v; }); -var __importStar = (this && this.__importStar) || function (mod) { - if (mod && mod.__esModule) return mod; - var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); - __setModuleDefault(result, mod); - return result; -}; +var __importStar = (this && this.__importStar) || (function () { + var ownKeys = function(o) { + ownKeys = Object.getOwnPropertyNames || function (o) { + var ar = []; + for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k; + return ar; + }; + return ownKeys(o); + }; + return function (mod) { + if (mod && mod.__esModule) return mod; + var result = {}; + if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]); + __setModuleDefault(result, mod); + return result; + }; +})(); Object.defineProperty(exports, "__esModule", { value: true }); exports.requestDurationMiddleware = void 0; const Prometheus = __importStar(require("prom-client")); @@ -29,7 +39,7 @@ const requestDurationHistogram = new Prometheus.Histogram({ name: 'http_request_duration_seconds', help: 'Duration of HTTP requests in seconds', labelNames: ['method', 'path'], - buckets: [0.1, 0.5, 1, 2, 5], + buckets: [0.1, 0.5, 1, 2, 5] }); const requestDurationMiddleware = (err, req, res, next) => { const start = process.hrtime(); diff --git a/src/building-blocks/monitoring/request-duration.middleware.js.map b/src/building-blocks/monitoring/request-duration.middleware.js.map index 6096974..e2c4d8a 100644 --- a/src/building-blocks/monitoring/request-duration.middleware.js.map +++ b/src/building-blocks/monitoring/request-duration.middleware.js.map @@ -1 +1 @@ -{"version":3,"file":"request-duration.middleware.js","sourceRoot":"","sources":["request-duration.middleware.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wDAA0C;AAE1C,MAAM,wBAAwB,GAAG,IAAI,UAAU,CAAC,SAAS,CAAC;IACtD,IAAI,EAAE,+BAA+B;IACrC,IAAI,EAAE,sCAAsC;IAC5C,UAAU,EAAE,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC9B,OAAO,EAAE,CAAC,GAAG,EAAE,GAAG,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC;CAC/B,CAAC,CAAC;AAEI,MAAM,yBAAyB,GAAG,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,IAAI,EAAE,EAAE;IAC7D,MAAM,KAAK,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC;IAE/B,GAAG,CAAC,EAAE,CAAC,QAAQ,EAAE,GAAG,EAAE;QAClB,MAAM,QAAQ,GAAG,yBAAyB,CAAC,KAAK,CAAC,CAAC;QAClD,MAAM,MAAM,GAAG,EAAE,MAAM,EAAE,GAAG,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,CAAC,IAAI,EAAE,CAAC;QACtD,wBAAwB,CAAC,OAAO,CAAC,MAAM,EAAE,QAAQ,GAAG,IAAI,CAAC,CAAC;IAC9D,CAAC,CAAC,CAAC;IAEH,IAAI,EAAE,CAAC;AACX,CAAC,CAAC;AAVW,QAAA,yBAAyB,6BAUpC;AAEF,SAAS,yBAAyB,CAAC,KAAuB;IACtD,MAAM,UAAU,GAAG,GAAG,CAAC;IACvB,MAAM,QAAQ,GAAG,GAAG,CAAC;IAErB,MAAM,IAAI,GAAG,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;IACnC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,GAAG,UAAU,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,GAAG,QAAQ,CAAC;AACvD,CAAC"} \ No newline at end of file +{"version":3,"file":"request-duration.middleware.js","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request-duration.middleware.ts b/src/building-blocks/monitoring/request-duration.middleware.ts index e6613a5..1da2243 100644 --- a/src/building-blocks/monitoring/request-duration.middleware.ts +++ b/src/building-blocks/monitoring/request-duration.middleware.ts @@ -1,28 +1,28 @@ import * as Prometheus from 'prom-client'; const requestDurationHistogram = new Prometheus.Histogram({ - name: 'http_request_duration_seconds', - help: 'Duration of HTTP requests in seconds', - labelNames: ['method', 'path'], - buckets: [0.1, 0.5, 1, 2, 5], // Adjust buckets based on your requirements + name: 'http_request_duration_seconds', + help: 'Duration of HTTP requests in seconds', + labelNames: ['method', 'path'], + buckets: [0.1, 0.5, 1, 2, 5] // Adjust buckets based on your requirements }); export const requestDurationMiddleware = (err, req, res, next) => { - const start = process.hrtime(); + const start = process.hrtime(); - res.on('finish', () => { - const duration = getDurationInMilliseconds(start); - const labels = { method: req.method, path: req.path }; - requestDurationHistogram.observe(labels, duration / 1000); // Convert to seconds - }); + res.on('finish', () => { + const duration = getDurationInMilliseconds(start); + const labels = { method: req.method, path: req.path }; + requestDurationHistogram.observe(labels, duration / 1000); // Convert to seconds + }); - next(); + next(); }; function getDurationInMilliseconds(start: [number, number]): number { - const NS_PER_SEC = 1e9; - const NS_TO_MS = 1e6; + const NS_PER_SEC = 1e9; + const NS_TO_MS = 1e6; - const diff = process.hrtime(start); - return (diff[0] * NS_PER_SEC + diff[1]) / NS_TO_MS; + const diff = process.hrtime(start); + return (diff[0] * NS_PER_SEC + diff[1]) / NS_TO_MS; } diff --git a/src/building-blocks/openTelemetry/open-telemetry-tracer.js.map b/src/building-blocks/openTelemetry/open-telemetry-tracer.js.map index aebe83a..31457be 100644 --- a/src/building-blocks/openTelemetry/open-telemetry-tracer.js.map +++ b/src/building-blocks/openTelemetry/open-telemetry-tracer.js.map @@ -1 +1 @@ -{"version":3,"file":"open-telemetry-tracer.js","sourceRoot":"","sources":["open-telemetry-tracer.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAAA,2CAAgE;AAChE,kEAAqF;A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AO,CAAC;QACjB,QAAQ,EAAE,QAAQ,CAAC,QAAQ;QAC3B,aAAa,EAAE,QAAQ,CAAC,mBAAmB;QAC3C,gBAAgB,EAAE;YAChB,IAAI,0CAAmB,EAAE;YACzB,IAAI,gDAAsB,EAAE;YAC5B,IAAI,iDAAmB,EAAE;YACzB,IAAI,gDAAsB,EAAE;SAC7B;KACF,CAAC,CAAC;AACL,CAAC;AAOM,IAAM,mBAAmB,GAAzB,MAAM,mBAAmB;IAC9B,YAA2D,OAA6B;QAA7B,YAAO,GAAP,OAAO,CAAsB;QACtF,oBAAoB,GAAG,IAAI,CAAC,OAAO,CAAC;IACtC,CAAC;IACD,KAAK,CAAC,YAAY;QAChB,CAAC,MAAM,OAAO,CAAC,CAAC,KAAK,EAAE,CAAC;IAC1B,CAAC;IAED,KAAK,CAAC,YAAY,CAAC,OAA6B;;QAC9C,MAAM,MAAM,GAAG,WAAK,CAAC,SAAS,CAAC,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,WAAW,mCAAI,iBAAO,CAAC,WAAW,CAAC,CAAC;QAC5E,OAAO,MAAM,CAAC;IAChB,CAAC;CACF,CAAA;AAZY,kDAAmB;8BAAnB,mBAAmB;IAD/B,IAAA,mBAAU,GAAE;IAEE,WAAA,IAAA,eAAM,EAAC,oBAAoB,CAAC,CAAA;qCAA2B,oBAAoB;GAD7E,mBAAmB,CAY/B"} \ No newline at end of file diff --git a/src/building-blocks/openTelemetry/open-telemetry-tracer.ts b/src/building-blocks/openTelemetry/open-telemetry-tracer.ts index f5fd3d6..e12a259 100644 --- a/src/building-blocks/openTelemetry/open-telemetry-tracer.ts +++ b/src/building-blocks/openTelemetry/open-telemetry-tracer.ts @@ -1,17 +1,17 @@ -import {Inject, Injectable, OnModuleInit} from '@nestjs/common'; -import {BatchSpanProcessor, NodeTracerProvider} from '@opentelemetry/sdk-trace-node'; -import {ZipkinExporter} from '@opentelemetry/exporter-zipkin'; -import {AmqplibInstrumentation} from '@opentelemetry/instrumentation-amqplib'; -import {SimpleSpanProcessor} from '@opentelemetry/sdk-trace-base'; -import {HttpInstrumentation} from '@opentelemetry/instrumentation-http'; -import {ExpressInstrumentation} from '@opentelemetry/instrumentation-express'; -import {NestInstrumentation} from '@opentelemetry/instrumentation-nestjs-core'; -import {Resource} from '@opentelemetry/resources'; -import {SemanticResourceAttributes} from '@opentelemetry/semantic-conventions'; -import {JaegerExporter} from '@opentelemetry/exporter-jaeger'; -import {trace, Tracer} from '@opentelemetry/api'; +import { Inject, Injectable, OnModuleInit } from '@nestjs/common'; +import { BatchSpanProcessor, NodeTracerProvider } from '@opentelemetry/sdk-trace-node'; +import { ZipkinExporter } from '@opentelemetry/exporter-zipkin'; +import { AmqplibInstrumentation } from '@opentelemetry/instrumentation-amqplib'; +import { SimpleSpanProcessor } from '@opentelemetry/sdk-trace-base'; +import { HttpInstrumentation } from '@opentelemetry/instrumentation-http'; +import { ExpressInstrumentation } from '@opentelemetry/instrumentation-express'; +import { NestInstrumentation } from '@opentelemetry/instrumentation-nestjs-core'; +import { Resource } from '@opentelemetry/resources'; +import { SemanticResourceAttributes } from '@opentelemetry/semantic-conventions'; +import { JaegerExporter } from '@opentelemetry/exporter-jaeger'; +import { trace, Tracer } from '@opentelemetry/api'; import configs from '../configs/configs'; -import {NodeSDK} from "@opentelemetry/sdk-node"; +import { NodeSDK } from '@opentelemetry/sdk-node'; export class OpenTelemetryOptions { jaegerEndpoint?: string; @@ -28,10 +28,10 @@ let openTelemetryOptions: OpenTelemetryOptions = new OpenTelemetryOptions(); const otelSDK = initSdk(); async function initSdk() { - const provider = new NodeTracerProvider({ resource: new Resource({ - [SemanticResourceAttributes.SERVICE_NAME]: openTelemetryOptions?.serviceName ?? configs.serviceName + [SemanticResourceAttributes.SERVICE_NAME]: + openTelemetryOptions?.serviceName ?? configs.serviceName }) }); @@ -76,9 +76,7 @@ export class OpenTelemetryTracer implements IOpenTelemetryTracer, OnModuleInit { } async createTracer(options: OpenTelemetryOptions): Promise { - const tracer = trace.getTracer(options?.serviceName ?? configs.serviceName); return tracer; } } - diff --git a/src/building-blocks/openTelemetry/open-telemetry.module.js b/src/building-blocks/openTelemetry/open-telemetry.module.js index 3714f9e..844db6a 100644 --- a/src/building-blocks/openTelemetry/open-telemetry.module.js +++ b/src/building-blocks/openTelemetry/open-telemetry.module.js @@ -23,10 +23,12 @@ exports.OpenTelemetryModule = OpenTelemetryModule; exports.OpenTelemetryModule = OpenTelemetryModule = OpenTelemetryModule_1 = __decorate([ (0, common_1.Global)(), (0, common_1.Module)({ - providers: [{ + providers: [ + { provide: 'IOpenTelemetryTracer', useClass: open_telemetry_tracer_1.OpenTelemetryTracer - }], + } + ], exports: ['IOpenTelemetryTracer'] }) ], OpenTelemetryModule); diff --git a/src/building-blocks/openTelemetry/open-telemetry.module.js.map b/src/building-blocks/openTelemetry/open-telemetry.module.js.map index 9efec21..4b91e68 100644 --- a/src/building-blocks/openTelemetry/open-telemetry.module.js.map +++ b/src/building-blocks/openTelemetry/open-telemetry.module.js.map @@ -1 +1 @@ -{"version":3,"file":"open-telemetry.module.js","sourceRoot":"","sources":["open-telemetry.module.ts"],"names":[],"mappings":";;;;;;;;;;AAAA,2CAAoF;AACpF,mEAAmF;AAS5E,IAAM,mBAAmB,2BAAzB,MAAM,mBAAmB;IAE9B,KAAK,CAAC,qBAAqB,CAAC,MAAe,IAAG,CAAC;IAE/C,MAAM,CAAC,OAAO,CAAC,OAA8B;QAC3C,OAAO;YACL,MAAM,EAAE,qBAAmB;YAC3B,SAAS,EAAE,CAAC,2CAAmB,EAAE,EAAE,OAAO,EAAE,4CAAoB,EAAE,QAAQ,EAAE,OAAO,EAAE,CAAC;SACvF,CAAC;IACJ,CAAC;CACF,CAAA;AAVY,kDAAmB;8BAAnB,mBAAmB;IAR/B,IAAA,eAAM,GAAE;IACR,IAAA,eAAM,EAAC;QACN,SAAS,EAAE,CAAM;gBACf,OAAO,EAAE,sBAAsB;gBAC/B,QAAQ,EAAE,2CAAmB;aAC9B,CAAC;QACF,OAAO,EAAE,CAAC,sBAAsB,CAAC;KAClC,CAAC;GACW,mBAAmB,CAU/B"} \ No newline at end of file +{"version":3,"file":"open-telemetry.module.js","sourceRoot":"","sources":["open-telemetry.module.ts"],"names":[],"mappings":";;;;;;;;;;AAAA,2CAAsF;AACtF,mEAAoF;AAW7E,IAAM,mBAAmB,2BAAzB,MAAM,mBAAmB;IAC9B,KAAK,CAAC,qBAAqB,CAAC,MAAe,IAAG,CAAC;IAE/C,MAAM,CAAC,OAAO,CAAC,OAA8B;QAC3C,OAAO;YACL,MAAM,EAAE,qBAAmB;YAC3B,SAAS,EAAE,CAAC,2CAAmB,EAAE,EAAE,OAAO,EAAE,4CAAoB,EAAE,QAAQ,EAAE,OAAO,EAAE,CAAC;SACvF,CAAC;IACJ,CAAC;CACF,CAAA;AATY,kDAAmB;8BAAnB,mBAAmB;IAV/B,IAAA,eAAM,GAAE;IACR,IAAA,eAAM,EAAC;QACN,SAAS,EAAE;YACT;gBACE,OAAO,EAAE,sBAAsB;gBAC/B,QAAQ,EAAE,2CAAmB;aAC9B;SACF;QACD,OAAO,EAAE,CAAC,sBAAsB,CAAC;KAClC,CAAC;GACW,mBAAmB,CAS/B"} \ No newline at end of file diff --git a/src/building-blocks/openTelemetry/open-telemetry.module.ts b/src/building-blocks/openTelemetry/open-telemetry.module.ts index b7d1bd2..3337a33 100644 --- a/src/building-blocks/openTelemetry/open-telemetry.module.ts +++ b/src/building-blocks/openTelemetry/open-telemetry.module.ts @@ -1,15 +1,16 @@ -import {DynamicModule, Global, Module, OnApplicationShutdown} from '@nestjs/common'; -import { OpenTelemetryOptions, OpenTelemetryTracer} from './open-telemetry-tracer'; +import { DynamicModule, Global, Module, OnApplicationShutdown } from '@nestjs/common'; +import { OpenTelemetryOptions, OpenTelemetryTracer } from './open-telemetry-tracer'; @Global() @Module({ - providers: [ { - provide: 'IOpenTelemetryTracer', - useClass: OpenTelemetryTracer - }], + providers: [ + { + provide: 'IOpenTelemetryTracer', + useClass: OpenTelemetryTracer + } + ], exports: ['IOpenTelemetryTracer'] }) export class OpenTelemetryModule implements OnApplicationShutdown { - async onApplicationShutdown(signal?: string) {} static forRoot(options?: OpenTelemetryOptions): DynamicModule { diff --git a/src/building-blocks/package.json b/src/building-blocks/package.json index f84c6e0..23f135b 100644 --- a/src/building-blocks/package.json +++ b/src/building-blocks/package.json @@ -5,62 +5,61 @@ "main": "index.js", "scripts": { "build": "tsc", - "format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"", - "lint": "eslint \"{src,apps,libs,test}/**/*.ts\" --fix" + "format": "prettier --write \"**/*.{ts,js}\"", + "lint": "eslint . --fix" }, - "author": "", + "author": "Meysam", "license": "ISC", "keywords": [], "dependencies": { - "@nestjs/cli": "10.2.1", - "@nestjs/cqrs": "^10.2.6", - "@nestjs/passport": "^10.0.2", - "@opentelemetry/api": "^1.7.0", - "@opentelemetry/auto-instrumentations-node": "^0.40.2", - "@opentelemetry/exporter-jaeger": "^1.19.0", - "@opentelemetry/exporter-prometheus": "^0.46.0", - "@opentelemetry/exporter-zipkin": "^1.19.0", - "@opentelemetry/instrumentation-amqplib": "^0.33.4", - "@opentelemetry/instrumentation-express": "^0.34.0", - "@opentelemetry/instrumentation-http": "^0.46.0", - "@opentelemetry/instrumentation-nestjs-core": "^0.33.3", + "@eslint/js": "^9.17.0", + "@nestjs/cli": "10.4.9", + "@nestjs/cqrs": "^10.2.8", + "@nestjs/passport": "^10.0.3", + "@opentelemetry/api": "^1.9.0", + "@opentelemetry/auto-instrumentations-node": "^0.55.0", + "@opentelemetry/exporter-jaeger": "^1.30.0", + "@opentelemetry/exporter-prometheus": "^0.57.0", + "@opentelemetry/exporter-zipkin": "^1.30.0", + "@opentelemetry/instrumentation-amqplib": "^0.46.0", + "@opentelemetry/instrumentation-express": "^0.47.0", + "@opentelemetry/instrumentation-http": "^0.57.0", + "@opentelemetry/instrumentation-nestjs-core": "^0.44.0", "@opentelemetry/metrics": "^0.24.0", "@opentelemetry/node": "^0.24.0", - "@opentelemetry/resources": "^1.19.0", - "@opentelemetry/sdk-node": "^0.46.0", - "@opentelemetry/sdk-trace-base": "^1.19.0", - "@opentelemetry/sdk-trace-node": "^1.19.0", - "@opentelemetry/semantic-conventions": "^1.19.0", - "@types/amqplib": "^0.10.4", - "@types/dotenv": "8.2.0", - "@types/express": "4.17.21", - "@types/node": "^20.10.0", - "@types/passport-jwt": "^3.0.13", + "@opentelemetry/resources": "^1.30.0", + "@opentelemetry/sdk-node": "^0.57.0", + "@opentelemetry/sdk-trace-base": "^1.30.0", + "@opentelemetry/sdk-trace-node": "^1.30.0", + "@opentelemetry/semantic-conventions": "^1.28.0", + "@types/amqplib": "^0.10.6", + "@types/dotenv": "8.2.3", + "@types/express": "5.0.0", + "@types/node": "^22.10.2", + "@types/passport-jwt": "^4.0.1", "@types/passport-local": "^1.0.38", - "@types/uuid": "^9.0.7", - "@typescript-eslint/eslint-plugin": "6.12.0", - "@typescript-eslint/parser": "6.12.0", - "@typescript-eslint/typescript-estree": "6.12.0", - "amqplib": "^0.10.3", + "@types/uuid": "^10.0.0", + "@typescript-eslint/eslint-plugin": "8.18.2", + "@typescript-eslint/parser": "8.18.2", + "@typescript-eslint/typescript-estree": "8.18.2", + "amqplib": "^0.10.5", "async-retry": "^1.3.3", "bcryptjs": "^2.4.3", - "date-fns": "^2.30.0", - "dotenv": "^16.3.1", - "eslint": "8.54.0", - "eslint-config-prettier": "9.0.0", - "eslint-plugin-import": "2.29.0", - "eslint-plugin-prettier": "5.0.1", - "express": "4.18.2", + "date-fns": "^4.1.0", + "dotenv": "^16.4.7", + "eslint": "9.17.0", + "express": "4.21.2", "http-problem-details": "^0.1.5", + "joi": "^17.13.3", "lodash": "^4.17.21", "passport-jwt": "^4.0.1", - "prettier": "3.1.0", - "prom-client": "^15.0.0", - "reflect-metadata": "^0.1.13", + "prettier": "3.4.2", + "prom-client": "^15.1.3", + "reflect-metadata": "^0.2.2", "rxjs": "^7.8.1", - "testcontainers": "^10.3.2", - "ts-node": "10.9.1", - "typeorm": "^0.3.17", - "typescript": "5.3.2" + "testcontainers": "^10.16.0", + "ts-node": "10.9.2", + "typeorm": "^0.3.20", + "typescript": "5.7.2" } } diff --git a/src/building-blocks/passport/jwt.guard.d.ts b/src/building-blocks/passport/jwt.guard.d.ts index 32494ff..c212a10 100644 --- a/src/building-blocks/passport/jwt.guard.d.ts +++ b/src/building-blocks/passport/jwt.guard.d.ts @@ -1,7 +1,7 @@ import { ExecutionContext } from '@nestjs/common'; declare const JwtGuard_base: import("@nestjs/passport").Type; export declare class JwtGuard extends JwtGuard_base { - canActivate(context: ExecutionContext): boolean | Promise | import("rxjs").Observable; + canActivate(context: ExecutionContext): boolean | Promise | import("node_modules/rxjs/dist/types").Observable; handleRequest(err: any, user: any, _info: any): any; } export {}; diff --git a/src/building-blocks/passport/jwt.guard.js b/src/building-blocks/passport/jwt.guard.js index 60b295b..09e4f9d 100644 --- a/src/building-blocks/passport/jwt.guard.js +++ b/src/building-blocks/passport/jwt.guard.js @@ -24,4 +24,3 @@ exports.JwtGuard = JwtGuard; exports.JwtGuard = JwtGuard = __decorate([ (0, common_1.Injectable)() ], JwtGuard); -//# sourceMappingURL=jwt.guard.js.map \ No newline at end of file diff --git a/src/building-blocks/rabbitmq/rabbitmq-connection.js b/src/building-blocks/rabbitmq/rabbitmq-connection.js index 59a1509..a9a1717 100644 --- a/src/building-blocks/rabbitmq/rabbitmq-connection.js +++ b/src/building-blocks/rabbitmq/rabbitmq-connection.js @@ -21,13 +21,23 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key, else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; return c > 3 && r && Object.defineProperty(target, key, r), r; }; -var __importStar = (this && this.__importStar) || function (mod) { - if (mod && mod.__esModule) return mod; - var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); - __setModuleDefault(result, mod); - return result; -}; +var __importStar = (this && this.__importStar) || (function () { + var ownKeys = function(o) { + ownKeys = Object.getOwnPropertyNames || function (o) { + var ar = []; + for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k; + return ar; + }; + return ownKeys(o); + }; + return function (mod) { + if (mod && mod.__esModule) return mod; + var result = {}; + if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]); + __setModuleDefault(result, mod); + return result; + }; +})(); var __metadata = (this && this.__metadata) || function (k, v) { if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v); }; diff --git a/src/building-blocks/rabbitmq/rabbitmq-connection.js.map b/src/building-blocks/rabbitmq/rabbitmq-connection.js.map index 51de692..70b38d9 100644 --- a/src/building-blocks/rabbitmq/rabbitmq-connection.js.map +++ b/src/building-blocks/rabbitmq/rabbitmq-connection.js.map @@ -1 +1 @@ -{"version":3,"file":"rabbitmq-connection.js","sourceRoot":"","sources":["rabbitmq-connection.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,2CAA0E;AAC1E,8CAAgC;AAChC,iEAAyC;AACzC,8DAAqC;AAErC,MAAa,eAAe;IAK1B,YAAY,OAAkC;QAC5C,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AARD,0CAQC;AAED,IAAI,UAAU,GAAoB,IAAI,CAAC;AACvC,IAAI,OAAO,GAAiB,IAAI,CAAC;AAa1B,IAAM,kBAAkB,GAAxB,MAAM,kBAAkB;IAE7B,YAAsD,OAAyB;QAAzB,YAAO,GAAP,OAAO,CAAkB;IAAG,CAAC;IAEnF,KAAK,CAAC,YAAY;QAChB,MAAM,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAC5C,CAAC;IAED,KAA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,MAAM,OAAO,CAAC,KAAK,EAAE,CAAC;gBACtB,eAAM,CAAC,GAAG,CAAC,6BAA6B,CAAC,CAAC;YAC5C,CAAC;QACH,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,eAAM,CAAC,KAAK,CAAC,uBAAuB,CAAC,CAAC;QACxC,CAAC;IACH,CAAC;IAED,KAAK,CAAC,eAAe;QACnB,IAAI,CAAC;YACH,IAAI,UAAU,EAAE,CAAC;gBACf,MAAM,UAAU,CAAC,KAAK,EAAE,CAAC;gBACzB,eAAM,CAAC,GAAG,CAAC,uCAAuC,CAAC,CAAC;YACtD,CAAC;QACH,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,eAAM,CAAC,KAAK,CAAC,mCAAmC,CAAC,CAAC;QACpD,CAAC;IACH,CAAC;CACF,CAAA;AA/FY,gDAAkB;6BAAlB,kBAAkB;IAD9B,IAAA,mBAAU,GAAE;IAGE,WAAA,IAAA,eAAM,EAAC,eAAe,CAAC,CAAA;qCAA4B,eAAe;GAFpE,kBAAkB,CA+F9B"} \ No newline at end of file +{"version":3,"file":"rabbitmq-connection.js","sourceRoot":"","sources":["rabbitmq-connection.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,2CAA0E;AAC1E,8CAAgC;AAChC,iEAAyC;AACzC,8DAAqC;AAErC,MAAa,eAAe;IAK1B,YAAY,OAAkC;QAC5C,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AARD,0CAQC;AAED,IAAI,UAAU,GAAoB,IAAI,CAAC;AACvC,IAAI,OAAO,GAAiB,IAAI,CAAC;AAa1B,IAAM,kBAAkB,GAAxB,MAAM,kBAAkB;IAC7B,YAAsD,OAAyB;QAAzB,YAAO,GAAP,OAAO,CAAkB;IAAG,CAAC;IAEnF,KAAK,CAAC,YAAY;QAChB,MAAM,IAAI,CAAC,gBAA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C,WAAW;QACf,IAAI,CAAC;YACH,IAAI,OAAO,EAAE,CAAC;gBACZ,MAAM,OAAO,CAAC,KAAK,EAAE,CAAC;gBACtB,eAAM,CAAC,GAAG,CAAC,6BAA6B,CAAC,CAAC;YAC5C,CAAC;QACH,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,eAAM,CAAC,KAAK,CAAC,uBAAuB,CAAC,CAAC;QACxC,CAAC;IACH,CAAC;IAED,KAAK,CAAC,eAAe;QACnB,IAAI,CAAC;YACH,IAAI,UAAU,EAAE,CAAC;gBACf,MAAM,UAAU,CAAC,KAAK,EAAE,CAAC;gBACzB,eAAM,CAAC,GAAG,CAAC,uCAAuC,CAAC,CAAC;YACtD,CAAC;QACH,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,eAAM,CAAC,KAAK,CAAC,mCAAmC,CAAC,CAAC;QACpD,CAAC;IACH,CAAC;CACF,CAAA;AA7FY,gDAAkB;6BAAlB,kBAAkB;IAD9B,IAAA,mBAAU,GAAE;IAEE,WAAA,IAAA,eAAM,EAAC,eAAe,CAAC,CAAA;qCAA4B,eAAe;GADpE,kBAAkB,CA6F9B"} \ No newline at end of file diff --git a/src/building-blocks/rabbitmq/rabbitmq-connection.ts b/src/building-blocks/rabbitmq/rabbitmq-connection.ts index 11331e3..74c5c92 100644 --- a/src/building-blocks/rabbitmq/rabbitmq-connection.ts +++ b/src/building-blocks/rabbitmq/rabbitmq-connection.ts @@ -28,7 +28,6 @@ export interface IRabbitmqConnection { @Injectable() export class RabbitmqConnection implements OnModuleInit, IRabbitmqConnection { - constructor(@Inject(RabbitmqOptions) private readonly options?: RabbitmqOptions) {} async onModuleInit(): Promise { @@ -38,7 +37,6 @@ export class RabbitmqConnection implements OnModuleInit, IRabbitmqConnection { async createConnection(options?: RabbitmqOptions): Promise { if (!connection || !connection == undefined) { try { - const host = options?.host ?? configs.rabbitmq.host; const port = options?.port ?? configs.rabbitmq.port; diff --git a/src/building-blocks/rabbitmq/rabbitmq-publisher.js b/src/building-blocks/rabbitmq/rabbitmq-publisher.js index 3dc42ff..86f5cb7 100644 --- a/src/building-blocks/rabbitmq/rabbitmq-publisher.js +++ b/src/building-blocks/rabbitmq/rabbitmq-publisher.js @@ -35,7 +35,9 @@ let RabbitmqPublisher = class RabbitmqPublisher { try { await (0, async_retry_1.default)(async () => { const channel = await this.rabbitMQConnection.getChannel(); - const tracer = await this.openTelemetryTracer.createTracer({ serviceName: 'rabbitmq_publisher_tracer' }); + const tracer = await this.openTelemetryTracer.createTracer({ + serviceName: 'rabbitmq_publisher_tracer' + }); const exchangeName = (0, lodash_1.snakeCase)((0, reflection_1.getTypeName)(message)); const serializedMessage = (0, serilization_1.serializeObject)(message); const span = tracer.startSpan(`publish_message_${exchangeName}`); diff --git a/src/building-blocks/rabbitmq/rabbitmq-publisher.js.map b/src/building-blocks/rabbitmq/rabbitmq-publisher.js.map index b2951e0..756a4b6 100644 --- a/src/building-blocks/rabbitmq/rabbitmq-publisher.js.map +++ b/src/building-blocks/rabbitmq/rabbitmq-publisher.js.map @@ -1 +1 @@ -{"version":3,"file":"rabbitmq-publisher.js","sourceRoot":"","sources":["rabbitmq-publisher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAAA,2CAA0D;AAC1D,+DAA8E;AAC9E,wDAAwD;AACxD,oDAAkD;AAClD,mCAAmC;AACnC,+BAAoC;AACpC,uCAAuC;AAEvC,iEAAyC;AACzC,8DAAqC;AAErC,MAAM,iBAAiB,GAAa,EAAE,CAAC;AAQhC,IAAM,iBAAiB,GAAvB,MAAM,iBAAiB;IAC5B,YACmB,kBAAsC,EACN,mBAAyC;QADzE,uBAAkB,GAAlB,kBAAkB,CAAoB;QACN,wBAAmB,GAAnB,mBAAmB,CAAsB;IACzF,CAAC;IAEJ,KAAK,CAAC,cAAc,CAAI,OAAU;QAChC,IAAI,CAAC;YACH,MAAM,IAAA,qBAAU,EACd,KAAK,IAAI,EAAE;gBACT,MAAM,OAAO,GAAG,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KAAK;gBAC5B,MAAM,EAAE,iBAAO,CAAC,KAAK,CAAC,MAAM;gBAC5B,UAAU,EAAE,iBAAO,CAAC,KAAK,CAAC,UAAU;gBACpC,UAAU,EAAE,iBAAO,CAAC,KAAK,CAAC,UAAU;aACrC,CACF,CAAC;QACJ,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,eAAM,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;YACpB,MAAM,IAAI,CAAC,kBAAkB,CAAC,WAAW,EAAE,CAAC;QAC9C,CAAC;IACH,CAAC;IAED,KAAK,CAAC,WAAW,CAAI,OAAU;QAC7B,MAAM,YAAY,GAAG,IAAA,kBAAS,EAAC,IAAA,wBAAW,EAAC,OAAO,CAAC,CAAC,CAAC;QAErD,MAAM,WAAW,GAAG,iBAAiB,CAAC,QAAQ,CAAC,YAAY,CAAC,CAAC;QAE7D,OAAO,OAAO,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC;IACtC,CAAC;CACF,CAAA;AAjEY,8CAAiB;4BAAjB,iBAAiB;IAD7B,IAAA,mBAAU,GAAE;IAIR,WAAA,IAAA,eAAM,EAAC,sBAAsB,CAAC,CAAA;qCADM,wCAAkB;GAF9C,iBAAiB,CAiE7B"} \ No newline at end of file diff --git a/src/building-blocks/rabbitmq/rabbitmq-publisher.ts b/src/building-blocks/rabbitmq/rabbitmq-publisher.ts index 242ee4b..bd93bb5 100644 --- a/src/building-blocks/rabbitmq/rabbitmq-publisher.ts +++ b/src/building-blocks/rabbitmq/rabbitmq-publisher.ts @@ -1,11 +1,11 @@ -import {Inject, Injectable, Logger} from '@nestjs/common'; -import {IRabbitmqConnection, RabbitmqConnection} from './rabbitmq-connection'; +import { Inject, Injectable, Logger } from '@nestjs/common'; +import { IRabbitmqConnection, RabbitmqConnection } from './rabbitmq-connection'; import { serializeObject } from '../utils/serilization'; import { getTypeName } from '../utils/reflection'; import { snakeCase } from 'lodash'; import { v4 as uuidv4 } from 'uuid'; import { getUnixTime } from 'date-fns'; -import {IOpenTelemetryTracer, OpenTelemetryTracer} from '../openTelemetry/open-telemetry-tracer'; +import { IOpenTelemetryTracer, OpenTelemetryTracer } from '../openTelemetry/open-telemetry-tracer'; import configs from '../configs/configs'; import asyncRetry from 'async-retry'; @@ -29,7 +29,9 @@ export class RabbitmqPublisher implements IRabbitmqPublisher { async () => { const channel = await this.rabbitMQConnection.getChannel(); - const tracer = await this.openTelemetryTracer.createTracer({ serviceName: 'rabbitmq_publisher_tracer' }); + const tracer = await this.openTelemetryTracer.createTracer({ + serviceName: 'rabbitmq_publisher_tracer' + }); const exchangeName = snakeCase(getTypeName(message)); const serializedMessage = serializeObject(message); diff --git a/src/building-blocks/rabbitmq/rabbitmq-subscriber.js b/src/building-blocks/rabbitmq/rabbitmq-subscriber.js index 0d6b60f..5143699 100644 --- a/src/building-blocks/rabbitmq/rabbitmq-subscriber.js +++ b/src/building-blocks/rabbitmq/rabbitmq-subscriber.js @@ -34,7 +34,9 @@ let RabbitmqConsumer = class RabbitmqConsumer { try { await (0, async_retry_1.default)(async () => { const channel = await this.rabbitMQConnection.getChannel(); - const tracer = await this.openTelemetryTracer.createTracer({ serviceName: 'rabbitmq_subscriber_tracer' }); + const tracer = await this.openTelemetryTracer.createTracer({ + serviceName: 'rabbitmq_subscriber_tracer' + }); const exchangeName = (0, lodash_1.snakeCase)((0, reflection_1.getTypeName)(type)); await channel.assertExchange(exchangeName, 'fanout', { durable: false diff --git a/src/building-blocks/rabbitmq/rabbitmq-subscriber.js.map b/src/building-blocks/rabbitmq/rabbitmq-subscriber.js.map index 4c09f1e..be15977 100644 --- a/src/building-blocks/rabbitmq/rabbitmq-subscriber.js.map +++ b/src/building-blocks/rabbitmq/rabbitmq-subscriber.js.map @@ -1 +1 @@ -{"version":3,"file":"rabbitmq-subscriber.js","sourceRoot":"","sources":["rabbitmq-subscriber.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAAA,2CAA0D;AAC1D,+DAA2D;AAC3D,oDAAkD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AAG,SAAS,GAAG,WAAW,CAAC;QACxD,CAAC;IACH,CAAC;CACF,CAAA;AA3FY,4CAAgB;2BAAhB,gBAAgB;IAD5B,IAAA,mBAAU,GAAE;IAIR,WAAA,IAAA,eAAM,EAAC,sBAAsB,CAAC,CAAA;qCADM,wCAAkB;GAF9C,gBAAgB,CA2F5B"} \ No newline at end of file diff --git a/src/building-blocks/rabbitmq/rabbitmq-subscriber.ts b/src/building-blocks/rabbitmq/rabbitmq-subscriber.ts index a2aba4e..0669836 100644 --- a/src/building-blocks/rabbitmq/rabbitmq-subscriber.ts +++ b/src/building-blocks/rabbitmq/rabbitmq-subscriber.ts @@ -1,9 +1,9 @@ -import {Inject, Injectable, Logger} from '@nestjs/common'; +import { Inject, Injectable, Logger } from '@nestjs/common'; import { RabbitmqConnection } from './rabbitmq-connection'; import { getTypeName } from '../utils/reflection'; import { snakeCase } from 'lodash'; import { deserializeObject } from '../utils/serilization'; -import {IOpenTelemetryTracer, OpenTelemetryTracer} from '../openTelemetry/open-telemetry-tracer'; +import { IOpenTelemetryTracer, OpenTelemetryTracer } from '../openTelemetry/open-telemetry-tracer'; import { sleep } from '../utils/time'; import configs from '../configs/configs'; import asyncRetry from 'async-retry'; @@ -29,7 +29,9 @@ export class RabbitmqConsumer implements IRabbitmqConsumer { async () => { const channel = await this.rabbitMQConnection.getChannel(); - const tracer = await this.openTelemetryTracer.createTracer({ serviceName: 'rabbitmq_subscriber_tracer' }); + const tracer = await this.openTelemetryTracer.createTracer({ + serviceName: 'rabbitmq_subscriber_tracer' + }); const exchangeName = snakeCase(getTypeName(type)); diff --git a/src/building-blocks/rabbitmq/rabbitmq.module.js.map b/src/building-blocks/rabbitmq/rabbitmq.module.js.map index 11eb93a..9c0bb10 100644 --- a/src/building-blocks/rabbitmq/rabbitmq.module.js.map +++ b/src/building-blocks/rabbitmq/rabbitmq.module.js.map @@ -1 +1 @@ -{"version":3,"file":"rabbitmq.module.js","sourceRoot":"","sources":["rabbitmq.module.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,2CAA4F;AAC5F,6DAA2E;AAC3E,+DAA+F;AAC/F,kFAA2E;AAC3E,+DAAuD;AAsBhD,IAAM,cAAc,sBAApB,MAAM,cAAc;IACzB,YAA6B,kBAAsC;QAAtC,uBAAkB,GAAlB,kBAAkB,CAAoB;IAAG,CAAC;IACvE,KAAK,CAAC,qBAAqB,CAAC,MAAe;QACvC,MAAM,IAAI,CAAC,kBAAkB,CAAC,eAAe,EAAE,CAAC;IACpD,CAAC;IAED,MAAM,CAAC,OAAO,CAAC,OAAyB;QACtC,OAAO;YACL,MAAM,EAAE,gBAAc;YACtB,SAAS,EAAE,CAAC,wCAAkB,EAAE,EAAE,OAAO,EAAE,qCAAe,EAAE,QAAQ,EAAE,OAAO,EAAE,CAAC;SACjF,CAAC;IACJ,CAAC;CACF,CAAA;AAZY,wCAAc;yBAAd,cAAc;IApB1B,IAAA,eAAM,GAAE;IACR,IAAA,eAAM,EAAC;QACN,OAAO,EAAE,CAAC,2CAAmB,CAAC,OAAO,EAAE,CAAC;QACxC,SAAS,EAAE;YACT,sCAAiB;YACjB;gBACE,OAAO,EAAE,qBAAqB;gBAC9B,QAAQ,EAAE,wCAAkB;aAC7B;YACD;gBACE,OAAO,EAAE,oBAAoB;gBAC7B,QAAQ,EAAE,sCAAiB;aAC5B;YACD;gBACE,OAAO,EAAE,mBAAmB;gBAC5B,QAAQ,EAAE,sCAAgB;aAC3B;SACF;QACD,OAAO,EAAE,CAAC,qBAAqB,EAAE,oBAAoB,EAAE,mBAAmB,CAAC;KAC5E,CAAC;qCAEiD,wCAAkB;GADxD,cAAc,CAY1B"} \ No newline at end of file +{"version":3,"file":"rabbitmq.module.js","sourceRoot":"","sources":["rabbitmq.module.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,2CAA8F;AAC9F,6DAA6E;AAC7E,+DAAiG;AACjG,kFAA6E;AAC7E,+DAAyD;AAsBlD,IAAM,cAAc,sBAApB,MAAM,cAAc;IACzB,YAA6B,kBAAsC;QAAtC,uBAAkB,GAAlB,kBAAkB,CAAoB;IAAG,CAAC;IACvE,KAAK,CAAC,qBAAqB,CAAC,MAAe;QACzC,MAAM,IAAI,CAAC,kBAAkB,CAAC,eAAe,EAAE,CAAC;IAClD,CAAC;IAED,MAAM,CAAC,OAAO,CAAC,OAAyB;QACtC,OAAO;YACL,MAAM,EAAE,gBAAc;YACtB,SAAS,EAAE,CAAC,wCAAkB,EAAE,EAAE,OAAO,EAAE,qCAAe,EAAE,QAAQ,EAAE,OAAO,EAAE,CAAC;SACjF,CAAC;IACJ,CAAC;CACF,CAAA;AAZY,wCAAc;yBAAd,cAAc;IApB1B,IAAA,eAAM,GAAE;IACR,IAAA,eAAM,EAAC;QACN,OAAO,EAAE,CAAC,2CAAmB,CAAC,OAAO,EAAE,CAAC;QACxC,SAAS,EAAE;YACT,sCAAiB;YACjB;gBACE,OAAO,EAAE,qBAAqB;gBAC9B,QAAQ,EAAE,wCAAkB;aAC7B;YACD;gBACE,OAAO,EAAE,oBAAoB;gBAC7B,QAAQ,EAAE,sCAAiB;aAC5B;YACD;gBACE,OAAO,EAAE,mBAAmB;gBAC5B,QAAQ,EAAE,sCAAgB;aAC3B;SACF;QACD,OAAO,EAAE,CAAC,qBAAqB,EAAE,oBAAoB,EAAE,mBAAmB,CAAC;KAC5E,CAAC;qCAEiD,wCAAkB;GADxD,cAAc,CAY1B"} \ No newline at end of file diff --git a/src/building-blocks/rabbitmq/rabbitmq.module.ts b/src/building-blocks/rabbitmq/rabbitmq.module.ts index 21179ed..3bd1b44 100644 --- a/src/building-blocks/rabbitmq/rabbitmq.module.ts +++ b/src/building-blocks/rabbitmq/rabbitmq.module.ts @@ -1,8 +1,8 @@ -import {DynamicModule, Global, Inject, Module, OnApplicationShutdown} from '@nestjs/common'; -import {IRabbitmqPublisher, RabbitmqPublisher} from './rabbitmq-publisher'; -import {IRabbitmqConnection, RabbitmqConnection, RabbitmqOptions} from './rabbitmq-connection'; -import {OpenTelemetryModule} from '../openTelemetry/open-telemetry.module'; -import {RabbitmqConsumer} from "./rabbitmq-subscriber"; +import { DynamicModule, Global, Inject, Module, OnApplicationShutdown } from '@nestjs/common'; +import { IRabbitmqPublisher, RabbitmqPublisher } from './rabbitmq-publisher'; +import { IRabbitmqConnection, RabbitmqConnection, RabbitmqOptions } from './rabbitmq-connection'; +import { OpenTelemetryModule } from '../openTelemetry/open-telemetry.module'; +import { RabbitmqConsumer } from './rabbitmq-subscriber'; @Global() @Module({ @@ -27,7 +27,7 @@ import {RabbitmqConsumer} from "./rabbitmq-subscriber"; export class RabbitmqModule implements OnApplicationShutdown { constructor(private readonly rabbitmqConnection: RabbitmqConnection) {} async onApplicationShutdown(signal?: string) { - await this.rabbitmqConnection.closeConnection(); + await this.rabbitmqConnection.closeConnection(); } static forRoot(options?: RabbitmqOptions): DynamicModule { diff --git a/src/building-blocks/test/container/postgres/postgres-container.d.ts b/src/building-blocks/test/container/postgres/postgres-container.d.ts index d002413..ac530f9 100644 --- a/src/building-blocks/test/container/postgres/postgres-container.d.ts +++ b/src/building-blocks/test/container/postgres/postgres-container.d.ts @@ -1,6 +1,6 @@ import 'reflect-metadata'; import { StartedTestContainer } from 'testcontainers'; -import { DataSourceOptions, EntitySchema, MixedList } from "typeorm"; +import { DataSourceOptions, EntitySchema, MixedList } from 'typeorm'; export interface PostgresContainerOptions { imageName: string; type: string; diff --git a/src/building-blocks/test/container/postgres/postgres-container.js.map b/src/building-blocks/test/container/postgres/postgres-container.js.map index 930421d..9e89f97 100644 --- a/src/building-blocks/test/container/postgres/postgres-container.js.map +++ b/src/building-blocks/test/container/postgres/postgres-container.js.map @@ -1 +1 @@ -{"version":3,"file":"postgres-container.js","sourceRoot":"","sources":["postgres-container.ts"],"names":[],"mappings":";;;AAAA,4BAA0B;AAC1B,mDAAwE;AACxE,2CAAsC;AAgBtC,MAAa,iBAAiB;IACrB,KAAK,CAAC,KAAK;QAChB,MAAM,sBAAsB,GAAG,MAAM,IA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AM,eAAe,GAA6B;YAChD,IAAI,EAAE,UAAU;YAChB,QAAQ,EAAE,SAAS;YACnB,IAAI,EAAE,IAAI;YACV,IAAI,EAAE,WAAW;YACjB,QAAQ,EAAE,gBAAgB;YAC1B,QAAQ,EAAE,gBAAgB;YAC1B,SAAS,EAAE,iBAAiB;YAC5B,WAAW,EAAE,IAAI;YACjB,aAAa,EAAE,KAAK;YACpB,QAAQ,EAAE,CAAC,2BAA2B,CAAC;SACxC,CAAC;QAEF,OAAO,eAAe,CAAC;IACzB,CAAC;CACF;AAhDD,8CAgDC"} \ No newline at end of file diff --git a/src/building-blocks/test/container/postgres/postgres-container.ts b/src/building-blocks/test/container/postgres/postgres-container.ts index 0b90839..260ccdc 100644 --- a/src/building-blocks/test/container/postgres/postgres-container.ts +++ b/src/building-blocks/test/container/postgres/postgres-container.ts @@ -1,7 +1,7 @@ import 'reflect-metadata'; import { GenericContainer, StartedTestContainer } from 'testcontainers'; -import {Logger} from "@nestjs/common"; -import {DataSourceOptions, EntitySchema, MixedList} from "typeorm"; +import { Logger } from '@nestjs/common'; +import { DataSourceOptions, EntitySchema, MixedList } from 'typeorm'; export interface PostgresContainerOptions { imageName: string; @@ -16,8 +16,8 @@ export interface PostgresContainerOptions { migrationsRun: boolean; } -export class PostgresContainer{ - public async start(): Promise<[StartedTestContainer, DataSourceOptions]>{ +export class PostgresContainer { + public async start(): Promise<[StartedTestContainer, DataSourceOptions]> { const defaultPostgresOptions = await this.getDefaultPostgresTestContainers(); const pgContainerStarted = await this.getContainerStarted(defaultPostgresOptions); @@ -35,7 +35,9 @@ export class PostgresContainer{ return [pgContainerStarted, dataSourceOptions]; } - private async getContainerStarted(options: PostgresContainerOptions): Promise{ + private async getContainerStarted( + options: PostgresContainerOptions + ): Promise { const pgContainer = new GenericContainer(options.imageName) .withExposedPorts(options.port) .withEnvironment({ POSTGRES_USER: options.username }) @@ -46,7 +48,7 @@ export class PostgresContainer{ return pgContainerStarted; } - private async getDefaultPostgresTestContainers(): Promise{ + private async getDefaultPostgresTestContainers(): Promise { const postgresOptions: PostgresContainerOptions = { type: 'postgres', database: 'test_db', @@ -62,5 +64,4 @@ export class PostgresContainer{ return postgresOptions; } - } diff --git a/src/building-blocks/test/container/rabbitmq/rabbitmq-container.d.ts b/src/building-blocks/test/container/rabbitmq/rabbitmq-container.d.ts index 9b8cc3a..45b272f 100644 --- a/src/building-blocks/test/container/rabbitmq/rabbitmq-container.d.ts +++ b/src/building-blocks/test/container/rabbitmq/rabbitmq-container.d.ts @@ -1,6 +1,6 @@ import 'reflect-metadata'; import { StartedTestContainer } from 'testcontainers'; -import { RabbitmqOptions } from "../../../rabbitmq/rabbitmq-connection"; +import { RabbitmqOptions } from '../../../rabbitmq/rabbitmq-connection'; export interface RabbitmqContainerOptions { host: string; port: number; diff --git a/src/building-blocks/test/container/rabbitmq/rabbitmq-container.js.map b/src/building-blocks/test/container/rabbitmq/rabbitmq-container.js.map index 6a6c2fc..5492f72 100644 --- a/src/building-blocks/test/container/rabbitmq/rabbitmq-container.js.map +++ b/src/building-blocks/test/container/rabbitmq/rabbitmq-container.js.map @@ -1 +1 @@ -{"version":3,"file":"rabbitmq-container.js","sourceRoot":"","sources":["rabbitmq-container.ts"],"names":[],"mappings":";;;;;;AAAA,4BAA0B;AAC1B,mDAAwE;AACxE,2CAAsC;AACtC,uEAA+C;AAW/C,MAAa,iBAAiB;IACrB,KAAK,CAAC,KAAK;QAChB,MAAM,sBAAsB,GAAG,MAAM,IAAI,CAAC,gCAAgC,EAAE,CAAC;QAE7E,MAAM,wBAAwB,GAAG,MAAM,IAAI,CAAC,mBAAmB,CAAC,sBAAsB,CAAC,CAAC;QAExF,MAAM,aAAa,GAAG,wBAAwB,CAAC,aAAa,CAAC,sBAAsB,CAAC,IAAI,CAAC,CAAC;QAE1F,iBAAO,CAAC,QAAQ,mCACX,iBAAO,CAAC,QAAQ,KACnB,IAAI,EAAE,aAAa,EACnB,QAAQ,EAAE,sBAAsB,CAAC,QAAQ,E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No newline at end of file diff --git a/src/building-blocks/test/container/rabbitmq/rabbitmq-container.ts b/src/building-blocks/test/container/rabbitmq/rabbitmq-container.ts index 3980504..bab6c22 100644 --- a/src/building-blocks/test/container/rabbitmq/rabbitmq-container.ts +++ b/src/building-blocks/test/container/rabbitmq/rabbitmq-container.ts @@ -1,8 +1,8 @@ import 'reflect-metadata'; import { GenericContainer, StartedTestContainer } from 'testcontainers'; -import {Logger} from "@nestjs/common"; -import configs from "../../../configs/configs"; -import {RabbitmqOptions} from "../../../rabbitmq/rabbitmq-connection"; +import { Logger } from '@nestjs/common'; +import configs from '../../../configs/configs'; +import { RabbitmqOptions } from '../../../rabbitmq/rabbitmq-connection'; export interface RabbitmqContainerOptions { host: string; @@ -12,8 +12,8 @@ export interface RabbitmqContainerOptions { imageName: string; } -export class RabbitmqContainer{ - public async start(): Promise<[StartedTestContainer, RabbitmqOptions]>{ +export class RabbitmqContainer { + public async start(): Promise<[StartedTestContainer, RabbitmqOptions]> { const defaultRabbitmqOptions = await this.getDefaultRabbitmqTestContainers(); const rabbitmqContainerStarted = await this.getContainerStarted(defaultRabbitmqOptions); @@ -37,7 +37,9 @@ export class RabbitmqContainer{ return [rabbitmqContainerStarted, rabbitmqOptions]; } - private async getContainerStarted(options: RabbitmqContainerOptions): Promise{ + private async getContainerStarted( + options: RabbitmqContainerOptions + ): Promise { const rabbitmqContainer = new GenericContainer(options.imageName) .withExposedPorts(options.port) .withEnvironment({ RABBITMQ_DEFAULT_USER: options.username }) @@ -47,7 +49,7 @@ export class RabbitmqContainer{ return rabbitmqContainerStarted; } - private async getDefaultRabbitmqTestContainers(): Promise{ + private async getDefaultRabbitmqTestContainers(): Promise { const rabbitmqOptions: RabbitmqContainerOptions = { port: 5672, host: 'localhost', diff --git a/src/building-blocks/tsconfig.json b/src/building-blocks/tsconfig.json index 86929f1..fcae4cb 100644 --- a/src/building-blocks/tsconfig.json +++ b/src/building-blocks/tsconfig.json @@ -1,15 +1,34 @@ { "compilerOptions": { - "module": "commonjs", - "declaration": true, - "removeComments": true, - "emitDecoratorMetadata": true, - "experimentalDecorators": true, - "allowSyntheticDefaultImports": true, - "target": "es2017", - "sourceMap": true, - "baseUrl": "./", - "incremental": true, - "esModuleInterop": true - } + // Language and Environment + "target": "es2022", // Modern JavaScript features + "module": "commonjs", // Module system for Node.js + "lib": ["es2022"], // Include all ES2022 features + + // Modules and Output + "moduleResolution": "node", // Use Node.js module resolution + "baseUrl": "./", // Base directory for paths + "outDir": "./dist", // Output directory + "declaration": true, // Generate .d.ts files (mostly use in library development) + "sourceMap": true, // Generate source maps (mostly use in library development) + "removeComments": true, // Remove comments in output + + // Decorators (needed for NestJS) + "experimentalDecorators": true, // Enable decorators + "emitDecoratorMetadata": true, // Emit decorator metadata + + // Type Checking + "strict": false, // Enable all strict type checking + "skipLibCheck": true, // Skip type checking of declaration files + "forceConsistentCasingInFileNames": true, // Ensure consistent casing in imports + + // Interop Constraints + "esModuleInterop": true, // Enable ES Module interop + "allowSyntheticDefaultImports": true, // Allow default imports from modules + + // Advanced + "incremental": true, // Enable incremental compilation + "preserveConstEnums": true, // Keep const enums in output + "resolveJsonModule": true // Allow importing JSON files + }, } diff --git a/src/building-blocks/tsconfig.tsbuildinfo b/src/building-blocks/tsconfig.tsbuildinfo deleted file mode 100644 index 12f3475..0000000 --- a/src/building-blocks/tsconfig.tsbuildinfo +++ /dev/null @@ -1 +0,0 @@ -{"program":{"fileNames":["./node_modules/typescript/lib/lib.es5.d.ts","./node_modules/typescript/lib/lib.es2015.d.ts","./node_modules/typescript/lib/lib.es2016.d.ts","./node_modules/typescript/lib/lib.es2017.d.ts","./node_modules/typescript/lib/lib.es2018.d.ts","./node_modules/typescript/lib/lib.es2019.d.ts","./node_modules/typescript/lib/lib.es2020.d.ts","./node_modules/typescript/lib/lib.dom.d.ts","./node_modules/typescript/lib/lib.dom.iterable.d.ts","./node_modules/typescript/lib/lib.webworker.importscripts.d.ts","./node_modules/typescript/lib/lib.scripthost.d.ts","./node_modules/typescript/lib/lib.es2015.core.d.ts","./node_modules/typescript/lib/lib.es2015.collection.d.ts","./node_modules/typescript/lib/lib.es2015.generator.d.ts","./node_modules/typescript/lib/lib.es2015.iterable.d.ts","./node_modules/typescript/lib/lib.es2015.promise.d.ts","./node_modules/typescript/lib/lib.es2015.proxy.d.ts","./node_modules/typescript/lib/lib.es2015.reflect.d.ts","./node_modules/typescript/lib/lib.es2015.symbol.d.ts","./node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","./node_modules/typescript/lib/lib.es2016.array.include.d.ts","./node_modules/typescript/lib/lib.es2017.date.d.ts","./node_modules/typescript/lib/lib.es2017.object.d.ts","./node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","./node_modules/typescript/lib/lib.es2017.string.d.ts","./node_modules/typescript/lib/lib.es2017.intl.d.ts","./node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","./node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","./node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","./node_modules/typescript/lib/lib.es2018.intl.d.ts","./node_modules/typescript/lib/lib.es2018.promise.d.ts","./node_modules/typescript/lib/lib.es2018.regexp.d.ts","./node_modules/typescript/lib/lib.es2019.array.d.ts","./node_modules/typescript/lib/lib.es2019.object.d.ts","./node_modules/typescript/lib/lib.es2019.string.d.ts","./node_modules/typescript/lib/lib.es2019.symbol.d.ts","./node_modules/typescript/lib/lib.es2019.intl.d.ts","./node_modules/typescript/lib/lib.es2020.bigint.d.ts","./node_modules/typescript/lib/lib.es2020.date.d.ts","./node_modules/typescript/lib/lib.es2020.promise.d.ts","./node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","./node_modules/typescript/lib/lib.es2020.string.d.ts","./node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","./node_modules/typescript/lib/lib.es2020.intl.d.ts","./node_modules/typescript/lib/lib.es2020.number.d.ts","./node_modules/typescript/lib/lib.esnext.intl.d.ts","./node_modules/typescript/lib/lib.decorators.d.ts","./node_modules/typescript/lib/lib.decorators.legacy.d.ts","./node_modules/typescript/lib/lib.es2017.full.d.ts","./node_modules/@types/node/assert.d.ts","./node_modules/@types/node/assert/strict.d.ts","./node_modules/undici-types/header.d.ts","./node_modules/undici-types/readable.d.ts","./node_modules/undici-types/file.d.ts","./node_modules/undici-types/fetch.d.ts","./node_modules/undici-types/formdata.d.ts","./node_modules/undici-types/connector.d.ts","./node_modules/undici-types/client.d.ts","./node_modules/undici-types/errors.d.ts","./node_modules/undici-types/dispatcher.d.ts","./node_modules/undici-types/global-dispatcher.d.ts","./node_modules/undici-types/global-origin.d.ts","./node_modules/undici-types/pool-stats.d.ts","./node_modules/undici-types/pool.d.ts","./node_modules/undici-types/handlers.d.ts","./node_modules/undici-types/balanced-pool.d.ts","./node_modules/undici-types/agent.d.ts","./node_modules/undici-types/mock-interceptor.d.ts","./node_modules/undici-types/mock-agent.d.ts","./node_modules/undici-types/mock-client.d.ts","./node_modules/undici-types/mock-pool.d.ts","./node_modules/undici-types/mock-errors.d.ts","./node_modules/undici-types/proxy-agent.d.ts","./node_modules/undici-types/api.d.ts","./node_modules/undici-types/cookies.d.ts","./node_modules/undici-types/patch.d.ts","./node_modules/undici-types/filereader.d.ts","./node_modules/undici-types/diagnostics-channel.d.ts","./node_modules/undici-types/websocket.d.ts","./node_modules/undici-types/content-type.d.ts","./node_modules/undici-types/cache.d.ts","./node_modules/undici-types/interceptors.d.ts","./node_modules/undici-types/index.d.ts","./node_modules/@types/node/globals.d.ts","./node_modules/@types/node/async_hooks.d.ts","./node_modules/@types/node/buffer.d.ts","./node_modules/@types/node/child_process.d.ts","./node_modules/@types/node/cluster.d.ts","./node_modules/@types/node/console.d.ts","./node_modules/@types/node/constants.d.ts","./node_modules/@types/node/crypto.d.ts","./node_modules/@types/node/dgram.d.ts","./node_modules/@types/node/diagnostics_channel.d.ts","./node_modules/@types/node/dns.d.ts","./node_modules/@types/node/dns/promises.d.ts","./node_modules/@types/node/domain.d.ts","./node_modules/@types/node/dom-events.d.ts","./node_modules/@types/node/events.d.ts","./node_modules/@types/node/fs.d.ts","./node_modules/@types/node/fs/promises.d.ts","./node_modules/@types/node/http.d.ts","./node_modules/@types/node/http2.d.ts","./node_modules/@types/node/https.d.ts","./node_modules/@types/node/inspector.d.ts","./node_modules/@types/node/module.d.ts","./node_modules/@types/node/net.d.ts","./node_modules/@types/node/os.d.ts","./node_modules/@types/node/path.d.ts","./node_modules/@types/node/perf_hooks.d.ts","./node_modules/@types/node/process.d.ts","./node_modules/@types/node/punycode.d.ts","./node_modules/@types/node/querystring.d.ts","./node_modules/@types/node/readline.d.ts","./node_modules/@types/node/readline/promises.d.ts","./node_modules/@types/node/repl.d.ts","./node_modules/@types/node/stream.d.ts","./node_modules/@types/node/stream/promises.d.ts","./node_modules/@types/node/stream/consumers.d.ts","./node_modules/@types/node/stream/web.d.ts","./node_modules/@types/node/string_decoder.d.ts","./node_modules/@types/node/test.d.ts","./node_modules/@types/node/timers.d.ts","./node_modules/@types/node/timers/promises.d.ts","./node_modules/@types/node/tls.d.ts","./node_modules/@types/node/trace_events.d.ts","./node_modules/@types/node/tty.d.ts","./node_modules/@types/node/url.d.ts","./node_modules/@types/node/util.d.ts","./node_modules/@types/node/v8.d.ts","./node_modules/@types/node/vm.d.ts","./node_modules/@types/node/wasi.d.ts","./node_modules/@types/node/worker_threads.d.ts","./node_modules/@types/node/zlib.d.ts","./node_modules/@types/node/globals.global.d.ts","./node_modules/@types/node/index.d.ts","./node_modules/dotenv/lib/main.d.ts","./node_modules/joi/lib/index.d.ts","./configs/configs.ts","./node_modules/reflect-metadata/index.d.ts","./node_modules/@nestjs/common/decorators/core/bind.decorator.d.ts","./node_modules/@nestjs/common/interfaces/abstract.interface.d.ts","./node_modules/@nestjs/common/interfaces/controllers/controller-metadata.interface.d.ts","./node_modules/@nestjs/common/interfaces/controllers/controller.interface.d.ts","./node_modules/@nestjs/common/interfaces/features/arguments-host.interface.d.ts","./node_modules/@nestjs/common/interfaces/exceptions/exception-filter.interface.d.ts","./node_modules/rxjs/dist/types/internal/subscription.d.ts","./node_modules/rxjs/dist/types/internal/subscriber.d.ts","./node_modules/rxjs/dist/types/internal/operator.d.ts","./node_modules/rxjs/dist/types/internal/observable.d.ts","./node_modules/rxjs/dist/types/internal/types.d.ts","./node_modules/rxjs/dist/types/internal/operators/audit.d.ts","./node_modules/rxjs/dist/types/internal/operators/audittime.d.ts","./node_modules/rxjs/dist/types/internal/operators/buffer.d.ts","./node_modules/rxjs/dist/types/internal/operators/buffercount.d.ts","./node_modules/rxjs/dist/types/internal/operators/buffertime.d.ts","./node_modules/rxjs/dist/types/internal/operators/buffertoggle.d.ts","./node_modules/rxjs/dist/types/internal/operators/bufferwhen.d.ts","./node_modules/rxjs/dist/types/internal/operators/catcherror.d.ts","./node_modules/rxjs/dist/types/internal/operators/combinelatestall.d.ts","./node_modules/rxjs/dist/types/internal/operators/combineall.d.ts","./node_modules/rxjs/dist/types/internal/operators/combinelatest.d.ts","./node_modules/rxjs/dist/types/internal/operators/combinelatestwith.d.ts","./node_modules/rxjs/dist/types/internal/operators/concat.d.ts","./node_modules/rxjs/dist/types/internal/operators/concatall.d.ts","./node_modules/rxjs/dist/types/internal/operators/concatmap.d.ts","./node_modules/rxjs/dist/types/internal/operators/concatmapto.d.ts","./node_modules/rxjs/dist/types/internal/operators/concatwith.d.ts","./node_modules/rxjs/dist/types/internal/operators/connect.d.ts","./node_modules/rxjs/dist/types/internal/operators/count.d.ts","./node_modules/rxjs/dist/types/internal/operators/debounce.d.ts","./node_modules/rxjs/dist/types/internal/operators/debouncetime.d.ts","./node_modules/rxjs/dist/types/internal/operators/defaultifempty.d.ts","./node_modules/rxjs/dist/types/internal/operators/delay.d.ts","./node_modules/rxjs/dist/types/internal/operators/delaywhen.d.ts","./node_modules/rxjs/dist/types/internal/operators/dematerialize.d.ts","./node_modules/rxjs/dist/types/internal/operators/distinct.d.ts","./node_modules/rxjs/dist/types/internal/operators/distinctuntilchanged.d.ts","./node_modules/rxjs/dist/types/internal/operators/distinctuntilkeychanged.d.ts","./node_modules/rxjs/dist/types/internal/operators/elementat.d.ts","./node_modules/rxjs/dist/types/internal/operators/endwith.d.ts","./node_modules/rxjs/dist/types/internal/operators/every.d.ts","./node_modules/rxjs/dist/types/internal/operators/exhaustall.d.ts","./node_modules/rxjs/dist/types/internal/operators/exhaust.d.ts","./node_modules/rxjs/dist/types/internal/operators/exhaustmap.d.ts","./node_modules/rxjs/dist/types/internal/operators/expand.d.ts","./node_modules/rxjs/dist/types/internal/operators/filter.d.ts","./node_modules/rxjs/dist/types/internal/operators/finalize.d.ts","./node_modules/rxjs/dist/types/internal/operators/find.d.ts","./node_modules/rxjs/dist/types/internal/operators/findindex.d.ts","./node_modules/rxjs/dist/types/internal/operators/first.d.ts","./node_modules/rxjs/dist/types/internal/subject.d.ts","./node_modules/rxjs/dist/types/internal/operators/groupby.d.ts","./node_modules/rxjs/dist/types/internal/operators/ignoreelements.d.ts","./node_modules/rxjs/dist/types/internal/operators/isempty.d.ts","./node_modules/rxjs/dist/types/internal/operators/last.d.ts","./node_modules/rxjs/dist/types/internal/operators/map.d.ts","./node_modules/rxjs/dist/types/internal/operators/mapto.d.ts","./node_modules/rxjs/dist/types/internal/notification.d.ts","./node_modules/rxjs/dist/types/internal/operators/materialize.d.ts","./node_modules/rxjs/dist/types/internal/operators/max.d.ts","./node_modules/rxjs/dist/types/internal/operators/merge.d.ts","./node_modules/rxjs/dist/types/internal/operators/mergeall.d.ts","./node_modules/rxjs/dist/types/internal/operators/mergemap.d.ts","./node_modules/rxjs/dist/types/internal/operators/flatmap.d.ts","./node_modules/rxjs/dist/types/internal/operators/mergemapto.d.ts","./node_modules/rxjs/dist/types/internal/operators/mergescan.d.ts","./node_modules/rxjs/dist/types/internal/operators/mergewith.d.ts","./node_modules/rxjs/dist/types/internal/operators/min.d.ts","./node_modules/rxjs/dist/types/internal/observable/connectableobservable.d.ts","./node_modules/rxjs/dist/types/internal/operators/multicast.d.ts","./node_modules/rxjs/dist/types/internal/operators/observeon.d.ts","./node_modules/rxjs/dist/types/internal/operators/onerrorresumenextwith.d.ts","./node_modules/rxjs/dist/types/internal/operators/pairwise.d.ts","./node_modules/rxjs/dist/types/internal/operators/partition.d.ts","./node_modules/rxjs/dist/types/internal/operators/pluck.d.ts","./node_modules/rxjs/dist/types/internal/operators/publish.d.ts","./node_modules/rxjs/dist/types/internal/operators/publishbehavior.d.ts","./node_modules/rxjs/dist/types/internal/operators/publishlast.d.ts","./node_modules/rxjs/dist/types/internal/operators/publishreplay.d.ts","./node_modules/rxjs/dist/types/internal/operators/race.d.ts","./node_modules/rxjs/dist/types/internal/operators/racewith.d.ts","./node_modules/rxjs/dist/types/internal/operators/reduce.d.ts","./node_modules/rxjs/dist/types/internal/operators/repeat.d.ts","./node_modules/rxjs/dist/types/internal/operators/repeatwhen.d.ts","./node_modules/rxjs/dist/types/internal/operators/retry.d.ts","./node_modules/rxjs/dist/types/internal/operators/retrywhen.d.ts","./node_modules/rxjs/dist/types/internal/operators/refcount.d.ts","./node_modules/rxjs/dist/types/internal/operators/sample.d.ts","./node_modules/rxjs/dist/types/internal/operators/sampletime.d.ts","./node_modules/rxjs/dist/types/internal/operators/scan.d.ts","./node_modules/rxjs/dist/types/internal/operators/sequenceequal.d.ts","./node_modules/rxjs/dist/types/internal/operators/share.d.ts","./node_modules/rxjs/dist/types/internal/operators/sharereplay.d.ts","./node_modules/rxjs/dist/types/internal/operators/single.d.ts","./node_modules/rxjs/dist/types/internal/operators/skip.d.ts","./node_modules/rxjs/dist/types/internal/operators/skiplast.d.ts","./node_modules/rxjs/dist/types/internal/operators/skipuntil.d.ts","./node_modules/rxjs/dist/types/internal/operators/skipwhile.d.ts","./node_modules/rxjs/dist/types/internal/operators/startwith.d.ts","./node_modules/rxjs/dist/types/internal/operators/subscribeon.d.ts","./node_modules/rxjs/dist/types/internal/operators/switchall.d.ts","./node_modules/rxjs/dist/types/internal/operators/switchmap.d.ts","./node_modules/rxjs/dist/types/internal/operators/switchmapto.d.ts","./node_modules/rxjs/dist/types/internal/operators/switchscan.d.ts","./node_modules/rxjs/dist/types/internal/operators/take.d.ts","./node_modules/rxjs/dist/types/internal/operators/takelast.d.ts","./node_modules/rxjs/dist/types/internal/operators/takeuntil.d.ts","./node_modules/rxjs/dist/types/internal/operators/takewhile.d.ts","./node_modules/rxjs/dist/types/internal/operators/tap.d.ts","./node_modules/rxjs/dist/types/internal/operators/throttle.d.ts","./node_modules/rxjs/dist/types/internal/operators/throttletime.d.ts","./node_modules/rxjs/dist/types/internal/operators/throwifempty.d.ts","./node_modules/rxjs/dist/types/internal/operators/timeinterval.d.ts","./node_modules/rxjs/dist/types/internal/operators/timeout.d.ts","./node_modules/rxjs/dist/types/internal/operators/timeoutwith.d.ts","./node_modules/rxjs/dist/types/internal/operators/timestamp.d.ts","./node_modules/rxjs/dist/types/internal/operators/toarray.d.ts","./node_modules/rxjs/dist/types/internal/operators/window.d.ts","./node_modules/rxjs/dist/types/internal/operators/windowcount.d.ts","./node_modules/rxjs/dist/types/internal/operators/windowtime.d.ts","./node_modules/rxjs/dist/types/internal/operators/windowtoggle.d.ts","./node_modules/rxjs/dist/types/internal/operators/windowwhen.d.ts","./node_modules/rxjs/dist/types/internal/operators/withlatestfrom.d.ts","./node_modules/rxjs/dist/types/internal/operators/zip.d.ts","./node_modules/rxjs/dist/types/internal/operators/zipall.d.ts","./node_modules/rxjs/dist/types/internal/operators/zipwith.d.ts","./node_modules/rxjs/dist/types/operators/index.d.ts","./node_modules/rxjs/dist/types/internal/scheduler/action.d.ts","./node_modules/rxjs/dist/types/internal/scheduler.d.ts","./node_modules/rxjs/dist/types/internal/testing/testmessage.d.ts","./node_modules/rxjs/dist/types/internal/testing/subscriptionlog.d.ts","./node_modules/rxjs/dist/types/internal/testing/subscriptionloggable.d.ts","./node_modules/rxjs/dist/types/internal/testing/coldobservable.d.ts","./node_modules/rxjs/dist/types/internal/testing/hotobservable.d.ts","./node_modules/rxjs/dist/types/internal/scheduler/asyncscheduler.d.ts","./node_modules/rxjs/dist/types/internal/scheduler/timerhandle.d.ts","./node_modules/rxjs/dist/types/internal/scheduler/asyncaction.d.ts","./node_modules/rxjs/dist/types/internal/scheduler/virtualtimescheduler.d.ts","./node_modules/rxjs/dist/types/internal/testing/testscheduler.d.ts","./node_modules/rxjs/dist/types/testing/index.d.ts","./node_modules/rxjs/dist/types/internal/symbol/observable.d.ts","./node_modules/rxjs/dist/types/internal/observable/dom/animationframes.d.ts","./node_modules/rxjs/dist/types/internal/behaviorsubject.d.ts","./node_modules/rxjs/dist/types/internal/replaysubject.d.ts","./node_modules/rxjs/dist/types/internal/asyncsubject.d.ts","./node_modules/rxjs/dist/types/internal/scheduler/asapscheduler.d.ts","./node_modules/rxjs/dist/types/internal/scheduler/asap.d.ts","./node_modules/rxjs/dist/types/internal/scheduler/async.d.ts","./node_modules/rxjs/dist/types/internal/scheduler/queuescheduler.d.ts","./node_modules/rxjs/dist/types/internal/scheduler/queue.d.ts","./node_modules/rxjs/dist/types/internal/scheduler/animationframescheduler.d.ts","./node_modules/rxjs/dist/types/internal/scheduler/animationframe.d.ts","./node_modules/rxjs/dist/types/internal/util/identity.d.ts","./node_modules/rxjs/dist/types/internal/util/pipe.d.ts","./node_modules/rxjs/dist/types/internal/util/noop.d.ts","./node_modules/rxjs/dist/types/internal/util/isobservable.d.ts","./node_modules/rxjs/dist/types/internal/lastvaluefrom.d.ts","./node_modules/rxjs/dist/types/internal/firstvaluefrom.d.ts","./node_modules/rxjs/dist/types/internal/util/argumentoutofrangeerror.d.ts","./node_modules/rxjs/dist/types/internal/util/emptyerror.d.ts","./node_modules/rxjs/dist/types/internal/util/notfounderror.d.ts","./node_modules/rxjs/dist/types/internal/util/objectunsubscribederror.d.ts","./node_modules/rxjs/dist/types/internal/util/sequenceerror.d.ts","./node_modules/rxjs/dist/types/internal/util/unsubscriptionerror.d.ts","./node_modules/rxjs/dist/types/internal/observable/bindcallback.d.ts","./node_modules/rxjs/dist/types/internal/observable/bindnodecallback.d.ts","./node_modules/rxjs/dist/types/internal/anycatcher.d.ts","./node_modules/rxjs/dist/types/internal/observable/combinelatest.d.ts","./node_modules/rxjs/dist/types/internal/observable/concat.d.ts","./node_modules/rxjs/dist/types/internal/observable/connectable.d.ts","./node_modules/rxjs/dist/types/internal/observable/defer.d.ts","./node_modules/rxjs/dist/types/internal/observable/empty.d.ts","./node_modules/rxjs/dist/types/internal/observable/forkjoin.d.ts","./node_modules/rxjs/dist/types/internal/observable/from.d.ts","./node_modules/rxjs/dist/types/internal/observable/fromevent.d.ts","./node_modules/rxjs/dist/types/internal/observable/fromeventpattern.d.ts","./node_modules/rxjs/dist/types/internal/observable/generate.d.ts","./node_modules/rxjs/dist/types/internal/observable/iif.d.ts","./node_modules/rxjs/dist/types/internal/observable/interval.d.ts","./node_modules/rxjs/dist/types/internal/observable/merge.d.ts","./node_modules/rxjs/dist/types/internal/observable/never.d.ts","./node_modules/rxjs/dist/types/internal/observable/of.d.ts","./node_modules/rxjs/dist/types/internal/observable/onerrorresumenext.d.ts","./node_modules/rxjs/dist/types/internal/observable/pairs.d.ts","./node_modules/rxjs/dist/types/internal/observable/partition.d.ts","./node_modules/rxjs/dist/types/internal/observable/race.d.ts","./node_modules/rxjs/dist/types/internal/observable/range.d.ts","./node_modules/rxjs/dist/types/internal/observable/throwerror.d.ts","./node_modules/rxjs/dist/types/internal/observable/timer.d.ts","./node_modules/rxjs/dist/types/internal/observable/using.d.ts","./node_modules/rxjs/dist/types/internal/observable/zip.d.ts","./node_modules/rxjs/dist/types/internal/scheduled/scheduled.d.ts","./node_modules/rxjs/dist/types/internal/config.d.ts","./node_modules/rxjs/dist/types/index.d.ts","./node_modules/@nestjs/common/interfaces/exceptions/rpc-exception-filter.interface.d.ts","./node_modules/@nestjs/common/interfaces/exceptions/ws-exception-filter.interface.d.ts","./node_modules/@nestjs/common/interfaces/external/validation-error.interface.d.ts","./node_modules/@nestjs/common/interfaces/features/execution-context.interface.d.ts","./node_modules/@nestjs/common/interfaces/features/can-activate.interface.d.ts","./node_modules/@nestjs/common/interfaces/features/custom-route-param-factory.interface.d.ts","./node_modules/@nestjs/common/interfaces/features/nest-interceptor.interface.d.ts","./node_modules/@nestjs/common/interfaces/features/paramtype.interface.d.ts","./node_modules/@nestjs/common/interfaces/type.interface.d.ts","./node_modules/@nestjs/common/interfaces/features/pipe-transform.interface.d.ts","./node_modules/@nestjs/common/enums/request-method.enum.d.ts","./node_modules/@nestjs/common/enums/http-status.enum.d.ts","./node_modules/@nestjs/common/enums/shutdown-signal.enum.d.ts","./node_modules/@nestjs/common/enums/version-type.enum.d.ts","./node_modules/@nestjs/common/enums/index.d.ts","./node_modules/@nestjs/common/interfaces/version-options.interface.d.ts","./node_modules/@nestjs/common/interfaces/middleware/middleware-configuration.interface.d.ts","./node_modules/@nestjs/common/interfaces/middleware/middleware-consumer.interface.d.ts","./node_modules/@nestjs/common/interfaces/middleware/middleware-config-proxy.interface.d.ts","./node_modules/@nestjs/common/interfaces/middleware/nest-middleware.interface.d.ts","./node_modules/@nestjs/common/interfaces/middleware/index.d.ts","./node_modules/@nestjs/common/interfaces/global-prefix-options.interface.d.ts","./node_modules/@nestjs/common/interfaces/hooks/before-application-shutdown.interface.d.ts","./node_modules/@nestjs/common/interfaces/hooks/on-application-bootstrap.interface.d.ts","./node_modules/@nestjs/common/interfaces/hooks/on-application-shutdown.interface.d.ts","./node_modules/@nestjs/common/interfaces/hooks/on-destroy.interface.d.ts","./node_modules/@nestjs/common/interfaces/hooks/on-init.interface.d.ts","./node_modules/@nestjs/common/interfaces/hooks/index.d.ts","./node_modules/@nestjs/common/interfaces/http/http-exception-body.interface.d.ts","./node_modules/@nestjs/common/interfaces/http/http-redirect-response.interface.d.ts","./node_modules/@nestjs/common/interfaces/external/cors-options.interface.d.ts","./node_modules/@nestjs/common/interfaces/external/https-options.interface.d.ts","./node_modules/@nestjs/common/services/logger.service.d.ts","./node_modules/@nestjs/common/interfaces/nest-application-context-options.interface.d.ts","./node_modules/@nestjs/common/interfaces/nest-application-options.interface.d.ts","./node_modules/@nestjs/common/interfaces/http/http-server.interface.d.ts","./node_modules/@nestjs/common/interfaces/http/message-event.interface.d.ts","./node_modules/@nestjs/common/interfaces/http/raw-body-request.interface.d.ts","./node_modules/@nestjs/common/interfaces/http/index.d.ts","./node_modules/@nestjs/common/interfaces/injectable.interface.d.ts","./node_modules/@nestjs/common/interfaces/microservices/nest-hybrid-application-options.interface.d.ts","./node_modules/@nestjs/common/interfaces/modules/forward-reference.interface.d.ts","./node_modules/@nestjs/common/interfaces/scope-options.interface.d.ts","./node_modules/@nestjs/common/interfaces/modules/injection-token.interface.d.ts","./node_modules/@nestjs/common/interfaces/modules/optional-factory-dependency.interface.d.ts","./node_modules/@nestjs/common/interfaces/modules/provider.interface.d.ts","./node_modules/@nestjs/common/interfaces/modules/module-metadata.interface.d.ts","./node_modules/@nestjs/common/interfaces/modules/dynamic-module.interface.d.ts","./node_modules/@nestjs/common/interfaces/modules/introspection-result.interface.d.ts","./node_modules/@nestjs/common/interfaces/modules/nest-module.interface.d.ts","./node_modules/@nestjs/common/interfaces/modules/index.d.ts","./node_modules/@nestjs/common/interfaces/nest-application-context.interface.d.ts","./node_modules/@nestjs/common/interfaces/websockets/web-socket-adapter.interface.d.ts","./node_modules/@nestjs/common/interfaces/nest-application.interface.d.ts","./node_modules/@nestjs/common/interfaces/nest-microservice.interface.d.ts","./node_modules/@nestjs/common/interfaces/index.d.ts","./node_modules/@nestjs/common/decorators/core/catch.decorator.d.ts","./node_modules/@nestjs/common/decorators/core/controller.decorator.d.ts","./node_modules/@nestjs/common/decorators/core/dependencies.decorator.d.ts","./node_modules/@nestjs/common/decorators/core/exception-filters.decorator.d.ts","./node_modules/@nestjs/common/decorators/core/inject.decorator.d.ts","./node_modules/@nestjs/common/decorators/core/injectable.decorator.d.ts","./node_modules/@nestjs/common/decorators/core/optional.decorator.d.ts","./node_modules/@nestjs/common/decorators/core/set-metadata.decorator.d.ts","./node_modules/@nestjs/common/decorators/core/use-guards.decorator.d.ts","./node_modules/@nestjs/common/decorators/core/use-interceptors.decorator.d.ts","./node_modules/@nestjs/common/decorators/core/use-pipes.decorator.d.ts","./node_modules/@nestjs/common/decorators/core/apply-decorators.d.ts","./node_modules/@nestjs/common/decorators/core/version.decorator.d.ts","./node_modules/@nestjs/common/decorators/core/index.d.ts","./node_modules/@nestjs/common/decorators/modules/global.decorator.d.ts","./node_modules/@nestjs/common/decorators/modules/module.decorator.d.ts","./node_modules/@nestjs/common/decorators/modules/index.d.ts","./node_modules/@nestjs/common/decorators/http/request-mapping.decorator.d.ts","./node_modules/@nestjs/common/decorators/http/route-params.decorator.d.ts","./node_modules/@nestjs/common/decorators/http/http-code.decorator.d.ts","./node_modules/@nestjs/common/decorators/http/create-route-param-metadata.decorator.d.ts","./node_modules/@nestjs/common/decorators/http/render.decorator.d.ts","./node_modules/@nestjs/common/decorators/http/header.decorator.d.ts","./node_modules/@nestjs/common/decorators/http/redirect.decorator.d.ts","./node_modules/@nestjs/common/decorators/http/sse.decorator.d.ts","./node_modules/@nestjs/common/decorators/http/index.d.ts","./node_modules/@nestjs/common/decorators/index.d.ts","./node_modules/@nestjs/common/exceptions/http.exception.d.ts","./node_modules/@nestjs/common/exceptions/bad-request.exception.d.ts","./node_modules/@nestjs/common/exceptions/unauthorized.exception.d.ts","./node_modules/@nestjs/common/exceptions/method-not-allowed.exception.d.ts","./node_modules/@nestjs/common/exceptions/not-found.exception.d.ts","./node_modules/@nestjs/common/exceptions/forbidden.exception.d.ts","./node_modules/@nestjs/common/exceptions/not-acceptable.exception.d.ts","./node_modules/@nestjs/common/exceptions/request-timeout.exception.d.ts","./node_modules/@nestjs/common/exceptions/conflict.exception.d.ts","./node_modules/@nestjs/common/exceptions/gone.exception.d.ts","./node_modules/@nestjs/common/exceptions/payload-too-large.exception.d.ts","./node_modules/@nestjs/common/exceptions/unsupported-media-type.exception.d.ts","./node_modules/@nestjs/common/exceptions/unprocessable-entity.exception.d.ts","./node_modules/@nestjs/common/exceptions/internal-server-error.exception.d.ts","./node_modules/@nestjs/common/exceptions/not-implemented.exception.d.ts","./node_modules/@nestjs/common/exceptions/http-version-not-supported.exception.d.ts","./node_modules/@nestjs/common/exceptions/bad-gateway.exception.d.ts","./node_modules/@nestjs/common/exceptions/service-unavailable.exception.d.ts","./node_modules/@nestjs/common/exceptions/gateway-timeout.exception.d.ts","./node_modules/@nestjs/common/exceptions/im-a-teapot.exception.d.ts","./node_modules/@nestjs/common/exceptions/precondition-failed.exception.d.ts","./node_modules/@nestjs/common/exceptions/misdirected.exception.d.ts","./node_modules/@nestjs/common/exceptions/index.d.ts","./node_modules/@nestjs/common/file-stream/interfaces/streamable-options.interface.d.ts","./node_modules/@nestjs/common/file-stream/interfaces/streamable-handler-response.interface.d.ts","./node_modules/@nestjs/common/file-stream/interfaces/index.d.ts","./node_modules/@nestjs/common/services/console-logger.service.d.ts","./node_modules/@nestjs/common/services/index.d.ts","./node_modules/@nestjs/common/file-stream/streamable-file.d.ts","./node_modules/@nestjs/common/file-stream/index.d.ts","./node_modules/@nestjs/common/module-utils/constants.d.ts","./node_modules/@nestjs/common/module-utils/interfaces/configurable-module-async-options.interface.d.ts","./node_modules/@nestjs/common/module-utils/interfaces/configurable-module-cls.interface.d.ts","./node_modules/@nestjs/common/module-utils/interfaces/configurable-module-host.interface.d.ts","./node_modules/@nestjs/common/module-utils/interfaces/index.d.ts","./node_modules/@nestjs/common/module-utils/configurable-module.builder.d.ts","./node_modules/@nestjs/common/module-utils/index.d.ts","./node_modules/@nestjs/common/pipes/default-value.pipe.d.ts","./node_modules/@nestjs/common/interfaces/external/class-transform-options.interface.d.ts","./node_modules/@nestjs/common/interfaces/external/transformer-package.interface.d.ts","./node_modules/@nestjs/common/interfaces/external/validator-options.interface.d.ts","./node_modules/@nestjs/common/interfaces/external/validator-package.interface.d.ts","./node_modules/@nestjs/common/utils/http-error-by-code.util.d.ts","./node_modules/@nestjs/common/pipes/validation.pipe.d.ts","./node_modules/@nestjs/common/pipes/parse-array.pipe.d.ts","./node_modules/@nestjs/common/pipes/parse-bool.pipe.d.ts","./node_modules/@nestjs/common/pipes/parse-int.pipe.d.ts","./node_modules/@nestjs/common/pipes/parse-float.pipe.d.ts","./node_modules/@nestjs/common/pipes/parse-enum.pipe.d.ts","./node_modules/@nestjs/common/pipes/parse-uuid.pipe.d.ts","./node_modules/@nestjs/common/pipes/file/interfaces/file.interface.d.ts","./node_modules/@nestjs/common/pipes/file/interfaces/index.d.ts","./node_modules/@nestjs/common/pipes/file/file-validator.interface.d.ts","./node_modules/@nestjs/common/pipes/file/file-type.validator.d.ts","./node_modules/@nestjs/common/pipes/file/max-file-size.validator.d.ts","./node_modules/@nestjs/common/pipes/file/parse-file-options.interface.d.ts","./node_modules/@nestjs/common/pipes/file/parse-file.pipe.d.ts","./node_modules/@nestjs/common/pipes/file/parse-file-pipe.builder.d.ts","./node_modules/@nestjs/common/pipes/file/index.d.ts","./node_modules/@nestjs/common/pipes/index.d.ts","./node_modules/@nestjs/common/serializer/class-serializer.interfaces.d.ts","./node_modules/@nestjs/common/serializer/class-serializer.interceptor.d.ts","./node_modules/@nestjs/common/serializer/decorators/serialize-options.decorator.d.ts","./node_modules/@nestjs/common/serializer/decorators/index.d.ts","./node_modules/@nestjs/common/serializer/index.d.ts","./node_modules/@nestjs/common/utils/forward-ref.util.d.ts","./node_modules/@nestjs/common/utils/index.d.ts","./node_modules/@nestjs/common/index.d.ts","./node_modules/@types/mime/index.d.ts","./node_modules/@types/send/index.d.ts","./node_modules/@types/qs/index.d.ts","./node_modules/@types/range-parser/index.d.ts","./node_modules/@types/express-serve-static-core/index.d.ts","./node_modules/@types/http-errors/index.d.ts","./node_modules/@types/serve-static/index.d.ts","./node_modules/@types/connect/index.d.ts","./node_modules/@types/body-parser/index.d.ts","./node_modules/@types/express/index.d.ts","./context/context.ts","./node_modules/@nestjs/cqrs/dist/interfaces/commands/command.interface.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/commands/command-bus.interface.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/commands/command-handler.interface.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/commands/command-publisher.interface.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/events/event.interface.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/events/event-bus.interface.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/events/event-handler.interface.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/events/event-publisher.interface.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/events/message-source.interface.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/exceptions/unhandled-exception-info.interface.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/exceptions/unhandled-exception-publisher.interface.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/queries/query.interface.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/queries/query-bus.interface.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/queries/query-handler.interface.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/queries/query-publisher.interface.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/queries/query-result.interface.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/saga.type.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/index.d.ts","./node_modules/@nestjs/cqrs/dist/aggregate-root.d.ts","./node_modules/@nestjs/core/adapters/http-adapter.d.ts","./node_modules/@nestjs/core/adapters/index.d.ts","./node_modules/@nestjs/common/constants.d.ts","./node_modules/@nestjs/core/inspector/interfaces/edge.interface.d.ts","./node_modules/@nestjs/core/inspector/interfaces/entrypoint.interface.d.ts","./node_modules/@nestjs/core/inspector/interfaces/extras.interface.d.ts","./node_modules/@nestjs/core/inspector/interfaces/node.interface.d.ts","./node_modules/@nestjs/core/injector/settlement-signal.d.ts","./node_modules/@nestjs/core/injector/injector.d.ts","./node_modules/@nestjs/core/inspector/interfaces/serialized-graph-metadata.interface.d.ts","./node_modules/@nestjs/core/inspector/interfaces/serialized-graph-json.interface.d.ts","./node_modules/@nestjs/core/inspector/serialized-graph.d.ts","./node_modules/@nestjs/core/injector/module-token-factory.d.ts","./node_modules/@nestjs/core/injector/compiler.d.ts","./node_modules/@nestjs/core/injector/modules-container.d.ts","./node_modules/@nestjs/core/injector/container.d.ts","./node_modules/@nestjs/core/injector/instance-links-host.d.ts","./node_modules/@nestjs/core/injector/abstract-instance-resolver.d.ts","./node_modules/@nestjs/core/injector/module-ref.d.ts","./node_modules/@nestjs/core/injector/module.d.ts","./node_modules/@nestjs/core/injector/instance-wrapper.d.ts","./node_modules/@nestjs/core/router/interfaces/exclude-route-metadata.interface.d.ts","./node_modules/@nestjs/core/application-config.d.ts","./node_modules/@nestjs/core/constants.d.ts","./node_modules/@nestjs/core/discovery/discovery-module.d.ts","./node_modules/@nestjs/core/discovery/discovery-service.d.ts","./node_modules/@nestjs/core/discovery/index.d.ts","./node_modules/@nestjs/core/helpers/http-adapter-host.d.ts","./node_modules/@nestjs/core/exceptions/base-exception-filter.d.ts","./node_modules/@nestjs/core/exceptions/index.d.ts","./node_modules/@nestjs/core/helpers/context-id-factory.d.ts","./node_modules/@nestjs/common/interfaces/exceptions/exception-filter-metadata.interface.d.ts","./node_modules/@nestjs/core/exceptions/exceptions-handler.d.ts","./node_modules/@nestjs/core/router/router-proxy.d.ts","./node_modules/@nestjs/core/helpers/context-creator.d.ts","./node_modules/@nestjs/core/exceptions/base-exception-filter-context.d.ts","./node_modules/@nestjs/common/interfaces/exceptions/rpc-exception-filter-metadata.interface.d.ts","./node_modules/@nestjs/common/interfaces/exceptions/index.d.ts","./node_modules/@nestjs/core/exceptions/external-exception-filter.d.ts","./node_modules/@nestjs/core/exceptions/external-exceptions-handler.d.ts","./node_modules/@nestjs/core/exceptions/external-exception-filter-context.d.ts","./node_modules/@nestjs/core/guards/constants.d.ts","./node_modules/@nestjs/core/helpers/execution-context-host.d.ts","./node_modules/@nestjs/core/guards/guards-consumer.d.ts","./node_modules/@nestjs/core/guards/guards-context-creator.d.ts","./node_modules/@nestjs/core/guards/index.d.ts","./node_modules/@nestjs/core/interceptors/interceptors-consumer.d.ts","./node_modules/@nestjs/core/interceptors/interceptors-context-creator.d.ts","./node_modules/@nestjs/core/interceptors/index.d.ts","./node_modules/@nestjs/common/enums/route-paramtypes.enum.d.ts","./node_modules/@nestjs/core/pipes/params-token-factory.d.ts","./node_modules/@nestjs/core/pipes/pipes-consumer.d.ts","./node_modules/@nestjs/core/pipes/pipes-context-creator.d.ts","./node_modules/@nestjs/core/pipes/index.d.ts","./node_modules/@nestjs/core/helpers/context-utils.d.ts","./node_modules/@nestjs/core/injector/inquirer/inquirer-constants.d.ts","./node_modules/@nestjs/core/injector/inquirer/index.d.ts","./node_modules/@nestjs/core/interfaces/module-definition.interface.d.ts","./node_modules/@nestjs/core/interfaces/module-override.interface.d.ts","./node_modules/@nestjs/core/inspector/interfaces/enhancer-metadata-cache-entry.interface.d.ts","./node_modules/@nestjs/core/inspector/graph-inspector.d.ts","./node_modules/@nestjs/core/metadata-scanner.d.ts","./node_modules/@nestjs/core/scanner.d.ts","./node_modules/@nestjs/core/injector/instance-loader.d.ts","./node_modules/@nestjs/core/injector/lazy-module-loader/lazy-module-loader-options.interface.d.ts","./node_modules/@nestjs/core/injector/lazy-module-loader/lazy-module-loader.d.ts","./node_modules/@nestjs/core/injector/index.d.ts","./node_modules/@nestjs/core/helpers/interfaces/external-handler-metadata.interface.d.ts","./node_modules/@nestjs/core/helpers/interfaces/params-metadata.interface.d.ts","./node_modules/@nestjs/core/helpers/external-context-creator.d.ts","./node_modules/@nestjs/core/helpers/index.d.ts","./node_modules/@nestjs/core/inspector/initialize-on-preview.allowlist.d.ts","./node_modules/@nestjs/core/inspector/partial-graph.host.d.ts","./node_modules/@nestjs/core/inspector/index.d.ts","./node_modules/@nestjs/core/middleware/route-info-path-extractor.d.ts","./node_modules/@nestjs/core/middleware/routes-mapper.d.ts","./node_modules/@nestjs/core/middleware/builder.d.ts","./node_modules/@nestjs/core/middleware/index.d.ts","./node_modules/@nestjs/core/nest-application-context.d.ts","./node_modules/@nestjs/core/nest-application.d.ts","./node_modules/@nestjs/common/interfaces/microservices/nest-microservice-options.interface.d.ts","./node_modules/@nestjs/core/nest-factory.d.ts","./node_modules/@nestjs/core/repl/repl.d.ts","./node_modules/@nestjs/core/repl/index.d.ts","./node_modules/@nestjs/core/router/interfaces/routes.interface.d.ts","./node_modules/@nestjs/core/router/interfaces/index.d.ts","./node_modules/@nestjs/core/router/request/request-constants.d.ts","./node_modules/@nestjs/core/router/request/index.d.ts","./node_modules/@nestjs/core/router/router-module.d.ts","./node_modules/@nestjs/core/router/index.d.ts","./node_modules/@nestjs/core/services/reflector.service.d.ts","./node_modules/@nestjs/core/services/index.d.ts","./node_modules/@nestjs/core/index.d.ts","./node_modules/@nestjs/cqrs/dist/utils/observable-bus.d.ts","./node_modules/@nestjs/cqrs/dist/command-bus.d.ts","./node_modules/@nestjs/cqrs/dist/unhandled-exception-bus.d.ts","./node_modules/@nestjs/cqrs/dist/utils/index.d.ts","./node_modules/@nestjs/cqrs/dist/event-bus.d.ts","./node_modules/@nestjs/cqrs/dist/query-bus.d.ts","./node_modules/@nestjs/cqrs/dist/interfaces/cqrs-options.interface.d.ts","./node_modules/@nestjs/cqrs/dist/services/explorer.service.d.ts","./node_modules/@nestjs/cqrs/dist/cqrs.module.d.ts","./node_modules/@nestjs/cqrs/dist/decorators/command-handler.decorator.d.ts","./node_modules/@nestjs/cqrs/dist/decorators/events-handler.decorator.d.ts","./node_modules/@nestjs/cqrs/dist/decorators/query-handler.decorator.d.ts","./node_modules/@nestjs/cqrs/dist/decorators/saga.decorator.d.ts","./node_modules/@nestjs/cqrs/dist/decorators/index.d.ts","./node_modules/@nestjs/cqrs/dist/event-publisher.d.ts","./node_modules/@nestjs/cqrs/dist/exceptions/command-not-found.exception.d.ts","./node_modules/@nestjs/cqrs/dist/exceptions/invalid-command-handler.exception.d.ts","./node_modules/@nestjs/cqrs/dist/exceptions/invalid-events-handler.exception.d.ts","./node_modules/@nestjs/cqrs/dist/exceptions/invalid-query-handler.exception.d.ts","./node_modules/@nestjs/cqrs/dist/exceptions/invalid-saga.exception.d.ts","./node_modules/@nestjs/cqrs/dist/exceptions/query-not-found.exception.d.ts","./node_modules/@nestjs/cqrs/dist/exceptions/index.d.ts","./node_modules/@nestjs/cqrs/dist/operators/of-type.d.ts","./node_modules/@nestjs/cqrs/dist/operators/index.d.ts","./node_modules/@nestjs/cqrs/dist/index.d.ts","./node_modules/@nestjs/cqrs/index.d.ts","./contracts/booking.contract.ts","./contracts/flight.contract.ts","./contracts/identity.contract.ts","./contracts/passenger.contract.ts","./node_modules/http-problem-details/dist/problemdocument.d.ts","./node_modules/http-problem-details/dist/index.d.ts","./types/exeptions/application.exception.ts","./utils/serilization.ts","./filters/error-handlers.filter.ts","./node_modules/prom-client/index.d.ts","./monitoring/request-counter.middleware.ts","./monitoring/request-duration.middleware.ts","./monitoring/prometheus.metrics.ts","./node_modules/@opentelemetry/api/build/src/baggage/internal/symbol.d.ts","./node_modules/@opentelemetry/api/build/src/baggage/types.d.ts","./node_modules/@opentelemetry/api/build/src/baggage/utils.d.ts","./node_modules/@opentelemetry/api/build/src/common/exception.d.ts","./node_modules/@opentelemetry/api/build/src/common/time.d.ts","./node_modules/@opentelemetry/api/build/src/common/attributes.d.ts","./node_modules/@opentelemetry/api/build/src/context/types.d.ts","./node_modules/@opentelemetry/api/build/src/context/context.d.ts","./node_modules/@opentelemetry/api/build/src/api/context.d.ts","./node_modules/@opentelemetry/api/build/src/diag/types.d.ts","./node_modules/@opentelemetry/api/build/src/diag/consolelogger.d.ts","./node_modules/@opentelemetry/api/build/src/api/diag.d.ts","./node_modules/@opentelemetry/api/build/src/metrics/observableresult.d.ts","./node_modules/@opentelemetry/api/build/src/metrics/metric.d.ts","./node_modules/@opentelemetry/api/build/src/metrics/meter.d.ts","./node_modules/@opentelemetry/api/build/src/metrics/noopmeter.d.ts","./node_modules/@opentelemetry/api/build/src/metrics/meterprovider.d.ts","./node_modules/@opentelemetry/api/build/src/api/metrics.d.ts","./node_modules/@opentelemetry/api/build/src/propagation/textmappropagator.d.ts","./node_modules/@opentelemetry/api/build/src/baggage/context-helpers.d.ts","./node_modules/@opentelemetry/api/build/src/api/propagation.d.ts","./node_modules/@opentelemetry/api/build/src/trace/attributes.d.ts","./node_modules/@opentelemetry/api/build/src/trace/trace_state.d.ts","./node_modules/@opentelemetry/api/build/src/trace/span_context.d.ts","./node_modules/@opentelemetry/api/build/src/trace/link.d.ts","./node_modules/@opentelemetry/api/build/src/trace/status.d.ts","./node_modules/@opentelemetry/api/build/src/trace/span.d.ts","./node_modules/@opentelemetry/api/build/src/trace/span_kind.d.ts","./node_modules/@opentelemetry/api/build/src/trace/spanoptions.d.ts","./node_modules/@opentelemetry/api/build/src/trace/tracer.d.ts","./node_modules/@opentelemetry/api/build/src/trace/tracer_options.d.ts","./node_modules/@opentelemetry/api/build/src/trace/proxytracer.d.ts","./node_modules/@opentelemetry/api/build/src/trace/tracer_provider.d.ts","./node_modules/@opentelemetry/api/build/src/trace/proxytracerprovider.d.ts","./node_modules/@opentelemetry/api/build/src/trace/samplingresult.d.ts","./node_modules/@opentelemetry/api/build/src/trace/sampler.d.ts","./node_modules/@opentelemetry/api/build/src/trace/trace_flags.d.ts","./node_modules/@opentelemetry/api/build/src/trace/internal/utils.d.ts","./node_modules/@opentelemetry/api/build/src/trace/spancontext-utils.d.ts","./node_modules/@opentelemetry/api/build/src/trace/invalid-span-constants.d.ts","./node_modules/@opentelemetry/api/build/src/trace/context-utils.d.ts","./node_modules/@opentelemetry/api/build/src/api/trace.d.ts","./node_modules/@opentelemetry/api/build/src/context-api.d.ts","./node_modules/@opentelemetry/api/build/src/diag-api.d.ts","./node_modules/@opentelemetry/api/build/src/metrics-api.d.ts","./node_modules/@opentelemetry/api/build/src/propagation-api.d.ts","./node_modules/@opentelemetry/api/build/src/trace-api.d.ts","./node_modules/@opentelemetry/api/build/src/index.d.ts","./node_modules/@opentelemetry/core/build/src/baggage/propagation/w3cbaggagepropagator.d.ts","./node_modules/@opentelemetry/core/build/src/common/anchored-clock.d.ts","./node_modules/@opentelemetry/core/build/src/common/attributes.d.ts","./node_modules/@opentelemetry/core/build/src/common/types.d.ts","./node_modules/@opentelemetry/core/build/src/common/global-error-handler.d.ts","./node_modules/@opentelemetry/core/build/src/common/logging-error-handler.d.ts","./node_modules/@opentelemetry/core/build/src/common/time.d.ts","./node_modules/@opentelemetry/core/build/src/exportresult.d.ts","./node_modules/@opentelemetry/core/build/src/baggage/utils.d.ts","./node_modules/@opentelemetry/core/build/src/utils/environment.d.ts","./node_modules/@opentelemetry/core/build/src/platform/node/environment.d.ts","./node_modules/@opentelemetry/core/build/src/platform/node/globalthis.d.ts","./node_modules/@opentelemetry/core/build/src/platform/node/hex-to-base64.d.ts","./node_modules/@opentelemetry/core/build/src/trace/idgenerator.d.ts","./node_modules/@opentelemetry/core/build/src/platform/node/randomidgenerator.d.ts","./node_modules/@opentelemetry/core/build/src/platform/node/performance.d.ts","./node_modules/@opentelemetry/core/build/src/platform/node/sdk-info.d.ts","./node_modules/@opentelemetry/core/build/src/platform/node/timer-util.d.ts","./node_modules/@opentelemetry/core/build/src/platform/node/index.d.ts","./node_modules/@opentelemetry/core/build/src/platform/index.d.ts","./node_modules/@opentelemetry/core/build/src/propagation/composite.d.ts","./node_modules/@opentelemetry/core/build/src/trace/w3ctracecontextpropagator.d.ts","./node_modules/@opentelemetry/core/build/src/trace/rpc-metadata.d.ts","./node_modules/@opentelemetry/core/build/src/trace/sampler/alwaysoffsampler.d.ts","./node_modules/@opentelemetry/core/build/src/trace/sampler/alwaysonsampler.d.ts","./node_modules/@opentelemetry/core/build/src/trace/sampler/parentbasedsampler.d.ts","./node_modules/@opentelemetry/core/build/src/trace/sampler/traceidratiobasedsampler.d.ts","./node_modules/@opentelemetry/core/build/src/trace/suppress-tracing.d.ts","./node_modules/@opentelemetry/core/build/src/trace/tracestate.d.ts","./node_modules/@opentelemetry/core/build/src/utils/merge.d.ts","./node_modules/@opentelemetry/core/build/src/utils/sampling.d.ts","./node_modules/@opentelemetry/core/build/src/utils/timeout.d.ts","./node_modules/@opentelemetry/core/build/src/utils/url.d.ts","./node_modules/@opentelemetry/core/build/src/utils/wrap.d.ts","./node_modules/@opentelemetry/core/build/src/utils/callback.d.ts","./node_modules/@opentelemetry/core/build/src/version.d.ts","./node_modules/@opentelemetry/core/build/src/internal/exporter.d.ts","./node_modules/@opentelemetry/core/build/src/index.d.ts","./node_modules/@opentelemetry/resources/build/src/config.d.ts","./node_modules/@opentelemetry/resources/build/src/iresource.d.ts","./node_modules/@opentelemetry/resources/build/src/types.d.ts","./node_modules/@opentelemetry/resources/build/src/resource.d.ts","./node_modules/@opentelemetry/resources/build/src/platform/node/default-service-name.d.ts","./node_modules/@opentelemetry/resources/build/src/platform/node/hostdetector.d.ts","./node_modules/@opentelemetry/resources/build/src/platform/node/osdetector.d.ts","./node_modules/@opentelemetry/resources/build/src/platform/node/hostdetectorsync.d.ts","./node_modules/@opentelemetry/resources/build/src/platform/node/osdetectorsync.d.ts","./node_modules/@opentelemetry/resources/build/src/platform/node/processdetector.d.ts","./node_modules/@opentelemetry/resources/build/src/platform/node/processdetectorsync.d.ts","./node_modules/@opentelemetry/resources/build/src/platform/node/index.d.ts","./node_modules/@opentelemetry/resources/build/src/platform/index.d.ts","./node_modules/@opentelemetry/resources/build/src/detectors/browserdetector.d.ts","./node_modules/@opentelemetry/resources/build/src/detectors/envdetector.d.ts","./node_modules/@opentelemetry/resources/build/src/detectors/browserdetectorsync.d.ts","./node_modules/@opentelemetry/resources/build/src/detectors/envdetectorsync.d.ts","./node_modules/@opentelemetry/resources/build/src/detectors/index.d.ts","./node_modules/@opentelemetry/resources/build/src/detect-resources.d.ts","./node_modules/@opentelemetry/resources/build/src/index.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/idgenerator.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/sampler.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/types.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/timedevent.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/export/readablespan.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/export/spanexporter.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/basictracerprovider.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/span.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/spanprocessor.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/tracer.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/export/batchspanprocessorbase.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/platform/node/export/batchspanprocessor.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/platform/node/randomidgenerator.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/platform/node/index.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/platform/index.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/export/consolespanexporter.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/export/inmemoryspanexporter.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/export/simplespanprocessor.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/export/noopspanprocessor.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/sampler/alwaysoffsampler.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/sampler/alwaysonsampler.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/sampler/parentbasedsampler.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/sampler/traceidratiobasedsampler.d.ts","./node_modules/@opentelemetry/sdk-trace-base/build/src/index.d.ts","./node_modules/@opentelemetry/sdk-trace-node/build/src/config.d.ts","./node_modules/@opentelemetry/sdk-trace-node/build/src/nodetracerprovider.d.ts","./node_modules/@opentelemetry/sdk-trace-node/build/src/index.d.ts","./node_modules/@opentelemetry/exporter-zipkin/build/src/types.d.ts","./node_modules/@opentelemetry/exporter-zipkin/build/src/platform/node/util.d.ts","./node_modules/@opentelemetry/exporter-zipkin/build/src/platform/node/index.d.ts","./node_modules/@opentelemetry/exporter-zipkin/build/src/platform/index.d.ts","./node_modules/@opentelemetry/exporter-zipkin/build/src/zipkin.d.ts","./node_modules/@opentelemetry/exporter-zipkin/build/src/index.d.ts","./node_modules/@opentelemetry/instrumentation/build/src/types.d.ts","./node_modules/@types/shimmer/index.d.ts","./node_modules/@opentelemetry/instrumentation/build/src/instrumentation.d.ts","./node_modules/@opentelemetry/instrumentation/build/src/platform/node/instrumentation.d.ts","./node_modules/@opentelemetry/instrumentation/build/src/platform/node/types.d.ts","./node_modules/@opentelemetry/instrumentation/build/src/platform/node/instrumentationnodemoduledefinition.d.ts","./node_modules/@opentelemetry/instrumentation/build/src/platform/node/instrumentationnodemodulefile.d.ts","./node_modules/@opentelemetry/instrumentation/build/src/platform/node/index.d.ts","./node_modules/@opentelemetry/instrumentation/build/src/platform/index.d.ts","./node_modules/@opentelemetry/instrumentation/build/src/types_internal.d.ts","./node_modules/@opentelemetry/instrumentation/build/src/autoloader.d.ts","./node_modules/@opentelemetry/instrumentation/build/src/utils.d.ts","./node_modules/@opentelemetry/instrumentation/build/src/index.d.ts","./node_modules/@opentelemetry/instrumentation-amqplib/build/src/types.d.ts","./node_modules/@opentelemetry/instrumentation-amqplib/build/src/amqplib.d.ts","./node_modules/@opentelemetry/instrumentation-amqplib/build/src/index.d.ts","./node_modules/@opentelemetry/instrumentation-http/node_modules/@opentelemetry/instrumentation/build/src/types.d.ts","./node_modules/@opentelemetry/instrumentation-http/node_modules/@opentelemetry/instrumentation/build/src/instrumentation.d.ts","./node_modules/@opentelemetry/instrumentation-http/node_modules/@opentelemetry/instrumentation/build/src/platform/node/instrumentation.d.ts","./node_modules/@opentelemetry/instrumentation-http/node_modules/@opentelemetry/instrumentation/build/src/platform/node/index.d.ts","./node_modules/@opentelemetry/instrumentation-http/node_modules/@opentelemetry/instrumentation/build/src/platform/index.d.ts","./node_modules/@opentelemetry/instrumentation-http/node_modules/@opentelemetry/instrumentation/build/src/types_internal.d.ts","./node_modules/@opentelemetry/instrumentation-http/node_modules/@opentelemetry/instrumentation/build/src/autoloader.d.ts","./node_modules/@opentelemetry/instrumentation-http/node_modules/@opentelemetry/instrumentation/build/src/instrumentationnodemoduledefinition.d.ts","./node_modules/@opentelemetry/instrumentation-http/node_modules/@opentelemetry/instrumentation/build/src/instrumentationnodemodulefile.d.ts","./node_modules/@opentelemetry/instrumentation-http/node_modules/@opentelemetry/instrumentation/build/src/utils.d.ts","./node_modules/@opentelemetry/instrumentation-http/node_modules/@opentelemetry/instrumentation/build/src/index.d.ts","./node_modules/@opentelemetry/instrumentation-http/build/src/types.d.ts","./node_modules/@opentelemetry/instrumentation-http/build/src/http.d.ts","./node_modules/@opentelemetry/instrumentation-http/build/src/utils.d.ts","./node_modules/@opentelemetry/instrumentation-http/build/src/index.d.ts","./node_modules/@opentelemetry/instrumentation-express/build/src/enums/expresslayertype.d.ts","./node_modules/@opentelemetry/instrumentation-express/build/src/types.d.ts","./node_modules/@opentelemetry/instrumentation-express/build/src/instrumentation.d.ts","./node_modules/@opentelemetry/instrumentation-express/build/src/enums/attributenames.d.ts","./node_modules/@opentelemetry/instrumentation-express/build/src/index.d.ts","./node_modules/@opentelemetry/instrumentation-nestjs-core/build/src/instrumentation.d.ts","./node_modules/@opentelemetry/instrumentation-nestjs-core/build/src/enums/attributenames.d.ts","./node_modules/@opentelemetry/instrumentation-nestjs-core/build/src/index.d.ts","./node_modules/@opentelemetry/semantic-conventions/build/src/trace/semanticattributes.d.ts","./node_modules/@opentelemetry/semantic-conventions/build/src/trace/index.d.ts","./node_modules/@opentelemetry/semantic-conventions/build/src/resource/semanticresourceattributes.d.ts","./node_modules/@opentelemetry/semantic-conventions/build/src/resource/index.d.ts","./node_modules/@opentelemetry/semantic-conventions/build/src/index.d.ts","./node_modules/@opentelemetry/exporter-jaeger/build/src/types.d.ts","./node_modules/@opentelemetry/exporter-jaeger/build/src/jaeger.d.ts","./node_modules/@opentelemetry/exporter-jaeger/build/src/index.d.ts","./node_modules/@opentelemetry/sdk-logs/build/src/types.d.ts","./node_modules/@opentelemetry/api-logs/build/src/types/logrecord.d.ts","./node_modules/@opentelemetry/api-logs/build/src/types/logger.d.ts","./node_modules/@opentelemetry/api-logs/build/src/types/loggeroptions.d.ts","./node_modules/@opentelemetry/api-logs/build/src/types/loggerprovider.d.ts","./node_modules/@opentelemetry/api-logs/build/src/nooplogger.d.ts","./node_modules/@opentelemetry/api-logs/build/src/nooploggerprovider.d.ts","./node_modules/@opentelemetry/api-logs/build/src/api/logs.d.ts","./node_modules/@opentelemetry/api-logs/build/src/index.d.ts","./node_modules/@opentelemetry/sdk-logs/build/src/export/readablelogrecord.d.ts","./node_modules/@opentelemetry/sdk-logs/build/src/internal/loggerprovidersharedstate.d.ts","./node_modules/@opentelemetry/sdk-logs/build/src/logrecord.d.ts","./node_modules/@opentelemetry/sdk-logs/build/src/logrecordprocessor.d.ts","./node_modules/@opentelemetry/sdk-logs/build/src/loggerprovider.d.ts","./node_modules/@opentelemetry/sdk-logs/build/src/export/nooplogrecordprocessor.d.ts","./node_modules/@opentelemetry/sdk-logs/build/src/export/logrecordexporter.d.ts","./node_modules/@opentelemetry/sdk-logs/build/src/export/consolelogrecordexporter.d.ts","./node_modules/@opentelemetry/sdk-logs/build/src/export/simplelogrecordprocessor.d.ts","./node_modules/@opentelemetry/sdk-logs/build/src/export/inmemorylogrecordexporter.d.ts","./node_modules/@opentelemetry/sdk-logs/build/src/export/batchlogrecordprocessorbase.d.ts","./node_modules/@opentelemetry/sdk-logs/build/src/platform/node/export/batchlogrecordprocessor.d.ts","./node_modules/@opentelemetry/sdk-logs/build/src/platform/node/index.d.ts","./node_modules/@opentelemetry/sdk-logs/build/src/platform/index.d.ts","./node_modules/@opentelemetry/sdk-logs/build/src/index.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/view/attributesprocessor.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/view/predicate.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/view/instrumentselector.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/view/meterselector.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/export/aggregationtemporality.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/utils.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/aggregator/types.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/aggregator/drop.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/aggregator/histogram.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/aggregator/exponential-histogram/buckets.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/aggregator/exponential-histogram/mapping/types.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/aggregator/exponentialhistogram.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/aggregator/lastvalue.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/aggregator/sum.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/aggregator/index.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/view/aggregation.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/view/view.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/instrumentdescriptor.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/export/metricdata.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/export/aggregationselector.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/export/metricexporter.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/export/metricproducer.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/types.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/export/metricreader.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/export/periodicexportingmetricreader.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/export/inmemorymetricexporter.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/export/consolemetricexporter.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/meterprovider.d.ts","./node_modules/@opentelemetry/sdk-metrics/build/src/index.d.ts","./node_modules/@opentelemetry/sdk-node/node_modules/@opentelemetry/instrumentation/build/src/index.d.ts","./node_modules/@opentelemetry/sdk-node/build/src/types.d.ts","./node_modules/@opentelemetry/sdk-node/build/src/sdk.d.ts","./node_modules/@opentelemetry/sdk-node/build/src/index.d.ts","./opentelemetry/open-telemetry-tracer.ts","./opentelemetry/open-telemetry.module.ts","./node_modules/@nestjs/passport/dist/abstract.strategy.d.ts","./node_modules/@nestjs/passport/dist/interfaces/auth-module.options.d.ts","./node_modules/@nestjs/passport/dist/interfaces/type.interface.d.ts","./node_modules/@nestjs/passport/dist/interfaces/index.d.ts","./node_modules/@nestjs/passport/dist/auth.guard.d.ts","./node_modules/@nestjs/passport/dist/passport.module.d.ts","./node_modules/@types/passport/index.d.ts","./node_modules/@nestjs/passport/dist/passport/passport.serializer.d.ts","./node_modules/@nestjs/passport/dist/passport/passport.strategy.d.ts","./node_modules/@nestjs/passport/dist/index.d.ts","./node_modules/@nestjs/passport/index.d.ts","./passport/jwt.guard.ts","./node_modules/@types/jsonwebtoken/index.d.ts","./node_modules/@types/passport-strategy/index.d.ts","./node_modules/@types/passport-jwt/index.d.ts","./passport/jwt.strategy.ts","./node_modules/@types/amqplib/properties.d.ts","./node_modules/@types/amqplib/index.d.ts","./rabbitmq/rabbitmq-connection.ts","./utils/reflection.ts","./node_modules/@types/uuid/index.d.ts","./node_modules/date-fns/typings.d.ts","./rabbitmq/rabbitmq-publisher.ts","./utils/time.ts","./rabbitmq/rabbitmq-subscriber.ts","./rabbitmq/rabbitmq.module.ts","./node_modules/@types/ssh2/index.d.ts","./node_modules/@types/docker-modem/index.d.ts","./node_modules/@types/dockerode/index.d.ts","./node_modules/testcontainers/build/utils/port.d.ts","./node_modules/testcontainers/build/common/logger.d.ts","./node_modules/testcontainers/build/common/type-guards.d.ts","./node_modules/testcontainers/build/common/hash.d.ts","./node_modules/testcontainers/build/common/uuid.d.ts","./node_modules/testcontainers/build/common/streams.d.ts","./node_modules/testcontainers/build/common/file-lock.d.ts","./node_modules/testcontainers/build/common/clock.d.ts","./node_modules/testcontainers/build/common/retry.d.ts","./node_modules/testcontainers/build/common/index.d.ts","./node_modules/testcontainers/build/container-runtime/clients/compose/types.d.ts","./node_modules/testcontainers/build/container-runtime/clients/types.d.ts","./node_modules/testcontainers/build/container-runtime/clients/compose/compose-client.d.ts","./node_modules/testcontainers/build/container-runtime/clients/container/types.d.ts","./node_modules/testcontainers/build/container-runtime/clients/container/container-client.d.ts","./node_modules/testcontainers/build/container-runtime/image-name.d.ts","./node_modules/testcontainers/build/container-runtime/clients/image/image-client.d.ts","./node_modules/testcontainers/build/container-runtime/clients/network/network-client.d.ts","./node_modules/testcontainers/build/container-runtime/clients/client.d.ts","./node_modules/testcontainers/build/container-runtime/auth/types.d.ts","./node_modules/testcontainers/build/container-runtime/auth/get-auth-config.d.ts","./node_modules/testcontainers/build/container-runtime/clients/compose/parse-compose-container-name.d.ts","./node_modules/testcontainers/build/container-runtime/index.d.ts","./node_modules/testcontainers/build/types.d.ts","./node_modules/testcontainers/build/utils/bound-ports.d.ts","./node_modules/testcontainers/build/wait-strategies/wait-strategy.d.ts","./node_modules/testcontainers/build/network/network.d.ts","./node_modules/testcontainers/build/utils/pull-policy.d.ts","./node_modules/testcontainers/build/test-container.d.ts","./node_modules/testcontainers/build/generic-container/generic-container-builder.d.ts","./node_modules/testcontainers/build/generic-container/generic-container.d.ts","./node_modules/testcontainers/build/test-containers.d.ts","./node_modules/testcontainers/build/generic-container/started-generic-container.d.ts","./node_modules/testcontainers/build/docker-compose-environment/downed-docker-compose-environment.d.ts","./node_modules/testcontainers/build/docker-compose-environment/stopped-docker-compose-environment.d.ts","./node_modules/testcontainers/build/docker-compose-environment/started-docker-compose-environment.d.ts","./node_modules/testcontainers/build/docker-compose-environment/docker-compose-environment.d.ts","./node_modules/testcontainers/build/wait-strategies/http-wait-strategy.d.ts","./node_modules/testcontainers/build/wait-strategies/log-wait-strategy.d.ts","./node_modules/testcontainers/build/wait-strategies/shell-wait-strategy.d.ts","./node_modules/testcontainers/build/wait-strategies/composite-wait-strategy.d.ts","./node_modules/testcontainers/build/wait-strategies/wait.d.ts","./node_modules/testcontainers/build/wait-strategies/startup-check-strategy.d.ts","./node_modules/testcontainers/build/generic-container/abstract-started-container.d.ts","./node_modules/testcontainers/build/generic-container/abstract-stopped-container.d.ts","./node_modules/testcontainers/build/index.d.ts","./node_modules/typeorm/metadata/types/relationtypes.d.ts","./node_modules/typeorm/metadata/types/deferrabletype.d.ts","./node_modules/typeorm/metadata/types/ondeletetype.d.ts","./node_modules/typeorm/metadata/types/onupdatetype.d.ts","./node_modules/typeorm/decorator/options/relationoptions.d.ts","./node_modules/typeorm/metadata/types/propertytypeinfunction.d.ts","./node_modules/typeorm/common/objecttype.d.ts","./node_modules/typeorm/common/entitytarget.d.ts","./node_modules/typeorm/metadata/types/relationtypeinfunction.d.ts","./node_modules/typeorm/metadata-args/relationmetadataargs.d.ts","./node_modules/typeorm/driver/types/columntypes.d.ts","./node_modules/typeorm/decorator/options/valuetransformer.d.ts","./node_modules/typeorm/decorator/options/columncommonoptions.d.ts","./node_modules/typeorm/decorator/options/columnoptions.d.ts","./node_modules/typeorm/metadata-args/types/columnmode.d.ts","./node_modules/typeorm/metadata-args/columnmetadataargs.d.ts","./node_modules/typeorm/common/objectliteral.d.ts","./node_modules/typeorm/schema-builder/options/tablecolumnoptions.d.ts","./node_modules/typeorm/schema-builder/table/tablecolumn.d.ts","./node_modules/typeorm/schema-builder/options/viewoptions.d.ts","./node_modules/typeorm/schema-builder/view/view.d.ts","./node_modules/typeorm/naming-strategy/namingstrategyinterface.d.ts","./node_modules/typeorm/metadata/foreignkeymetadata.d.ts","./node_modules/typeorm/metadata/relationmetadata.d.ts","./node_modules/typeorm/metadata-args/embeddedmetadataargs.d.ts","./node_modules/typeorm/metadata-args/relationidmetadataargs.d.ts","./node_modules/typeorm/metadata/relationidmetadata.d.ts","./node_modules/typeorm/metadata/relationcountmetadata.d.ts","./node_modules/typeorm/metadata/types/eventlistenertypes.d.ts","./node_modules/typeorm/metadata-args/entitylistenermetadataargs.d.ts","./node_modules/typeorm/metadata/entitylistenermetadata.d.ts","./node_modules/typeorm/metadata-args/uniquemetadataargs.d.ts","./node_modules/typeorm/metadata/uniquemetadata.d.ts","./node_modules/typeorm/metadata/embeddedmetadata.d.ts","./node_modules/typeorm/metadata/columnmetadata.d.ts","./node_modules/typeorm/driver/types/ctecapabilities.d.ts","./node_modules/typeorm/driver/types/mappedcolumntypes.d.ts","./node_modules/typeorm/driver/query.d.ts","./node_modules/typeorm/driver/sqlinmemory.d.ts","./node_modules/typeorm/schema-builder/schemabuilder.d.ts","./node_modules/typeorm/driver/types/datatypedefaults.d.ts","./node_modules/typeorm/entity-schema/entityschemaindexoptions.d.ts","./node_modules/typeorm/driver/types/geojsontypes.d.ts","./node_modules/typeorm/decorator/options/spatialcolumnoptions.d.ts","./node_modules/typeorm/entity-schema/entityschemacolumnoptions.d.ts","./node_modules/typeorm/decorator/options/joincolumnoptions.d.ts","./node_modules/typeorm/decorator/options/jointablemultiplecolumnsoptions.d.ts","./node_modules/typeorm/decorator/options/jointableoptions.d.ts","./node_modules/typeorm/entity-schema/entityschemarelationoptions.d.ts","./node_modules/typeorm/find-options/orderbycondition.d.ts","./node_modules/typeorm/metadata/types/tabletypes.d.ts","./node_modules/typeorm/entity-schema/entityschemauniqueoptions.d.ts","./node_modules/typeorm/entity-schema/entityschemacheckoptions.d.ts","./node_modules/typeorm/entity-schema/entityschemaexclusionoptions.d.ts","./node_modules/typeorm/entity-schema/entityschemainheritanceoptions.d.ts","./node_modules/typeorm/entity-schema/entityschemarelationidoptions.d.ts","./node_modules/typeorm/entity-schema/entityschemaoptions.d.ts","./node_modules/typeorm/entity-schema/entityschema.d.ts","./node_modules/typeorm/logger/logger.d.ts","./node_modules/typeorm/logger/loggeroptions.d.ts","./node_modules/typeorm/driver/types/databasetype.d.ts","./node_modules/typeorm/cache/queryresultcacheoptions.d.ts","./node_modules/typeorm/cache/queryresultcache.d.ts","./node_modules/typeorm/common/mixedlist.d.ts","./node_modules/typeorm/data-source/basedatasourceoptions.d.ts","./node_modules/typeorm/driver/types/replicationmode.d.ts","./node_modules/typeorm/schema-builder/options/tableforeignkeyoptions.d.ts","./node_modules/typeorm/schema-builder/table/tableforeignkey.d.ts","./node_modules/typeorm/driver/types/upserttype.d.ts","./node_modules/typeorm/driver/driver.d.ts","./node_modules/typeorm/find-options/joinoptions.d.ts","./node_modules/typeorm/find-options/findoperatortype.d.ts","./node_modules/typeorm/find-options/findoperator.d.ts","./node_modules/typeorm/driver/mongodb/bson.typings.d.ts","./node_modules/typeorm/platform/platformtools.d.ts","./node_modules/typeorm/driver/mongodb/typings.d.ts","./node_modules/typeorm/find-options/equaloperator.d.ts","./node_modules/typeorm/find-options/findoptionswhere.d.ts","./node_modules/typeorm/find-options/findoptionsselect.d.ts","./node_modules/typeorm/find-options/findoptionsrelations.d.ts","./node_modules/typeorm/find-options/findoptionsorder.d.ts","./node_modules/typeorm/find-options/findoneoptions.d.ts","./node_modules/typeorm/find-options/findmanyoptions.d.ts","./node_modules/typeorm/common/deeppartial.d.ts","./node_modules/typeorm/repository/saveoptions.d.ts","./node_modules/typeorm/repository/removeoptions.d.ts","./node_modules/typeorm/find-options/mongodb/mongofindoneoptions.d.ts","./node_modules/typeorm/find-options/mongodb/mongofindmanyoptions.d.ts","./node_modules/typeorm/schema-builder/options/tableuniqueoptions.d.ts","./node_modules/typeorm/schema-builder/table/tableunique.d.ts","./node_modules/typeorm/subscriber/event/transactioncommitevent.d.ts","./node_modules/typeorm/subscriber/event/transactionrollbackevent.d.ts","./node_modules/typeorm/subscriber/event/transactionstartevent.d.ts","./node_modules/typeorm/subscriber/event/updateevent.d.ts","./node_modules/typeorm/subscriber/event/removeevent.d.ts","./node_modules/typeorm/subscriber/event/insertevent.d.ts","./node_modules/typeorm/subscriber/event/loadevent.d.ts","./node_modules/typeorm/subscriber/event/softremoveevent.d.ts","./node_modules/typeorm/subscriber/event/recoverevent.d.ts","./node_modules/typeorm/subscriber/entitysubscriberinterface.d.ts","./node_modules/typeorm/subscriber/broadcasterresult.d.ts","./node_modules/typeorm/subscriber/broadcaster.d.ts","./node_modules/typeorm/schema-builder/options/tablecheckoptions.d.ts","./node_modules/typeorm/metadata-args/checkmetadataargs.d.ts","./node_modules/typeorm/metadata/checkmetadata.d.ts","./node_modules/typeorm/schema-builder/table/tablecheck.d.ts","./node_modules/typeorm/schema-builder/options/tableexclusionoptions.d.ts","./node_modules/typeorm/metadata-args/exclusionmetadataargs.d.ts","./node_modules/typeorm/metadata/exclusionmetadata.d.ts","./node_modules/typeorm/schema-builder/table/tableexclusion.d.ts","./node_modules/typeorm/driver/mongodb/mongoqueryrunner.d.ts","./node_modules/typeorm/query-builder/querypartialentity.d.ts","./node_modules/typeorm/query-runner/queryresult.d.ts","./node_modules/typeorm/query-builder/result/insertresult.d.ts","./node_modules/typeorm/query-builder/result/updateresult.d.ts","./node_modules/typeorm/query-builder/result/deleteresult.d.ts","./node_modules/typeorm/entity-manager/mongoentitymanager.d.ts","./node_modules/typeorm/repository/mongorepository.d.ts","./node_modules/typeorm/find-options/findtreeoptions.d.ts","./node_modules/typeorm/repository/treerepository.d.ts","./node_modules/typeorm/query-builder/transformer/plainobjecttonewentitytransformer.d.ts","./node_modules/typeorm/driver/types/isolationlevel.d.ts","./node_modules/typeorm/query-builder/insertorupdateoptions.d.ts","./node_modules/typeorm/repository/upsertoptions.d.ts","./node_modules/typeorm/common/pickkeysbytype.d.ts","./node_modules/typeorm/entity-manager/entitymanager.d.ts","./node_modules/typeorm/repository/repository.d.ts","./node_modules/typeorm/migration/migrationinterface.d.ts","./node_modules/typeorm/migration/migration.d.ts","./node_modules/typeorm/driver/cockroachdb/cockroachconnectioncredentialsoptions.d.ts","./node_modules/typeorm/driver/cockroachdb/cockroachconnectionoptions.d.ts","./node_modules/typeorm/driver/mysql/mysqlconnectioncredentialsoptions.d.ts","./node_modules/typeorm/driver/mysql/mysqlconnectionoptions.d.ts","./node_modules/typeorm/driver/postgres/postgresconnectioncredentialsoptions.d.ts","./node_modules/typeorm/driver/postgres/postgresconnectionoptions.d.ts","./node_modules/typeorm/driver/sqlite/sqliteconnectionoptions.d.ts","./node_modules/typeorm/driver/sqlserver/authentication/defaultauthentication.d.ts","./node_modules/typeorm/driver/sqlserver/authentication/azureactivedirectoryaccesstokenauthentication.d.ts","./node_modules/typeorm/driver/sqlserver/authentication/azureactivedirectorymsiappserviceauthentication.d.ts","./node_modules/typeorm/driver/sqlserver/authentication/azureactivedirectorymsivmauthentication.d.ts","./node_modules/typeorm/driver/sqlserver/authentication/azureactivedirectorypasswordauthentication.d.ts","./node_modules/typeorm/driver/sqlserver/authentication/azureactivedirectoryserviceprincipalsecret.d.ts","./node_modules/typeorm/driver/sqlserver/authentication/ntlmauthentication.d.ts","./node_modules/typeorm/driver/sqlserver/sqlserverconnectioncredentialsoptions.d.ts","./node_modules/typeorm/driver/sqlserver/sqlserverconnectionoptions.d.ts","./node_modules/typeorm/driver/oracle/oracleconnectioncredentialsoptions.d.ts","./node_modules/typeorm/driver/oracle/oracleconnectionoptions.d.ts","./node_modules/typeorm/driver/mongodb/mongoconnectionoptions.d.ts","./node_modules/typeorm/driver/cordova/cordovaconnectionoptions.d.ts","./node_modules/typeorm/driver/sqljs/sqljsconnectionoptions.d.ts","./node_modules/typeorm/driver/react-native/reactnativeconnectionoptions.d.ts","./node_modules/typeorm/driver/nativescript/nativescriptconnectionoptions.d.ts","./node_modules/typeorm/driver/expo/expoconnectionoptions.d.ts","./node_modules/typeorm/driver/aurora-mysql/auroramysqlconnectioncredentialsoptions.d.ts","./node_modules/typeorm/driver/aurora-mysql/auroramysqlconnectionoptions.d.ts","./node_modules/typeorm/driver/sap/sapconnectioncredentialsoptions.d.ts","./node_modules/typeorm/driver/sap/sapconnectionoptions.d.ts","./node_modules/typeorm/driver/aurora-postgres/aurorapostgresconnectionoptions.d.ts","./node_modules/typeorm/driver/better-sqlite3/bettersqlite3connectionoptions.d.ts","./node_modules/typeorm/driver/capacitor/capacitorconnectionoptions.d.ts","./node_modules/typeorm/connection/baseconnectionoptions.d.ts","./node_modules/typeorm/driver/spanner/spannerconnectioncredentialsoptions.d.ts","./node_modules/typeorm/driver/spanner/spannerconnectionoptions.d.ts","./node_modules/typeorm/data-source/datasourceoptions.d.ts","./node_modules/typeorm/entity-manager/sqljsentitymanager.d.ts","./node_modules/typeorm/query-builder/relationloader.d.ts","./node_modules/typeorm/query-builder/relationidloader.d.ts","./node_modules/typeorm/data-source/datasource.d.ts","./node_modules/typeorm/metadata-args/tablemetadataargs.d.ts","./node_modules/typeorm/metadata/types/treetypes.d.ts","./node_modules/typeorm/metadata/types/closuretreeoptions.d.ts","./node_modules/typeorm/metadata-args/treemetadataargs.d.ts","./node_modules/typeorm/metadata/entitymetadata.d.ts","./node_modules/typeorm/metadata-args/indexmetadataargs.d.ts","./node_modules/typeorm/metadata/indexmetadata.d.ts","./node_modules/typeorm/schema-builder/options/tableindexoptions.d.ts","./node_modules/typeorm/schema-builder/table/tableindex.d.ts","./node_modules/typeorm/schema-builder/options/tableoptions.d.ts","./node_modules/typeorm/schema-builder/table/table.d.ts","./node_modules/typeorm/query-runner/queryrunner.d.ts","./node_modules/typeorm/query-builder/querybuildercte.d.ts","./node_modules/typeorm/query-builder/alias.d.ts","./node_modules/typeorm/query-builder/joinattribute.d.ts","./node_modules/typeorm/query-builder/relation-id/relationidattribute.d.ts","./node_modules/typeorm/query-builder/relation-count/relationcountattribute.d.ts","./node_modules/typeorm/query-builder/selectquery.d.ts","./node_modules/typeorm/query-builder/selectquerybuilderoption.d.ts","./node_modules/typeorm/query-builder/whereclause.d.ts","./node_modules/typeorm/query-builder/queryexpressionmap.d.ts","./node_modules/typeorm/query-builder/brackets.d.ts","./node_modules/typeorm/query-builder/whereexpressionbuilder.d.ts","./node_modules/typeorm/query-builder/updatequerybuilder.d.ts","./node_modules/typeorm/query-builder/deletequerybuilder.d.ts","./node_modules/typeorm/query-builder/softdeletequerybuilder.d.ts","./node_modules/typeorm/query-builder/insertquerybuilder.d.ts","./node_modules/typeorm/query-builder/relationquerybuilder.d.ts","./node_modules/typeorm/query-builder/notbrackets.d.ts","./node_modules/typeorm/query-builder/querybuilder.d.ts","./node_modules/typeorm/query-builder/selectquerybuilder.d.ts","./node_modules/typeorm/metadata-args/relationcountmetadataargs.d.ts","./node_modules/typeorm/metadata-args/namingstrategymetadataargs.d.ts","./node_modules/typeorm/metadata-args/joincolumnmetadataargs.d.ts","./node_modules/typeorm/metadata-args/jointablemetadataargs.d.ts","./node_modules/typeorm/metadata-args/entitysubscribermetadataargs.d.ts","./node_modules/typeorm/metadata-args/inheritancemetadataargs.d.ts","./node_modules/typeorm/metadata-args/discriminatorvaluemetadataargs.d.ts","./node_modules/typeorm/metadata-args/entityrepositorymetadataargs.d.ts","./node_modules/typeorm/metadata-args/transactionentitymetadataargs.d.ts","./node_modules/typeorm/metadata-args/transactionrepositorymetadataargs.d.ts","./node_modules/typeorm/metadata-args/generatedmetadataargs.d.ts","./node_modules/typeorm/metadata-args/metadataargsstorage.d.ts","./node_modules/typeorm/connection/connectionmanager.d.ts","./node_modules/typeorm/globals.d.ts","./node_modules/typeorm/container.d.ts","./node_modules/typeorm/common/relationtype.d.ts","./node_modules/typeorm/error/typeormerror.d.ts","./node_modules/typeorm/error/cannotreflectmethodparametertypeerror.d.ts","./node_modules/typeorm/error/alreadyhasactiveconnectionerror.d.ts","./node_modules/typeorm/persistence/subjectchangemap.d.ts","./node_modules/typeorm/persistence/subject.d.ts","./node_modules/typeorm/error/subjectwithoutidentifiererror.d.ts","./node_modules/typeorm/error/cannotconnectalreadyconnectederror.d.ts","./node_modules/typeorm/error/locknotsupportedongivendrivererror.d.ts","./node_modules/typeorm/error/connectionisnotseterror.d.ts","./node_modules/typeorm/error/cannotcreateentityidmaperror.d.ts","./node_modules/typeorm/error/metadataalreadyexistserror.d.ts","./node_modules/typeorm/error/cannotdetermineentityerror.d.ts","./node_modules/typeorm/error/updatevaluesmissingerror.d.ts","./node_modules/typeorm/error/treerepositorynotsupportederror.d.ts","./node_modules/typeorm/error/customrepositorynotfounderror.d.ts","./node_modules/typeorm/error/transactionnotstartederror.d.ts","./node_modules/typeorm/error/transactionalreadystartederror.d.ts","./node_modules/typeorm/error/entitynotfounderror.d.ts","./node_modules/typeorm/error/entitymetadatanotfounderror.d.ts","./node_modules/typeorm/error/mustbeentityerror.d.ts","./node_modules/typeorm/error/optimisticlockversionmismatcherror.d.ts","./node_modules/typeorm/error/limitonupdatenotsupportederror.d.ts","./node_modules/typeorm/error/primarycolumncannotbenullableerror.d.ts","./node_modules/typeorm/error/customrepositorycannotinheritrepositoryerror.d.ts","./node_modules/typeorm/error/queryrunnerprovideralreadyreleasederror.d.ts","./node_modules/typeorm/error/cannotattachtreechildrenentityerror.d.ts","./node_modules/typeorm/error/customrepositorydoesnothaveentityerror.d.ts","./node_modules/typeorm/error/missingdeletedatecolumnerror.d.ts","./node_modules/typeorm/error/noconnectionforrepositoryerror.d.ts","./node_modules/typeorm/error/circularrelationserror.d.ts","./node_modules/typeorm/error/returningstatementnotsupportederror.d.ts","./node_modules/typeorm/error/usingjointableisnotallowederror.d.ts","./node_modules/typeorm/error/missingjoincolumnerror.d.ts","./node_modules/typeorm/error/missingprimarycolumnerror.d.ts","./node_modules/typeorm/error/entitypropertynotfounderror.d.ts","./node_modules/typeorm/error/missingdrivererror.d.ts","./node_modules/typeorm/error/driverpackagenotinstallederror.d.ts","./node_modules/typeorm/error/cannotgetentitymanagernotconnectederror.d.ts","./node_modules/typeorm/error/connectionnotfounderror.d.ts","./node_modules/typeorm/error/noversionorupdatedatecolumnerror.d.ts","./node_modules/typeorm/error/insertvaluesmissingerror.d.ts","./node_modules/typeorm/error/optimisticlockcannotbeusederror.d.ts","./node_modules/typeorm/error/metadatawithsuchnamealreadyexistserror.d.ts","./node_modules/typeorm/error/driveroptionnotseterror.d.ts","./node_modules/typeorm/error/findrelationsnotfounderror.d.ts","./node_modules/typeorm/error/namingstrategynotfounderror.d.ts","./node_modules/typeorm/error/pessimisticlocktransactionrequirederror.d.ts","./node_modules/typeorm/error/repositorynottreeerror.d.ts","./node_modules/typeorm/error/datatypenotsupportederror.d.ts","./node_modules/typeorm/error/initializedrelationerror.d.ts","./node_modules/typeorm/error/missingjointableerror.d.ts","./node_modules/typeorm/error/queryfailederror.d.ts","./node_modules/typeorm/error/noneedtoreleaseentitymanagererror.d.ts","./node_modules/typeorm/error/usingjoincolumnonlyononesideallowederror.d.ts","./node_modules/typeorm/error/usingjointableonlyononesideallowederror.d.ts","./node_modules/typeorm/error/subjectremovedandupdatederror.d.ts","./node_modules/typeorm/error/persistedentitynotfounderror.d.ts","./node_modules/typeorm/error/usingjoincolumnisnotallowederror.d.ts","./node_modules/typeorm/error/columntypeundefinederror.d.ts","./node_modules/typeorm/error/queryrunneralreadyreleasederror.d.ts","./node_modules/typeorm/error/offsetwithoutlimitnotsupportederror.d.ts","./node_modules/typeorm/error/cannotexecutenotconnectederror.d.ts","./node_modules/typeorm/error/noconnectionoptionerror.d.ts","./node_modules/typeorm/error/forbiddentransactionmodeoverrideerror.d.ts","./node_modules/typeorm/error/index.d.ts","./node_modules/typeorm/decorator/options/columnwithlengthoptions.d.ts","./node_modules/typeorm/decorator/options/columnnumericoptions.d.ts","./node_modules/typeorm/decorator/options/columnenumoptions.d.ts","./node_modules/typeorm/decorator/options/columnembeddedoptions.d.ts","./node_modules/typeorm/decorator/options/columnhstoreoptions.d.ts","./node_modules/typeorm/decorator/options/columnwithwidthoptions.d.ts","./node_modules/typeorm/decorator/columns/column.d.ts","./node_modules/typeorm/decorator/columns/createdatecolumn.d.ts","./node_modules/typeorm/decorator/columns/deletedatecolumn.d.ts","./node_modules/typeorm/decorator/options/primarygeneratedcolumnnumericoptions.d.ts","./node_modules/typeorm/decorator/options/primarygeneratedcolumnuuidoptions.d.ts","./node_modules/typeorm/decorator/options/primarygeneratedcolumnidentityoptions.d.ts","./node_modules/typeorm/decorator/columns/primarygeneratedcolumn.d.ts","./node_modules/typeorm/decorator/columns/primarycolumn.d.ts","./node_modules/typeorm/decorator/columns/updatedatecolumn.d.ts","./node_modules/typeorm/decorator/columns/versioncolumn.d.ts","./node_modules/typeorm/decorator/options/virtualcolumnoptions.d.ts","./node_modules/typeorm/decorator/columns/virtualcolumn.d.ts","./node_modules/typeorm/decorator/options/viewcolumnoptions.d.ts","./node_modules/typeorm/decorator/columns/viewcolumn.d.ts","./node_modules/typeorm/decorator/columns/objectidcolumn.d.ts","./node_modules/typeorm/decorator/listeners/afterinsert.d.ts","./node_modules/typeorm/decorator/listeners/afterload.d.ts","./node_modules/typeorm/decorator/listeners/afterremove.d.ts","./node_modules/typeorm/decorator/listeners/aftersoftremove.d.ts","./node_modules/typeorm/decorator/listeners/afterrecover.d.ts","./node_modules/typeorm/decorator/listeners/afterupdate.d.ts","./node_modules/typeorm/decorator/listeners/beforeinsert.d.ts","./node_modules/typeorm/decorator/listeners/beforeremove.d.ts","./node_modules/typeorm/decorator/listeners/beforesoftremove.d.ts","./node_modules/typeorm/decorator/listeners/beforerecover.d.ts","./node_modules/typeorm/decorator/listeners/beforeupdate.d.ts","./node_modules/typeorm/decorator/listeners/eventsubscriber.d.ts","./node_modules/typeorm/decorator/options/indexoptions.d.ts","./node_modules/typeorm/decorator/options/entityoptions.d.ts","./node_modules/typeorm/decorator/relations/joincolumn.d.ts","./node_modules/typeorm/decorator/relations/jointable.d.ts","./node_modules/typeorm/decorator/relations/manytomany.d.ts","./node_modules/typeorm/decorator/relations/manytoone.d.ts","./node_modules/typeorm/decorator/relations/onetomany.d.ts","./node_modules/typeorm/decorator/relations/onetoone.d.ts","./node_modules/typeorm/decorator/relations/relationcount.d.ts","./node_modules/typeorm/decorator/relations/relationid.d.ts","./node_modules/typeorm/decorator/entity/entity.d.ts","./node_modules/typeorm/decorator/entity/childentity.d.ts","./node_modules/typeorm/decorator/entity/tableinheritance.d.ts","./node_modules/typeorm/decorator/options/viewentityoptions.d.ts","./node_modules/typeorm/decorator/entity-view/viewentity.d.ts","./node_modules/typeorm/decorator/tree/treelevelcolumn.d.ts","./node_modules/typeorm/decorator/tree/treeparent.d.ts","./node_modules/typeorm/decorator/tree/treechildren.d.ts","./node_modules/typeorm/decorator/tree/tree.d.ts","./node_modules/typeorm/decorator/index.d.ts","./node_modules/typeorm/decorator/options/uniqueoptions.d.ts","./node_modules/typeorm/decorator/unique.d.ts","./node_modules/typeorm/decorator/check.d.ts","./node_modules/typeorm/decorator/exclusion.d.ts","./node_modules/typeorm/decorator/generated.d.ts","./node_modules/typeorm/decorator/entityrepository.d.ts","./node_modules/typeorm/find-options/operator/and.d.ts","./node_modules/typeorm/find-options/operator/any.d.ts","./node_modules/typeorm/find-options/operator/arraycontainedby.d.ts","./node_modules/typeorm/find-options/operator/arraycontains.d.ts","./node_modules/typeorm/find-options/operator/arrayoverlap.d.ts","./node_modules/typeorm/find-options/operator/between.d.ts","./node_modules/typeorm/find-options/operator/equal.d.ts","./node_modules/typeorm/find-options/operator/in.d.ts","./node_modules/typeorm/find-options/operator/isnull.d.ts","./node_modules/typeorm/find-options/operator/lessthan.d.ts","./node_modules/typeorm/find-options/operator/lessthanorequal.d.ts","./node_modules/typeorm/find-options/operator/ilike.d.ts","./node_modules/typeorm/find-options/operator/like.d.ts","./node_modules/typeorm/find-options/operator/morethan.d.ts","./node_modules/typeorm/find-options/operator/morethanorequal.d.ts","./node_modules/typeorm/find-options/operator/not.d.ts","./node_modules/typeorm/find-options/operator/raw.d.ts","./node_modules/typeorm/find-options/operator/jsoncontains.d.ts","./node_modules/typeorm/find-options/findoptionsutils.d.ts","./node_modules/typeorm/logger/abstractlogger.d.ts","./node_modules/typeorm/logger/advancedconsolelogger.d.ts","./node_modules/typeorm/logger/simpleconsolelogger.d.ts","./node_modules/typeorm/logger/filelogger.d.ts","./node_modules/typeorm/repository/abstractrepository.d.ts","./node_modules/typeorm/data-source/index.d.ts","./node_modules/typeorm/repository/baseentity.d.ts","./node_modules/typeorm/driver/sqlserver/mssqlparameter.d.ts","./node_modules/typeorm/connection/connectionoptionsreader.d.ts","./node_modules/typeorm/connection/connectionoptions.d.ts","./node_modules/typeorm/connection/connection.d.ts","./node_modules/typeorm/migration/migrationexecutor.d.ts","./node_modules/typeorm/naming-strategy/defaultnamingstrategy.d.ts","./node_modules/typeorm/naming-strategy/legacyoraclenamingstrategy.d.ts","./node_modules/typeorm/entity-schema/entityschemaembeddedcolumnoptions.d.ts","./node_modules/typeorm/schema-builder/rdbmsschemabuilder.d.ts","./node_modules/typeorm/util/instancechecker.d.ts","./node_modules/typeorm/repository/findtreesoptions.d.ts","./node_modules/typeorm/util/treerepositoryutils.d.ts","./node_modules/typeorm/index.d.ts","./test/container/postgres/postgres-container.ts","./test/container/rabbitmq/rabbitmq-container.ts","./types/exeptions/http-client.exception.ts","./types/pagination/paged-result.ts","./utils/encryption.ts","./utils/serialization.ts","./utils/validation.ts","./node_modules/@types/accepts/index.d.ts","./node_modules/@types/aws-lambda/common/api-gateway.d.ts","./node_modules/@types/aws-lambda/common/cloudfront.d.ts","./node_modules/@types/aws-lambda/handler.d.ts","./node_modules/@types/aws-lambda/trigger/alb.d.ts","./node_modules/@types/aws-lambda/trigger/api-gateway-proxy.d.ts","./node_modules/@types/aws-lambda/trigger/api-gateway-authorizer.d.ts","./node_modules/@types/aws-lambda/trigger/appsync-resolver.d.ts","./node_modules/@types/aws-lambda/trigger/autoscaling.d.ts","./node_modules/@types/aws-lambda/trigger/cloudformation-custom-resource.d.ts","./node_modules/@types/aws-lambda/trigger/cdk-custom-resource.d.ts","./node_modules/@types/aws-lambda/trigger/cloudfront-request.d.ts","./node_modules/@types/aws-lambda/trigger/cloudfront-response.d.ts","./node_modules/@types/aws-lambda/trigger/eventbridge.d.ts","./node_modules/@types/aws-lambda/trigger/cloudwatch-events.d.ts","./node_modules/@types/aws-lambda/trigger/cloudwatch-logs.d.ts","./node_modules/@types/aws-lambda/trigger/codebuild-cloudwatch-state.d.ts","./node_modules/@types/aws-lambda/trigger/codecommit.d.ts","./node_modules/@types/aws-lambda/trigger/codepipeline.d.ts","./node_modules/@types/aws-lambda/trigger/codepipeline-cloudwatch-action.d.ts","./node_modules/@types/aws-lambda/trigger/codepipeline-cloudwatch-pipeline.d.ts","./node_modules/@types/aws-lambda/trigger/codepipeline-cloudwatch-stage.d.ts","./node_modules/@types/aws-lambda/trigger/codepipeline-cloudwatch.d.ts","./node_modules/@types/aws-lambda/trigger/cognito-user-pool-trigger/_common.d.ts","./node_modules/@types/aws-lambda/trigger/cognito-user-pool-trigger/create-auth-challenge.d.ts","./node_modules/@types/aws-lambda/trigger/cognito-user-pool-trigger/custom-email-sender.d.ts","./node_modules/@types/aws-lambda/trigger/cognito-user-pool-trigger/custom-message.d.ts","./node_modules/@types/aws-lambda/trigger/cognito-user-pool-trigger/custom-sms-sender.d.ts","./node_modules/@types/aws-lambda/trigger/cognito-user-pool-trigger/define-auth-challenge.d.ts","./node_modules/@types/aws-lambda/trigger/cognito-user-pool-trigger/post-authentication.d.ts","./node_modules/@types/aws-lambda/trigger/cognito-user-pool-trigger/post-confirmation.d.ts","./node_modules/@types/aws-lambda/trigger/cognito-user-pool-trigger/pre-authentication.d.ts","./node_modules/@types/aws-lambda/trigger/cognito-user-pool-trigger/pre-signup.d.ts","./node_modules/@types/aws-lambda/trigger/cognito-user-pool-trigger/pre-token-generation.d.ts","./node_modules/@types/aws-lambda/trigger/cognito-user-pool-trigger/user-migration.d.ts","./node_modules/@types/aws-lambda/trigger/cognito-user-pool-trigger/verify-auth-challenge-response.d.ts","./node_modules/@types/aws-lambda/trigger/cognito-user-pool-trigger/index.d.ts","./node_modules/@types/aws-lambda/trigger/connect-contact-flow.d.ts","./node_modules/@types/aws-lambda/trigger/dynamodb-stream.d.ts","./node_modules/@types/aws-lambda/trigger/iot.d.ts","./node_modules/@types/aws-lambda/trigger/kinesis-firehose-transformation.d.ts","./node_modules/@types/aws-lambda/trigger/kinesis-stream.d.ts","./node_modules/@types/aws-lambda/trigger/lex.d.ts","./node_modules/@types/aws-lambda/trigger/lex-v2.d.ts","./node_modules/@types/aws-lambda/trigger/amplify-resolver.d.ts","./node_modules/@types/aws-lambda/trigger/msk.d.ts","./node_modules/@types/aws-lambda/trigger/s3.d.ts","./node_modules/@types/aws-lambda/trigger/s3-batch.d.ts","./node_modules/@types/aws-lambda/trigger/s3-event-notification.d.ts","./node_modules/@types/aws-lambda/trigger/secretsmanager.d.ts","./node_modules/@types/aws-lambda/trigger/self-managed-kafka.d.ts","./node_modules/@types/aws-lambda/trigger/ses.d.ts","./node_modules/@types/aws-lambda/trigger/sns.d.ts","./node_modules/@types/aws-lambda/trigger/sqs.d.ts","./node_modules/@types/aws-lambda/index.d.ts","./node_modules/@types/bunyan/index.d.ts","./node_modules/@types/content-disposition/index.d.ts","./node_modules/@types/keygrip/index.d.ts","./node_modules/@types/cookies/index.d.ts","./node_modules/@types/eslint/helpers.d.ts","./node_modules/@types/estree/index.d.ts","./node_modules/@types/json-schema/index.d.ts","./node_modules/@types/eslint/index.d.ts","./node_modules/@types/eslint-scope/index.d.ts","./node_modules/@types/hapi__catbox/index.d.ts","./node_modules/@hapi/boom/lib/index.d.ts","./node_modules/@types/hapi__shot/index.d.ts","./node_modules/@types/mime-db/index.d.ts","./node_modules/@types/hapi__mimos/index.d.ts","./node_modules/@hapi/iron/lib/index.d.ts","./node_modules/@hapi/podium/lib/index.d.ts","./node_modules/@types/hapi__hapi/index.d.ts","./node_modules/@types/http-assert/index.d.ts","./node_modules/@types/ioredis4/index.d.ts","./node_modules/@types/json5/index.d.ts","./node_modules/@types/koa-compose/index.d.ts","./node_modules/@types/koa/index.d.ts","./node_modules/@types/koa__router/index.d.ts","./node_modules/@types/memcached/index.d.ts","./node_modules/@types/mysql/index.d.ts","./node_modules/@types/passport-local/index.d.ts","./node_modules/pg-types/index.d.ts","./node_modules/pg-protocol/dist/messages.d.ts","./node_modules/pg-protocol/dist/serializer.d.ts","./node_modules/pg-protocol/dist/parser.d.ts","./node_modules/pg-protocol/dist/index.d.ts","./node_modules/@types/pg/index.d.ts","./node_modules/@types/pg-pool/index.d.ts","./node_modules/@types/semver/classes/semver.d.ts","./node_modules/@types/semver/functions/parse.d.ts","./node_modules/@types/semver/functions/valid.d.ts","./node_modules/@types/semver/functions/clean.d.ts","./node_modules/@types/semver/functions/inc.d.ts","./node_modules/@types/semver/functions/diff.d.ts","./node_modules/@types/semver/functions/major.d.ts","./node_modules/@types/semver/functions/minor.d.ts","./node_modules/@types/semver/functions/patch.d.ts","./node_modules/@types/semver/functions/prerelease.d.ts","./node_modules/@types/semver/functions/compare.d.ts","./node_modules/@types/semver/functions/rcompare.d.ts","./node_modules/@types/semver/functions/compare-loose.d.ts","./node_modules/@types/semver/functions/compare-build.d.ts","./node_modules/@types/semver/functions/sort.d.ts","./node_modules/@types/semver/functions/rsort.d.ts","./node_modules/@types/semver/functions/gt.d.ts","./node_modules/@types/semver/functions/lt.d.ts","./node_modules/@types/semver/functions/eq.d.ts","./node_modules/@types/semver/functions/neq.d.ts","./node_modules/@types/semver/functions/gte.d.ts","./node_modules/@types/semver/functions/lte.d.ts","./node_modules/@types/semver/functions/cmp.d.ts","./node_modules/@types/semver/functions/coerce.d.ts","./node_modules/@types/semver/classes/comparator.d.ts","./node_modules/@types/semver/classes/range.d.ts","./node_modules/@types/semver/functions/satisfies.d.ts","./node_modules/@types/semver/ranges/max-satisfying.d.ts","./node_modules/@types/semver/ranges/min-satisfying.d.ts","./node_modules/@types/semver/ranges/to-comparators.d.ts","./node_modules/@types/semver/ranges/min-version.d.ts","./node_modules/@types/semver/ranges/valid.d.ts","./node_modules/@types/semver/ranges/outside.d.ts","./node_modules/@types/semver/ranges/gtr.d.ts","./node_modules/@types/semver/ranges/ltr.d.ts","./node_modules/@types/semver/ranges/intersects.d.ts","./node_modules/@types/semver/ranges/simplify.d.ts","./node_modules/@types/semver/ranges/subset.d.ts","./node_modules/@types/semver/internals/identifiers.d.ts","./node_modules/@types/semver/index.d.ts","./node_modules/@types/ssh2-streams/index.d.ts","./node_modules/@types/tedious/index.d.ts","./node_modules/@types/validator/lib/isboolean.d.ts","./node_modules/@types/validator/lib/isemail.d.ts","./node_modules/@types/validator/lib/isfqdn.d.ts","./node_modules/@types/validator/lib/isiban.d.ts","./node_modules/@types/validator/lib/isiso31661alpha2.d.ts","./node_modules/@types/validator/lib/isiso4217.d.ts","./node_modules/@types/validator/lib/isiso6391.d.ts","./node_modules/@types/validator/lib/istaxid.d.ts","./node_modules/@types/validator/lib/isurl.d.ts","./node_modules/@types/validator/index.d.ts","./node_modules/@opentelemetry/instrumentation-express/node_modules/@types/express/index.d.ts","./node_modules/@opentelemetry/sdk-node/node_modules/@opentelemetry/instrumentation/build/src/types.d.ts","./node_modules/@opentelemetry/sdk-node/node_modules/@opentelemetry/instrumentation/build/src/platform/index.d.ts","./node_modules/@opentelemetry/sdk-node/node_modules/@opentelemetry/instrumentation/build/src/types_internal.d.ts","./node_modules/@opentelemetry/sdk-node/node_modules/@opentelemetry/instrumentation/build/src/autoloader.d.ts","./node_modules/@opentelemetry/sdk-node/node_modules/@opentelemetry/instrumentation/build/src/instrumentationnodemoduledefinition.d.ts","./node_modules/@opentelemetry/sdk-node/node_modules/@opentelemetry/instrumentation/build/src/instrumentationnodemodulefile.d.ts","./node_modules/@opentelemetry/sdk-node/node_modules/@opentelemetry/instrumentation/build/src/utils.d.ts","./node_modules/@opentelemetry/sdk-trace-base/node_modules/@opentelemetry/core/build/src/index.d.ts"],"fileInfos":[{"version":"f33e5332b24c3773e930e212cbb8b6867c8ba3ec4492064ea78e55a524d57450","affectsGlobalScope":true},"45b7ab580deca34ae9729e97c13cfd999df04416a79116c3bfb483804f85ded4","26f2f787e82c4222710f3b676b4d83eb5ad0a72fa7b746f03449e7a026ce5073","9a68c0c07ae2fa71b44384a839b7b8d81662a236d4b9ac30916718f7510b1b2d","5e1c4c362065a6b95ff952c0eab010f04dcd2c3494e813b493ecfd4fcb9fc0d8","68d73b4a11549f9c0b7d352d10e91e5dca8faa3322bfb77b661839c42b1ddec7","5efce4fc3c29ea84e8928f97adec086e3dc876365e0982cc8479a07954a3efd4",{"version":"21e41a76098aa7a191028256e52a726baafd45a925ea5cf0222eb430c96c1d83","affectsGlobalScope":true},{"version":"35299ae4a62086698444a5aaee27fc7aa377c68cbb90b441c9ace246ffd05c97","affectsGlobalScope":true},{"version":"80e18897e5884b6723488d4f5652167e7bb5024f946743134ecc4aa4ee731f89","affectsGlobalScope":true},{"version":"cd034f499c6cdca722b60c04b5b1b78e058487a7085a8e0d6fb50809947ee573","affectsGlobalScope":true},{"version":"138fb588d26538783b78d1e3b2c2cc12d55840b97bf5e08bca7f7a174fbe2f17","affectsGlobalScope":true},{"version":"dc2df20b1bcdc8c2d34af4926e2c3ab15ffe1160a63e58b7e09833f616efff44","affectsGlobalScope":true},{"version":"4443e68b35f3332f753eacc66a04ac1d2053b8b035a0e0ac1d455392b5e243b3","affectsGlobalScope":true},{"version":"bc47685641087c015972a3f072480889f0d6c65515f12bd85222f49a98952ed7","affectsGlobalScope":true},{"version":"0dc1e7ceda9b8b9b455c3a2d67b0412feab00bd2f66656cd8850e8831b08b537","affectsGlobalScope":true},{"version":"ce691fb9e5c64efb9547083e4a34091bcbe5bdb41027e310ebba8f7d96a98671","affectsGlobalScope":true},{"version":"8d697a2a929a5fcb38b7a65594020fcef05ec1630804a33748829c5ff53640d0","affectsGlobalScope":true},{"version":"4ff2a353abf8a80ee399af572debb8faab2d33ad38c4b4474cff7f26e7653b8d","affectsGlobalScope":true},{"version":"93495ff27b8746f55d19fcbcdbaccc99fd95f19d057aed1bd2c0cafe1335fbf0","affectsGlobalScope":true},{"version":"6fc23bb8c3965964be8c597310a2878b53a0306edb71d4b5a4dfe760186bcc01","affectsGlobalScope":true},{"version":"38f0219c9e23c915ef9790ab1d680440d95419ad264816fa15009a8851e79119","affectsGlobalScope":true},{"version":"bb42a7797d996412ecdc5b2787720de477103a0b2e53058569069a0e2bae6c7e","affectsGlobalScope":true},{"version":"4738f2420687fd85629c9efb470793bb753709c2379e5f85bc1815d875ceadcd","affectsGlobalScope":true},{"version":"2f11ff796926e0832f9ae148008138ad583bd181899ab7dd768a2666700b1893","affectsGlobalScope":true},{"version":"4de680d5bb41c17f7f68e0419412ca23c98d5749dcaaea1896172f06435891fc","affectsGlobalScope":true},{"version":"9fc46429fbe091ac5ad2608c657201eb68b6f1b8341bd6d670047d32ed0a88fa","affectsGlobalScope":true},{"version":"61c37c1de663cf4171e1192466e52c7a382afa58da01b1dc75058f032ddf0839","affectsGlobalScope":true},{"version":"b541a838a13f9234aba650a825393ffc2292dc0fc87681a5d81ef0c96d281e7a","affectsGlobalScope":true},{"version":"e0275cd0e42990dc3a16f0b7c8bca3efe87f1c8ad404f80c6db1c7c0b828c59f","affectsGlobalScope":true},{"version":"811ec78f7fefcabbda4bfa93b3eb67d9ae166ef95f9bff989d964061cbf81a0c","affectsGlobalScope":true},{"version":"717937616a17072082152a2ef351cb51f98802fb4b2fdabd32399843875974ca","affectsGlobalScope":true},{"version":"d7e7d9b7b50e5f22c915b525acc5a49a7a6584cf8f62d0569e557c5cfc4b2ac2","affectsGlobalScope":true},{"version":"71c37f4c9543f31dfced6c7840e068c5a5aacb7b89111a4364b1d5276b852557","affectsGlobalScope":true},{"version":"576711e016cf4f1804676043e6a0a5414252560eb57de9faceee34d79798c850","affectsGlobalScope":true},{"version":"89c1b1281ba7b8a96efc676b11b264de7a8374c5ea1e6617f11880a13fc56dc6","affectsGlobalScope":true},{"version":"49ed889be54031e1044af0ad2c603d627b8bda8b50c1a68435fe85583901d072","affectsGlobalScope":true},{"version":"e93d098658ce4f0c8a0779e6cab91d0259efb88a318137f686ad76f8410ca270","affectsGlobalScope":true},{"version":"063600664504610fe3e99b717a1223f8b1900087fab0b4cad1496a114744f8df","affectsGlobalScope":true},{"version":"934019d7e3c81950f9a8426d093458b65d5aff2c7c1511233c0fd5b941e608ab","affectsGlobalScope":true},{"version":"bf14a426dbbf1022d11bd08d6b8e709a2e9d246f0c6c1032f3b2edb9a902adbe","affectsGlobalScope":true},{"version":"ec0104fee478075cb5171e5f4e3f23add8e02d845ae0165bfa3f1099241fa2aa","affectsGlobalScope":true},{"version":"2b72d528b2e2fe3c57889ca7baef5e13a56c957b946906d03767c642f386bbc3","affectsGlobalScope":true},{"version":"acae90d417bee324b1372813b5a00829d31c7eb670d299cd7f8f9a648ac05688","affectsGlobalScope":true},{"version":"368af93f74c9c932edd84c58883e736c9e3d53cec1fe24c0b0ff451f529ceab1","affectsGlobalScope":true},{"version":"13f6e6380c78e15e140243dc4be2fa546c287c6d61f4729bc2dd7cf449605471","affectsGlobalScope":true},{"version":"33358442698bb565130f52ba79bfd3d4d484ac85fe33f3cb1759c54d18201393","affectsGlobalScope":true},{"version":"782dec38049b92d4e85c1585fbea5474a219c6984a35b004963b00beb1aab538","affectsGlobalScope":true},"1d242d5c24cf285c88bc4fb93c5ff903de8319064e282986edeb6247ba028d5e","efc7d584a33fe3422847783d228f315c4cd1afe74bd7cf8e3f0e4c1125129fef","7394959e5a741b185456e1ef5d64599c36c60a323207450991e7a42e08911419","5929864ce17fba74232584d90cb721a89b7ad277220627cc97054ba15a98ea8f","7180c03fd3cb6e22f911ce9ba0f8a7008b1a6ddbe88ccf16a9c8140ef9ac1686","25c8056edf4314820382a5fdb4bb7816999acdcb929c8f75e3f39473b87e85bc","54cb85a47d760da1c13c00add10d26b5118280d44d58e6908d8e89abbd9d7725","3e4825171442666d31c845aeb47fcd34b62e14041bb353ae2b874285d78482aa","c6fd2c5a395f2432786c9cb8deb870b9b0e8ff7e22c029954fabdd692bff6195","a967bfe3ad4e62243eb604bf956101e4c740f5921277c60debaf325c1320bf88","e9775e97ac4877aebf963a0289c81abe76d1ec9a2a7778dbe637e5151f25c5f3","471e1da5a78350bc55ef8cef24eb3aca6174143c281b8b214ca2beda51f5e04a","cadc8aced301244057c4e7e73fbcae534b0f5b12a37b150d80e5a45aa4bebcbd","385aab901643aa54e1c36f5ef3107913b10d1b5bb8cbcd933d4263b80a0d7f20","9670d44354bab9d9982eca21945686b5c24a3f893db73c0dae0fd74217a4c219","db3435f3525cd785bf21ec6769bf8da7e8a776be1a99e2e7efb5f244a2ef5fee","c3b170c45fc031db31f782e612adf7314b167e60439d304b49e704010e7bafe5","40383ebef22b943d503c6ce2cb2e060282936b952a01bea5f9f493d5fb487cc7","4893a895ea92c85345017a04ed427cbd6a1710453338df26881a6019432febdd","3a84b7cb891141824bd00ef8a50b6a44596aded4075da937f180c90e362fe5f6","13f6f39e12b1518c6650bbb220c8985999020fe0f21d818e28f512b7771d00f9","9b5369969f6e7175740bf51223112ff209f94ba43ecd3bb09eefff9fd675624a","4fe9e626e7164748e8769bbf74b538e09607f07ed17c2f20af8d680ee49fc1da","24515859bc0b836719105bb6cc3d68255042a9f02a6022b3187948b204946bd2","33203609eba548914dc83ddf6cadbc0bcb6e8ef89f6d648ca0908ae887f9fcc5","0db18c6e78ea846316c012478888f33c11ffadab9efd1cc8bcc12daded7a60b6","89167d696a849fce5ca508032aabfe901c0868f833a8625d5a9c6e861ef935d2","e53a3c2a9f624d90f24bf4588aacd223e7bec1b9d0d479b68d2f4a9e6011147f","339dc5265ee5ed92e536a93a04c4ebbc2128f45eeec6ed29f379e0085283542c","9f0a92164925aa37d4a5d9dd3e0134cff8177208dba55fd2310cd74beea40ee2","8bfdb79bf1a9d435ec48d9372dc93291161f152c0865b81fc0b2694aedb4578d","2e85db9e6fd73cfa3d7f28e0ab6b55417ea18931423bd47b409a96e4a169e8e6","c46e079fe54c76f95c67fb89081b3e399da2c7d109e7dca8e4b58d83e332e605","d32275be3546f252e3ad33976caf8c5e842c09cb87d468cb40d5f4cf092d1acc","4a0c3504813a3289f7fb1115db13967c8e004aa8e4f8a9021b95285502221bd1",{"version":"cc5e65fb1729463665074b9d7163e78a4225b7af7f3a6b3c74492f415166612f","affectsGlobalScope":true},"cce1f5f86974c1e916ec4a8cab6eec9aa8e31e8148845bf07fbaa8e1d97b1a2c",{"version":"185282b122cbca820c297a02a57b89cf5967ab43e220e3e174d872d3f9a94d2c","affectsGlobalScope":true},"16d74fe4d8e183344d3beb15d48b123c5980ff32ff0cc8c3b96614ddcdf9b239","7b43160a49cf2c6082da0465876c4a0b164e160b81187caeb0a6ca7a281e85ba",{"version":"41fb2a1c108fbf46609ce5a451b7ec78eb9b5ada95fd5b94643e4b26397de0b3","affectsGlobalScope":true},"a40826e8476694e90da94aa008283a7de50d1dafd37beada623863f1901cb7fb","e8968b394e4365588f8f89cfff86435258cf10062585c1d2224627ab92acda22","285e512c7a0db217a0599e18c462d565fa35be4a5153dd7b80bee88c83e83ddf","b5b719a47968cd61a6f83f437236bb6fe22a39223b6620da81ef89f5d7a78fb7","8806ae97308ef26363bd7ec8071bca4d07fb575f905ee3d8a91aff226df6d618","af5bf1db6f1804fb0069039ae77a05d60133c77a2158d9635ea27b6bb2828a8f","b7fe70be794e13d1b7940e318b8770cd1fb3eced7707805318a2e3aaac2c3e9e",{"version":"2c71199d1fc83bf17636ad5bf63a945633406b7b94887612bba4ef027c662b3e","affectsGlobalScope":true},{"version":"7ae9dc7dbb58cd843065639707815df85c044babaa0947116f97bdb824d07204","affectsGlobalScope":true},"7aae1df2053572c2cfc2089a77847aadbb38eedbaa837a846c6a49fb37c6e5bd","313a0b063f5188037db113509de1b934a0e286f14e9479af24fada241435e707","1f758340b027b18ae8773ac3d33a60648a2af49eaae9e4fde18d0a0dd608642c","87ef1a23caa071b07157c72077fa42b86d30568f9dc9e31eed24d5d14fc30ba8","396a8939b5e177542bdf9b5262b4eee85d29851b2d57681fa9d7eae30e225830","21773f5ac69ddf5a05636ba1f50b5239f4f2d27e4420db147fc2f76a5ae598ac",{"version":"dea4c00820d4fac5e530d4842aed2fb20d6744d75a674b95502cbd433f88bcb0","affectsGlobalScope":true},"a5fe4cc622c3bf8e09ababde5f4096ceac53163eefcd95e9cd53f062ff9bb67a","45b1053e691c5af9bfe85060a3e1542835f8d84a7e6e2e77ca305251eda0cb3c","0f05c06ff6196958d76b865ae17245b52d8fe01773626ac3c43214a2458ea7b7",{"version":"0d832a0650a74aafc276cb3f7bb26bde2e2270a6f87e6c871a64122e9203079b","affectsGlobalScope":true},{"version":"c6f3869f12bb5c3bb8ecd0b050ea20342b89b944eae18d313cde6b0ccc0925d7","affectsGlobalScope":true},"8abd0566d2854c4bd1c5e48e05df5c74927187f1541e6770001d9637ac41542e","d742ed2db6d5425b3b6ac5fb1f2e4b1ed2ae74fbeee8d0030d852121a4b05d2f","d8dba11dc34d50cb4202de5effa9a1b296d7a2f4a029eec871f894bddfb6430d","8b71dd18e7e63b6f991b511a201fad7c3bf8d1e0dd98acb5e3d844f335a73634","01d8e1419c84affad359cc240b2b551fb9812b450b4d3d456b64cda8102d4f60","8221b00f271cf7f535a8eeec03b0f80f0929c7a16116e2d2df089b41066de69b","269929a24b2816343a178008ac9ae9248304d92a8ba8e233055e0ed6dbe6ef71","93452d394fdd1dc551ec62f5042366f011a00d342d36d50793b3529bfc9bd633","f8c87b19eae111f8720b0345ab301af8d81add39621b63614dfc2d15fd6f140a","831c22d257717bf2cbb03afe9c4bcffc5ccb8a2074344d4238bf16d3a857bb12",{"version":"2225100373ca3d63bcc7f206e1177152d2e2161285a0bd83c8374db1503a0d1f","affectsGlobalScope":true},{"version":"7052b7b0c3829df3b4985bab2fd74531074b4835d5a7b263b75c82f0916ad62f","affectsGlobalScope":true},"aa34c3aa493d1c699601027c441b9664547c3024f9dbab1639df7701d63d18fa","eefcdf86cefff36e5d87de36a3638ab5f7d16c2b68932be4a72c14bb924e43c1","7c651f8dce91a927ab62925e73f190763574c46098f2b11fb8ddc1b147a6709a","7440ab60f4cb031812940cc38166b8bb6fbf2540cfe599f87c41c08011f0c1df",{"version":"4d0405568cf6e0ff36a4861c4a77e641366feaefa751600b0a4d12a5e8f730a8","affectsGlobalScope":true},{"version":"f5b5dc128973498b75f52b1b8c2d5f8629869104899733ae485100c2309b4c12","affectsGlobalScope":true},"e393915d3dc385e69c0e2390739c87b2d296a610662eb0b1cb85224e55992250","79bad8541d5779c85e82a9fb119c1fe06af77a71cc40f869d62ad379473d4b75","4a34b074b11c3597fb2ff890bc8f1484375b3b80793ab01f974534808d5777c7",{"version":"629d20681ca284d9e38c0a019f647108f5fe02f9c59ac164d56f5694fc3faf4d","affectsGlobalScope":true},"e7dbf5716d76846c7522e910896c5747b6df1abd538fee8f5291bdc843461795",{"version":"ab9b9a36e5284fd8d3bf2f7d5fcbc60052f25f27e4d20954782099282c60d23e","affectsGlobalScope":true},"b510d0a18e3db42ac9765d26711083ec1e8b4e21caaca6dc4d25ae6e8623f447","082fd595b601cead92b1aada1b38b23174ef0eee4b853fa37765f71e5d709236","bd7b73ef8ed8db3f3e753776d89d5965d4bfad0cccbd92924a6477411f9489e4",{"version":"71854ab6cac7bfc9453e665da6beb7f2478a3c6aa38ff9acc56c6a9e2956222c","signature":"d66d96771b0e2e8878677649c4cc329cba7b6aeca7f4b30209f947438bfa7008"},{"version":"8d6d51a5118d000ed3bfe6e1dd1335bebfff3fef23cd2af2f84a24d30f90cc90","affectsGlobalScope":true},"6d8dedbec739bc79642c1e96e9bfc0b83b25b104a0486aebf016fc7b85b39f48","e89535c3ec439608bcd0f68af555d0e5ddf121c54abe69343549718bd7506b9c","622a984b60c294ffb2f9152cf1d4d12e91d2b733d820eec949cf54d63a3c1025","81aae92abdeaccd9c1723cef39232c90c1aed9d9cf199e6e2a523b7d8e058a11","a63a6c6806a1e519688ef7bd8ca57be912fc0764485119dbd923021eb4e79665","75b57b109d774acca1e151df21cf5cb54c7a1df33a273f0457b9aee4ebd36fb9","ecf5cb089ea438f2545e04b6c52828c68d0b0f4bfaa661986faf36da273e9892","95444fb6292d5e2f7050d7021383b719c0252bf5f88854973977db9e3e3d8006","241bd4add06f06f0699dcd58f3b334718d85e3045d9e9d4fa556f11f4d1569c1","06540a9f3f2f88375ada0b89712de1c4310f7398d821c4c10ab5c6477dafb4bc",{"version":"de2d3120ed0989dbc776de71e6c0e8a6b4bf1935760cf468ff9d0e9986ef4c09","affectsGlobalScope":true},"b8bff8a60af0173430b18d9c3e5c443eaa3c515617210c0c7b3d2e1743c19ecb","97bdf234f5db52085d99c6842db560bca133f8a0413ff76bf830f5f38f088ce3","a76ebdf2579e68e4cfe618269c47e5a12a4e045c2805ed7f7ab37af8daa6b091","b493ff8a5175cbbb4e6e8bcfa9506c08f5a7318b2278365cfca3b397c9710ebc","e59d36b7b6e8ba2dd36d032a5f5c279d2460968c8b4e691ca384f118fb09b52a","e96885c0684c9042ec72a9a43ef977f6b4b4a2728f4b9e737edcbaa0c74e5bf6","303ee143a869e8f605e7b1d12be6c7269d4cab90d230caba792495be595d4f56","89e061244da3fc21b7330f4bd32f47c1813dd4d7f1dc3d0883d88943f035b993","e46558c2e04d06207b080138678020448e7fc201f3d69c2601b0d1456105f29a","71549375db52b1163411dba383b5f4618bdf35dc57fa327a1c7d135cf9bf67d1","7e6b2d61d6215a4e82ea75bc31a80ebb8ad0c2b37a60c10c70dd671e8d9d6d5d","78bea05df2896083cca28ed75784dde46d4b194984e8fc559123b56873580a23","5dd04ced37b7ea09f29d277db11f160df7fd73ba8b9dba86cb25552e0653a637","f74b81712e06605677ae1f061600201c425430151f95b5ef4d04387ad7617e6a","9a72847fcf4ac937e352d40810f7b7aec7422d9178451148296cf1aa19467620","3ae18f60e0b96fa1e025059b7d25b3247ba4dcb5f4372f6d6e67ce2adac74eac","2b9260f44a2e071450ae82c110f5dc8f330c9e5c3e85567ed97248330f2bf639","4f196e13684186bda6f5115fc4677a87cf84a0c9c4fc17b8f51e0984f3697b6d","61419f2c5822b28c1ea483258437c1faab87d00c6f84481aa22afb3380d8e9a4","64479aee03812264e421c0bf5104a953ca7b02740ba80090aead1330d0effe91","a5eb4835ab561c140ffc4634bb039387d5d0cceebb86918f1696c7ac156d26fd","c5570e504be103e255d80c60b56c367bf45d502ca52ee35c55dec882f6563b5c","4252b852dd791305da39f6e1242694c2e560d5e46f9bb26e2aca77252057c026","0520b5093712c10c6ef23b5fea2f833bf5481771977112500045e5ea7e8e2b69","5c3cf26654cf762ac4d7fd7b83f09acfe08eef88d2d6983b9a5a423cb4004ca3","e60fa19cf7911c1623b891155d7eb6b7e844e9afdf5738e3b46f3b687730a2bd","b1fd72ff2bb0ba91bb588f3e5329f8fc884eb859794f1c4657a2bfa122ae54d0","6cf42a4f3cfec648545925d43afaa8bb364ac10a839ffed88249da109361b275","ba13c7d46a560f3d4df8ffb1110e2bbec5801449af3b1240a718514b5576156e","6df52b70d7f7702202f672541a5f4a424d478ee5be51a9d37b8ccbe1dbf3c0f2","0ca7f997e9a4d8985e842b7c882e521b6f63233c4086e9fe79dd7a9dc4742b5e","91046b5c6b55d3b194c81fd4df52f687736fad3095e9d103ead92bb64dc160ee","db5704fdad56c74dfc5941283c1182ed471bd17598209d3ac4a49faa72e43cfc","758e8e89559b02b81bc0f8fd395b17ad5aff75490c862cbe369bb1a3d1577c40","2ee64342c077b1868f1834c063f575063051edd6e2964257d34aad032d6b657c","6f6b4b3d670b6a5f0e24ea001c1b3d36453c539195e875687950a178f1730fa7","05c4e2a992bb83066a3a648bad1c310cecd4d0628d7e19545bb107ac9596103a","b48b83a86dd9cfe36f8776b3ff52fcd45b0e043c0538dc4a4b149ba45fe367b9","792de5c062444bd2ee0413fb766e57e03cce7cdaebbfc52fc0c7c8e95069c96b","a79e3e81094c7a04a885bad9b049c519aace53300fb8a0fe4f26727cb5a746ce","dd6c3362aaaec60be028b4ba292806da8e7020eef7255c7414ce4a5c3a7138ef","8a4e89564d8ea66ad87ee3762e07540f9f0656a62043c910d819b4746fc429c5","b9011d99942889a0f95e120d06b698c628b0b6fdc3e6b7ecb459b97ed7d5bcc6","4d639cbbcc2f8f9ce6d55d5d503830d6c2556251df332dc5255d75af53c8a0e7","cdb48277f600ab5f429ecf1c5ea046683bc6b9f73f3deab9a100adac4b34969c","75be84956a29040a1afbe864c0a7a369dfdb739380072484eff153905ef867ee","b06b4adc2ae03331a92abd1b19af8eb91ec2bf8541747ee355887a167d53145e","3114b315cd0687aad8b57cff36f9c8c51f5b1bc6254f1b1e8446ae583d8e2474","0d417c15c5c635384d5f1819cc253a540fe786cc3fda32f6a2ae266671506a21","af733cb878419f3012f0d4df36f918a69ba38d73f3232ba1ab46ef9ede6cb29c","cb59317243a11379a101eb2f27b9df1022674c3df1df0727360a0a3f963f523b","0a01b0b5a9e87d04737084731212106add30f63ec640169f1462ba2e44b6b3a8","06b8a7d46195b6b3980e523ef59746702fd210b71681a83a5cf73799623621f9","860e4405959f646c101b8005a191298b2381af8f33716dc5f42097e4620608f8","f7e32adf714b8f25d3c1783473abec3f2e82d5724538d8dcf6f51baaaff1ca7a","e07d62a8a9a3bb65433a62e9bbf400c6bfd2df4de60652af4d738303ee3670a1","bfbf80f9cd4558af2d7b2006065340aaaced15947d590045253ded50aabb9bc5","851e8d57d6dd17c71e9fa0319abd20ab2feb3fb674d0801611a09b7a25fd281c","c3bd2b94e4298f81743d92945b80e9b56c1cdfb2bef43c149b7106a2491b1fc9","a246cce57f558f9ebaffd55c1e5673da44ea603b4da3b2b47eb88915d30a9181","d993eacc103c5a065227153c9aae8acea3a4322fe1a169ee7c70b77015bf0bb2","fc2b03d0c042aa1627406e753a26a1eaad01b3c496510a78016822ef8d456bb6","063c7ebbe756f0155a8b453f410ca6b76ffa1bbc1048735bcaf9c7c81a1ce35f","748e79252a7f476f8f28923612d7696b214e270cc909bc685afefaac8f052af0","9669075ac38ce36b638b290ba468233980d9f38bdc62f0519213b2fd3e2552ec","4d123de012c24e2f373925100be73d50517ac490f9ed3578ac82d0168bfbd303","656c9af789629aa36b39092bee3757034009620439d9a39912f587538033ce28","3ac3f4bdb8c0905d4c3035d6f7fb20118c21e8a17bee46d3735195b0c2a9f39f","1f453e6798ed29c86f703e9b41662640d4f2e61337007f27ac1c616f20093f69","af43b7871ff21c62bf1a54ec5c488e31a8d3408d5b51ff2e9f8581b6c55f2fc7","70550511d25cbb0b6a64dcac7fffc3c1397fd4cbeb6b23ccc7f9b794ab8a6954","af0fbf08386603a62f2a78c42d998c90353b1f1d22e05a384545f7accf881e0a","c3f32a185cd27ac232d3428a8d9b362c3f7b4892a58adaaa022828a7dcd13eed","3139c3e5e09251feec7a87f457084bee383717f3626a7f1459d053db2f34eb76","4888fd2bcfee9a0ce89d0df860d233e0cee8ee9c479b6bd5a5d5f9aae98342fe","3be870c8e17ec14f1c18fc248f5d2c4669e576404744ff5c63e6dafcf05b97ea","56654d2c5923598384e71cb808fac2818ca3f07dd23bb018988a39d5e64f268b","8b6719d3b9e65863da5390cb26994602c10a315aa16e7d70778a63fee6c4c079","6ab380571d87bd1d6f644fb6ab7837239d54b59f07dc84347b1341f866194214","547d3c406a21b30e2b78629ecc0b2ddaf652d9e0bdb2d59ceebce5612906df33","b3a4f9385279443c3a5568ec914a9492b59a723386161fd5ef0619d9f8982f97","3fe66aba4fbe0c3ba196a4f9ed2a776fe99dc4d1567a558fb11693e9fcc4e6ed","140eef237c7db06fc5adcb5df434ee21e81ee3a6fd57e1a75b8b3750aa2df2d8","0944ec553e4744efae790c68807a461720cff9f3977d4911ac0d918a17c9dd99","7c9ed7ffdc6f843ab69e5b2a3e7f667b050dd8d24d0052db81e35480f6d4e15d","7c7d9e116fe51100ff766703e6b5e4424f51ad8977fe474ddd8d0959aa6de257","af70a2567e586be0083df3938b6a6792e6821363d8ef559ad8d721a33a5bcdaf","006cff3a8bcb92d77953f49a94cd7d5272fef4ab488b9052ef82b6a1260d870b","7d44bfdc8ee5e9af70738ff652c622ae3ad81815e63ab49bdc593d34cb3a68e5","339814517abd4dbc7b5f013dfd3b5e37ef0ea914a8bbe65413ecffd668792bc6","34d5bc0a6958967ec237c99f980155b5145b76e6eb927c9ffc57d8680326b5d8","9eae79b70c9d8288032cbe1b21d0941f6bd4f315e14786b2c1d10bccc634e897","18ce015ed308ea469b13b17f99ce53bbb97975855b2a09b86c052eefa4aa013a","5a931bc4106194e474be141e0bc1046629510dc95b9a0e4b02a3783847222965","5e5f371bf23d5ced2212a5ff56675aefbd0c9b3f4d4fdda1b6123ac6e28f058c","907c17ad5a05eecb29b42b36cc8fec6437be27cc4986bb3a218e4f74f606911c","3656f0584d5a7ee0d0f2cc2b9cffbb43af92e80186b2ce160ebd4421d1506655","a726ad2d0a98bfffbe8bc1cd2d90b6d831638c0adc750ce73103a471eb9a891c","f44c0c8ce58d3dacac016607a1a90e5342d830ea84c48d2e571408087ae55894","75a315a098e630e734d9bc932d9841b64b30f7a349a20cf4717bf93044eff113","9131d95e32b3d4611d4046a613e022637348f6cebfe68230d4e81b691e4761a1","b03aa292cfdcd4edc3af00a7dbd71136dd067ec70a7536b655b82f4dd444e857","90f690a1c5fcb4c2d19c80fea05c8ab590d8f6534c4c296d70af6293ede67366","be95e987818530082c43909be722a838315a0fc5deb6043de0a76f5221cbad24","9ed5b799c50467b0c9f81ddf544b6bcda3e34d92076d6cab183c84511e45c39f","b4fa87cc1833839e51c49f20de71230e259c15b2c9c3e89e4814acc1d1ef10de","e90ac9e4ac0326faa1bc39f37af38ace0f9d4a655cd6d147713c653139cf4928","ea27110249d12e072956473a86fd1965df8e1be985f3b686b4e277afefdde584","1f6058d60eaa8825f59d4b76bbf6cc0e6ad9770948be58de68587b0931da00cc","5666075052877fe2fdddd5b16de03168076cf0f03fbca5c1d4a3b8f43cba570c","50100b1a91f61d81ca3329a98e64b7f05cddc5e3cb26b3411adc137c9c631aca","11aceaee5663b4ed597544567d6e6a5a94b66857d7ebd62a9875ea061018cd2c","6e30d0b5a1441d831d19fe02300ab3d83726abd5141cbcc0e2993fa0efd33db4","423f28126b2fc8d8d6fa558035309000a1297ed24473c595b7dec52e5c7ebae5","fb30734f82083d4790775dae393cd004924ebcbfde49849d9430bf0f0229dd16","2c92b04a7a4a1cd9501e1be338bf435738964130fb2ad5bd6c339ee41224ac4c","c5c5f0157b41833180419dacfbd2bcce78fb1a51c136bd4bcba5249864d8b9b5","669b754ec246dd7471e19b655b73bda6c2ca5bb7ccb1a4dff44a9ae45b6a716a","4bb6035e906946163ecfaec982389d0247ceeac6bdee7f1d07c03d9c224db3aa","8a44b424edee7bb17dc35a558cc15f92555f14a0441205613e0e50452ab3a602","24a00d0f98b799e6f628373249ece352b328089c3383b5606214357e9107e7d5","33637e3bc64edd2075d4071c55d60b32bdb0d243652977c66c964021b6fc8066","0f0ad9f14dedfdca37260931fac1edf0f6b951c629e84027255512f06a6ebc4c","16ad86c48bf950f5a480dc812b64225ca4a071827d3d18ffc5ec1ae176399e36","8cbf55a11ff59fd2b8e39a4aa08e25c5ddce46e3af0ed71fb51610607a13c505","d5bc4544938741f5daf8f3a339bfbf0d880da9e89e79f44a6383aaf056fe0159","c82857a876075e665bbcc78213abfe9e9b0206d502379576d7abd481ade3a569","4f71d883ed6f398ba8fe11fcd003b44bb5f220f840b3eac3c395ad91304e4620","5229c3934f58413f34f1b26c01323c93a5a65a2d9f2a565f216590dfbed1fe32","9fd7466b77020847dbc9d2165829796bf7ea00895b2520ff3752ffdcff53564b","fbfc12d54a4488c2eb166ed63bab0fb34413e97069af273210cf39da5280c8d6","85a84240002b7cf577cec637167f0383409d086e3c4443852ca248fc6e16711e","4c754b03f36ff35fc539f9ebb5f024adbb73ec2d3e4bfb35b385a05abb36a50e","59507446213e73654d6979f3b82dadc4efb0ed177425ae052d96a3f5a5be0d35","a914be97ca7a5be670d1545fc0691ac3fbabd023d7d084b338f6934349798a1f","8f62cbd3afbd6a07bb8c934294b6bfbe437021b89e53a4da7de2648ecfc7af25","62c3621d34fb2567c17a2c4b89914ebefbfbd1b1b875b070391a7d4f722e55dc","c05ac811542e0b59cb9c2e8f60e983461f0b0e39cea93e320fad447ff8e474f3","8e7a5b8f867b99cc8763c0b024068fb58e09f7da2c4810c12833e1ca6eb11c4f","132351cbd8437a463757d3510258d0fa98fd3ebef336f56d6f359cf3e177a3ce","df877050b04c29b9f8409aa10278d586825f511f0841d1ec41b6554f8362092b","33d1888c3c27d3180b7fd20bac84e97ecad94b49830d5dd306f9e770213027d1","ee942c58036a0de88505ffd7c129f86125b783888288c2389330168677d6347f","a3f317d500c30ea56d41501632cdcc376dae6d24770563a5e59c039e1c2a08ec","eb21ddc3a8136a12e69176531197def71dc28ffaf357b74d4bf83407bd845991","0c1651a159995dfa784c57b4ea9944f16bdf8d924ed2d8b3db5c25d25749a343","aaa13958e03409d72e179b5d7f6ec5c6cc666b7be14773ae7b6b5ee4921e52db","0a86e049843ad02977a94bb9cdfec287a6c5a0a4b6b5391a6648b1a122072c5a","87437ca9dabab3a41d483441696ff9220a19e713f58e0b6a99f1731af10776d7","26c5dfa9aa4e6428f4bb7d14cbf72917ace69f738fa92480b9749eebce933370","8e94328e7ca1a7a517d1aa3c569eac0f6a44f67473f6e22c2c4aff5f9f4a9b38","d604d413aff031f4bfbdae1560e54ebf503d374464d76d50a2c6ded4df525712","299f0af797897d77685d606502be72846b3d1f0dc6a2d8c964e9ea3ccbacf5bc","12bfd290936824373edda13f48a4094adee93239b9a73432db603127881a300d","340ceb3ea308f8e98264988a663640e567c553b8d6dc7d5e43a8f3b64f780374","c5a769564e530fba3ec696d0a5cff1709b9095a0bdf5b0826d940d2fc9786413","7124ef724c3fc833a17896f2d994c368230a8d4b235baed39aa8037db31de54f","5de1c0759a76e7710f76899dcae601386424eab11fb2efaf190f2b0f09c3d3d3","9c5ee8f7e581f045b6be979f062a61bf076d362bf89c7f966b993a23424e8b0d","1a11df987948a86aa1ec4867907c59bdf431f13ed2270444bf47f788a5c7f92d","3c97b5ea66276cf463525a6aa9d5bb086bf5e05beac70a0597cda2575503b57b","b756781cd40d465da57d1fc6a442c34ae61fe8c802d752aace24f6a43fedacee","0fe76167c87289ea094e01616dcbab795c11b56bad23e1ef8aba9aa37e93432a","3a45029dba46b1f091e8dc4d784e7be970e209cd7d4ff02bd15270a98a9ba24b","032c1581f921f8874cf42966f27fd04afcabbb7878fa708a8251cac5415a2a06","69c68ed9652842ce4b8e495d63d2cd425862104c9fb7661f72e7aa8a9ef836f8","a31383256374723b47d8b5497a9558bbbcf95bcecfb586a36caf7bfd3693eb0e","06f62a14599a68bcde148d1efd60c2e52e8fa540cc7dcfa4477af132bb3de271","64aa66c7458cbfd0f48f88070b08c2f66ae94aba099dac981f17c2322d147c06","11f19ce32d21222419cecab448fa335017ebebf4f9e5457c4fa9df42fa2dcca7","2e8ee2cbb5e9159764e2189cf5547aebd0e6b0d9a64d479397bb051cd1991744","1b0471d75f5adb7f545c1a97c02a0f825851b95fe6e069ac6ecaa461b8bb321d","1d157c31a02b1e5cca9bc495b3d8d39f4b42b409da79f863fb953fbe3c7d4884","07baaceaec03d88a4b78cb0651b25f1ae0322ac1aa0b555ae3749a79a41cba86","619a132f634b4ebe5b4b4179ea5870f62f2cb09916a25957bff17b408de8b56d","f60fa446a397eb1aead9c4e568faf2df8068b4d0306ebc075fb4be16ed26b741","f3cb784be4d9e91f966a0b5052a098d9b53b0af0d341f690585b0cc05c6ca412","350f63439f8fe2e06c97368ddc7fb6d6c676d54f59520966f7dbbe6a4586014e","eba613b9b357ac8c50a925fa31dc7e65ff3b95a07efbaa684b624f143d8d34ba","9814545517193cf51127d7fbdc3b7335688206ec04ee3a46bba2ee036bd0dcac","0f6199602df09bdb12b95b5434f5d7474b1490d2cd8cc036364ab3ba6fd24263","c8ca7fd9ec7a3ec82185bfc8213e4a7f63ae748fd6fced931741d23ef4ea3c0f","5c6a8a3c2a8d059f0592d4eab59b062210a1c871117968b10797dee36d991ef7","ad77fd25ece8e09247040826a777dc181f974d28257c9cd5acb4921b51967bd8","795a08ae4e193f345073b49f68826ab6a9b280400b440906e4ec5c237ae777e6","8153df63cf65122809db17128e5918f59d6bb43a371b5218f4430c4585f64085","a8150bc382dd12ce58e00764d2366e1d59a590288ee3123af8a4a2cb4ef7f9df","5adfaf2f9f33957264ad199a186456a4676b2724ed700fc313ff945d03372169","d5c41a741cd408c34cb91f84468f70e9bda3dfeabf33251a61039b3cdb8b22d8","c91d3f9753a311284e76cdcb348cbb50bca98733336ec726b54d77b7361b34de","cbaf4a4aa8a8c02aa681c5870d5c69127974de29b7e01df570edec391a417959","c7135e329a18b0e712378d5c7bc2faec6f5ab0e955ea0002250f9e232af8b3e4","340a45cd77b41d8a6deda248167fa23d3dc67ec798d411bd282f7b3d555b1695","fae330f86bc10db6841b310f32367aaa6f553036a3afc426e0389ddc5566cd74","cf25d45c02d5fd5d7adb16230a0e1d6715441eef5c0a79a21bfeaa9bbc058939","54c3822eaf6436f2eddc92dd6e410750465aba218adbf8ce5d488d773919ec01","99d99a765426accf8133737843fb024a154dc6545fc0ffbba968a7c0b848959d","c782c5fd5fa5491c827ecade05c3af3351201dd1c7e77e06711c8029b7a9ee4d","883d2104e448bb351c49dd9689a7e8117b480b614b2622732655cef03021bf6d","d9b00ee2eca9b149663fdba1c1956331841ae296ee03eaaff6c5becbc0ff1ea8","09a7e04beb0547c43270b327c067c85a4e2154372417390731dfe092c4350998","eee530aaa93e9ec362e3941ee8355e2d073c7b21d88c2af4713e3d701dab8fef","b5ef97d6974dc1246197361e661027adb2625a8544bb406d5ad1daae0fe47a22","8b8b92781a6bf150f9ee83f3d8ee278b6cdb98b8308c7ab3413684fc5d9078ef","7a0e4cd92545ad03910fd019ae9838718643bd4dde39881c745f236914901dfa","c99ebd20316217e349004ee1a0bc74d32d041fb6864093f10f31984c737b8cad","6f622e7f054f5ab86258362ac0a64a2d6a27f1e88732d6f5f052f422e08a70e7","d62d2ef93ceeb41cf9dfab25989a1e5f9ca5160741aac7f1453c69a6c14c69be","1491e80d72873fc586605283f2d9056ee59b166333a769e64378240df130d1c9","c32c073d389cfaa3b3e562423e16c2e6d26b8edebbb7d73ccffff4aa66f2171d","eca72bf229eecadb63e758613c62fab13815879053539a22477d83a48a21cd73","633db46fd1765736409a4767bfc670861468dde60dbb9a501fba4c1b72f8644d","689390db63cb282e6d0e5ce9b8f1ec2ec0912d0e2e6dac7235699a15ad17d339","f2ee748883723aa9325e5d7f30fce424f6a786706e1b91a5a55237c78ee89c4a","a2d8505de5a285a95212b0e7d8abb5a85944bbc76c50804d5fe2d001b9f5dcac","a314a39426700ba2b5a76c01bab321bbe79cfef898dae996e930b017fc2b0af9","c33a88f2578e8df2fdf36c6a0482bbee615eb3234c8f084ba31a9a96bd306b7f","22cca068109eb0e6b4f8acc3fe638d1e6ac277e2044246438763319792b546a1","8776e64e6165838ac152fa949456732755b0976d1867ae5534ce248f0ccd7f41","b6f78e34ec0465c8748976b4ecffbc18443193686136e4ef5f09e0acf64425c7","5c4c5b49bbb01828402bb04af1d71673b18852c11b7e95bfd5cf4c3d80d352c8","b1879b3db28afe9ba769e84058e7d544c55322e69f34b928df96ec50f17a051d","a96bc00e0c356e29e620eaec24a56d6dd7f4e304feefcc99066a1141c6fe05a7","d12cc0e5b09943c4cd0848f787eb9d07bf78b60798e4588c50582db9d4decc70","53b094f1afe442490555eeeb0384fc1ceb487560c83e31f9c64fb934c2dccd94","19c3760af3cbc9da99d5b7763b9e33aaf8d018bc2ed843287b7ff4343adf4634","9d1e38aeb76084848d2fcd39b458ec88246de028c0f3f448b304b15d764b23d2","d406da1eccf18cec56fd29730c24af69758fe3ff49c4f94335e797119cbc0554","4898c93890a136da9156c75acd1a80a941a961b3032a0cf14e1fa09a764448b7","f5d7a845e3e1c6c27351ea5f358073d0b0681537a2da6201fab254aa434121d3","9ddf8e9069327faa75d20135cab675779844f66590249769c3d35dd2a38c2ba9","d7c30f0abfe9e197e376b016086cf66b2ffb84015139963f37301ed0da9d3d0d","ff75bba0148f07775bcb54bf4823421ed4ebdb751b3bf79cc003bd22e49d7d73","d40d20ac633703a7333770bfd60360126fc3302d5392d237bbb76e8c529a4f95","35a9867207c488061fb4f6fe4715802fbc164b4400018d2fa0149ad02db9a61c","91bf47a209ad0eae090023c3ebc1165a491cf9758799368ffcbee8dbe7448f33","0abe2cd72812bbfc509975860277c7cd6f6e0be95d765a9da77fee98264a7e32","13286c0c8524606b17a8d68650970bab896fb505f348f71601abf0f2296e8913","fc2a131847515b3dff2f0e835633d9a00a9d03ed59e690e27eec85b7b0522f92","90433c678bc26751eb7a5d54a2bb0a14be6f5717f69abb5f7a04afc75dce15a4","cd0565ace87a2d7802bf4c20ea23a997c54e598b9eb89f9c75e69478c1f7a0b4","738020d2c8fc9df92d5dee4b682d35a776eaedfe2166d12bc8f186e1ea57cc52","86dd7c5657a0b0bc6bee8002edcfd544458d3d3c60974555746eb9b2583dc35e","d97b96b6ecd4ee03f9f1170722c825ef778430a6a0d7aab03b8929012bf773cd","f61963dc02ef27c48fb0e0016a413b1e00bcb8b97a3f5d4473cedc7b44c8dc77","272dbfe04cfa965d6fff63fdaba415c1b5a515b1881ae265148f8a84ddeb318f","2035fb009b5fafa9a4f4e3b3fdb06d9225b89f2cbbf17a5b62413bf72cea721a","e7f68ad89f943f167d40e045423f035beed4f91d4ceeec02381289211af1c644","72636f59b635c378dc9ea5246b9b3517b1214e340e468e54cb80126353053b2e","ebb79f267a3bf2de5f8edc1995c5d31777b539935fab8b7d863e8efb06c8e9ea","ada033e6a4c7f4e147e6d76bb881069dc66750619f8cc2472d65beeec1100145","52ff5e1ea35c54428b46c75fd14f87b7a7158a8f4a1ecfc4a9b996a03185c738","605d29d619180fbec287d1701e8b1f51f2d16747ec308d20aba3e9a0dac43a0f","67c19848b442d77c767414084fc571ce118b08301c4ddff904889d318f3a3363","c704ff0e0cb86d1b791767a88af21dadfee259180720a14c12baee668d0eb8fb","195c50e15d5b3ea034e01fbdca6f8ad4b35ad47463805bb0360bdffd6fce3009","da665f00b6877ae4adb39cd548257f487a76e3d99e006a702a4f38b4b39431cb","2b82adc9eead34b824a3f4dad315203fbfa56bee0061ccf9b485820606564f70","79cfed5eb33a189e2a590d4b4bb53ec0edd0624779d51126caae6395620a717d","d7a4309673b06223537bc9544b1a5fe9425628e1c8ab5605f3c5ebc27ecb8074","a1ca31e02359442c3e254204445cded3a4712e8830663a0fe06f894b8982ab7c","3eadfd083d40777b403f4f4eecfa40f93876f2a01779157cc114b2565a7afb51","3ac0b94ba8f884f63d38450ce9e29ecd59ff00805ffdd609193d7532b8605459","a3684ea9719122f9477902acd08cd363a6f3cff6d493df89d4dc12fa58204e27","2828dabf17a6507d39ebcc58fef847e111dcf2d51b8e4ff0d32732c72be032b3","c0c46113b4cd5ec9e7cf56e6dbfb3930ef6cbba914c0883eeced396988ae8320","118ea3f4e7b9c12e92551be0766706f57a411b4f18a1b4762cfde3cd6d4f0a96","33395c26f51d1663fda112972df743324d1054fe2a932c85a8bd59d1c771c33e","6305acbe492b9882ec940f8f0c8e5d1e1395258852f99328efcb1cf1683ca817","7619b1f6087a4e9336b2c42bd784b05aa4a2204a364b60171e5a628f817a381e","15be9120572c9fbcd3c267bd93b4140354514c9e70734e6fcca65ff4a246f83a","412482ab85893cec1d6f26231359474d1f59f6339e2743c08da1b05fc1d12767","858e2315e58af0d28fcd7f141a2505aba6a76fd10378ba0ad169b0336fee33fc","02da6c1b34f4ae2120d70cf5f9268bf1aedf62e55529d34f5974f5a93655ce38","3ecf179ef1cc28f7f9b46c8d2e496d50b542c176e94ed0147bab147b4a961cd6","b145da03ce7e174af5ced2cbbd16e96d3d5c2212f9a90d3657b63a5650a73b7f","c7aadab66a2bc90eeb0ab145ca4daebcbc038e24359263de3b40e7b1c7affba6","99518dc06286877a7b716e0f22c1a72d3c62be42701324b49f27bcc03573efff","f4575fd196a7e33c7be9773a71bcc5fbe7182a2152be909f6b8e8e7ba2438f06","05cba5acd77a4384389b9c62739104b5a1693efd66e6abac6c5ffc53280ae777","acacda82ebd929fe2fe9e31a37f193fc8498a7393a1c31dc5ceb656e2b45b708","1b13e7c5c58ab894fe65b099b6d19bb8afae6d04252db1bf55fe6ba95a0af954","4355d326c3129e5853b56267903f294ad03e34cc28b75f96b80734882dedac80","37139a8d45342c05b6a5aa1698a2e8e882d6dca5fb9a77aa91f05ac04e92e70b","e37191297f1234d3ae54edbf174489f9a3091a05fe959724db36f8e58d21fb17","3fca8fb3aab1bc7abb9b1420f517e9012fdddcbe18803bea2dd48fad6c45e92e","d0b0779e0cac4809a9a3c764ba3bd68314de758765a8e3b9291fe1671bfeb8a1","d2116b5f989aa68e585ae261b9d6d836be6ed1be0b55b47336d9f3db34674e86","d79a227dd654be16d8006eac8b67212679d1df494dfe6da22ea0bd34a13e010c","b9c89b4a2435c171e0a9a56668f510a376cb7991eaecef08b619e6d484841735","e2efbe9ad735950e0536a93120106219a25f45ba0ab7984d58497b5c9d19330e","6a79b61f57699de0a381c8a13f4c4bcd120556bfab0b4576994b6917cb62948b","c5133d7bdec65f465df12f0b507fbc0d96c78bfa5a012b0eb322cf1ff654e733","00b9ff040025f6b00e0f4ac8305fea1809975b325af31541bd9d69fa3b5e57b1","9f96b9fd0362a7bfe6a3aa70baa883c47ae167469c904782c99ccc942f62f0dc","27dad95a76606bfd8f5c36b7c05bf49dd2e66bdbe03dba745426734f82346ae6","89049878a456b5e0870bb50289ea8ece28a2abd0255301a261fa8ab6a3e9a07d","55ae9554811525f24818e19bdc8779fa99df434be7c03e5fc47fa441315f0226","24abac81e9c60089a126704e936192b2309413b40a53d9da68dadd1dd107684e","f13310c360ecffddb3858dcb33a7619665369d465f55e7386c31d45dfc3847bf","e7bde95a05a0564ee1450bc9a53797b0ac7944bf24d87d6f645baca3aa60df48","62e68ce120914431a7d34232d3eca643a7ddd67584387936a5202ae1c4dd9a1b","4e49cb98e2c4e546dd90fb6a867ef88978dea05502df92cb252078cdd407cd1d","e1cb8168c7e0bd4857a66558fe7fe6c66d08432a0a943c51bacdac83773d5745","a464510505f31a356e9833963d89ce39f37a098715fc2863e533255af4410525","ebbe6765a836bfa7f03181bc433c8984ca29626270ca1e240c009851222cb8a7","ac10457b51ee4a3173b7165c87c795eadd094e024f1d9f0b6f0c131126e3d903","468df9d24a6e2bc6b4351417e3b5b4c2ca08264d6d5045fe18eb42e7996e58b4","954523d1f4856180cbf79b35bd754e14d3b2aea06c7efd71b254c745976086e9","a8af4739274959d70f7da4bfdd64f71cfc08d825c2d5d3561bc7baed760b33ef","3e1e58eff1981ef808ead362d1586c132b309247cd14e3929fbd36d9ca80d3fe","cc32874a27100c32e3706d347eb4f435d6dd5c0d83e547c157352f977bbc6385","e45b069d58c9ac341d371b8bc3db4fa7351b9eee1731bffd651cfc1eb622f844","7f3c74caad25bfb6dfbf78c6fe194efcf8f79d1703d785fc05cd606fe0270525","54f3f7ff36384ca5c9e1627118b43df3014b7e0f62c9722619d19cdb7e43d608","2f346f1233bae487f1f9a11025fc73a1bf9093ee47980a9f4a75b84ea0bb7021","e04c5673b82d68376f57dea0e4a4fbacf6f1692c9382fb12b5fb2e93ce174c12","2350e4399e456a61e4340254b71fba87b02b76a403a502c649912865a249f14d","2579b150b86b5f644d86a6d58f17e3b801772c78866c34d41f86f3fc9eb523fe","0353e05b0d8475c10ddd88056e0483b191aa5cdea00a25e0505b96e023f1a2d9","d60d0eeebe3a5a7489e57b9d00d43868281014b0d8b180e29e2f664f1bfe873b","22a35275abc67f8aba44efc52b2f4b1abc2c94e183d36647fdab5a5e7c1bdf23","99193bafaa9ce112889698de25c4b8c80b1209bb7402189aea1c7ada708a8a54","70473538c6eb9494d53bf1539fe69df68d87c348743d8f7244dcb02ca3619484","c48932ab06a4e7531bdca7b0f739ace5fa273f9a1b9009bcd26902f8c0b851f0","df6c83e574308f6540c19e3409370482a7d8f448d56c65790b4ac0ab6f6fedd8","32f19b665839b1382b21afc41917cda47a56e744cd3df9986b13a72746d1c522","8db1ed144dd2304b9bd6e41211e22bad5f4ab1d8006e6ac127b29599f4b36083","843a5e3737f2abbbbd43bf2014b70f1c69a80530814a27ae1f8be213ae9ec222","6fc1be224ad6b3f3ec11535820def2d21636a47205c2c9de32238ba1ac8d82e6","5a44788293f9165116c9c183be66cefef0dc5d718782a04847de53bf664f3cc1","afd653ae63ce07075b018ba5ce8f4e977b6055c81cc65998410b904b94003c0a","9172155acfeb17b9d75f65b84f36cb3eb0ff3cd763db3f0d1ad5f6d10d55662f","71807b208e5f15feffb3ff530bec5b46b1217af0d8cc96dde00d549353bcb864","1a6eca5c2bc446481046c01a54553c3ffb856f81607a074f9f0256c59dd0ab13","d3f2d715f57df3f04bf7b16dde01dec10366f64fce44503c92b8f78f614c1769","b78cd10245a90e27e62d0558564f5d9a16576294eee724a59ae21b91f9269e4a","fedd311d427fdafac411b4e0edc0d1014668853679e021e04717a6de45ff5c0c","2f5747b1508ccf83fad0c251ba1e5da2f5a30b78b09ffa1cfaf633045160afed",{"version":"50072f976cfa86af1a3044f55cd729d992abe39222d2f6cdf929266c77a42b0b","affectsGlobalScope":true},"b71c603a539078a5e3a039b20f2b0a0d1708967530cf97dec8850a9ca45baa2b","34118be360cdd3381bbebbfd4b093c394460c8fc5df40688d58f45d86ab1448b","82819f9ecc249a6a3e284003540d02ea1b1f56f410c23231797b9e1e4b9622df","cc0d0b339f31ce0ab3b7a5b714d8e578ce698f1e13d7f8c60bfb766baeb1d35c","5c45abf1e13e4463eacfd5dedda06855da8748a6a6cb3334f582b52e219acc04",{"version":"1c10fac2f2fb1593438e99c7bb4f161f4bfc742f43418b535a8f56a361615c25","signature":"af2513f9e52515cd8071d142fca1e6f7b8c747eb9db558c7949ce70a1d02c5ab"},"0381ff3106ae2cd28e7cdf6b8d594d8722b27703ee0f4d1e467344fd73db52aa","deb1660a3318478a20eae7a8221c87d5d1c6d64d40f9eba87cb8fb62b3b86c96","20bc4f597f97571a694fe13bd5ee7aadc36619cc1f811b54b753508e1fbad0da","5199552cfaf38433b0998a825bb92eec050a4efd723725d1f6cb96ca3bd4d831","6e3bd4c8b83d57c91a46908e299b9415ac7b1cbc0839812bd9673703180cce04","70c624c29e709ed6fa606ff463eb72f9d4bb8038aaa503aa7849e613c8096bf1","17170ce84e1c8263863797e2b233939338d1370bfc0ae6d9bd36713bf2ab3b83","fcf6e2a981eeae1fe1ca84417a6a9bc2cda70fc7d59899ae518f22fc89bd0294","b7febc27fee5d9bfc84a8ed4a4e8ae6bf8419c4badd92b60fe73ecb4d0eed600","edd0d3186d39c81586ca68708e50a6c48f6c1d15878bda0db91a664f7505eb4a","6de6715daf79487d9d7f47cc09a64db3ac7b4bdc911ca12b7c179fccfee3db04","5eb2a99ec89e7e945e49823fe9d4380edad7b24de487eee9a16097c3078137eb","fab819540d70e97ed4a7a1fc356b0045f64a85595cbea9ff6c3bd7a8f33aa2a1","00bb95b13ebe6ba44d2e763be91ba44ed0ccca0bda3d2a26862f31d36578a68f","4ffeb1789d4714fc78ebf4df4ab367b8fc0a8deed5b38b11c41ea60637576042","26c82a5ade313319d2cdd8784db64f687b4e61e7b4c60e0e56564f33dd5b1dd9","0a0add89a43d51a9eb233dff01d00a1d50af884d43669b91d8f894ec4400f951","12920ec6117c8aaa2c1d97acf3e07aaf1ae4dd9708292b596eeb12da59a646ab","8dbcd3cb3860652c1bd030055b5bd82e979cca4d0c459fcfc11060096bf8053a","e398ebcb592512a3d7af9f0335b629f91c525719a37d7130ef6d508568209d5d","8b0b6a4c032a56d5651f7dd02ba3f05fbfe4131c4095093633cda3cae0991972","ff3c48a17bf10dfbb62448152042e4a48a56c9972059997ab9e7ed03b191809b","192a0c215bffe5e4ac7b9ff1e90e94bf4dfdad4f0f69a5ae07fccc36435ebb87","3ef8565e3d254583cced37534f161c31e3a8f341ff005c98b582c6d8c9274538","d7e42a3800e287d2a1af8479c7dd58c8663e80a01686cb89e0068be6c777d687","1098034333d3eb3c1d974435cacba9bd5a625711453412b3a514774fec7ca748","f2388b97b898a93d5a864e85627e3af8638695ebfa6d732ecd39d382824f0e63","6c6bd91368169cfa94b4f8cc64ebca2b050685ec76bc4082c44ce125b5530cca","f477375e6f0bf2a638a71d4e7a3da8885e3a03f3e5350688541d136b10b762a6","a44d6ea4dc70c3d789e9cef3cc42b79c78d17d3ce07f5fd278a7e1cbe824da56","a74519588a22a1c254c2853ba4dc82d0dfc1da22ad7ac7fd6feb6a91236ef5d1","1803e48a3ec919ccafbcafeef5e410776ca0644ae8c6c87beca4c92d8a964434","875c43c5409e197e72ee517cb1f8fd358406b4adf058dbdc1e50c8db93d68f26","8854713984b9588eac1cab69c9e2a6e1a33760d9a2d182169059991914dd8577","e333d487ca89f26eafb95ea4b59bea8ba26b357e9f2fd3728be81d999f9e8cf6","2f554c6798b731fc39ff4e3d86aadc932fdeaa063e3cbab025623ff5653c0031","fe4613c6c0d23edc04cd8585bdd86bc7337dc6265fb52037d11ca19eeb5e5aaf","53b26fbee1a21a6403cf4625d0e501a966b9ccf735754b854366cee8984b711c","30676a61ef0eca261117e20257cd3ac49803301afc9a29c543abf34930202933","981379335e8bb8e39196931acc39ff446922c964ac0998b61caac8e242068d31","8c59d8256086ed17676139ee43c1155673e357ab956fb9d00711a7cac73e059d","cfe88132f67aa055a3f49d59b01585fa8d890f5a66a0a13bb71973d57573eee7","53ce488a97f0b50686ade64252f60a1e491591dd7324f017b86d78239bd232ca","50fd11b764194f06977c162c37e5a70bcf0d3579bf82dd4de4eee3ac68d0f82f","e0ceb647dcdf6b27fd37e8b0406c7eafb8adfc99414837f3c9bfd28ffed6150a","99579aa074ed298e7a3d6a47e68f0cd099e92411212d5081ce88344a5b1b528d","d2d58166965f631fa203f405f3713b0f86f1f8b80755e9daea43057a25311e16","ce7dbf31739cc7bca35ca50e4f0cbd75cd31fd6c05c66841f8748e225dc73aaf","942ab34f62ac3f3d20014615b6442b6dc51815e30a878ebc390dd70e0dec63bf","7a671bf8b4ad81b8b8aea76213ca31b8a5de4ba39490fbdee249fc5ba974a622","8e07f13fb0f67e12863b096734f004e14c5ebfd34a524ed4c863c80354c25a44","6f6bdb523e5162216efc36ebba4f1ef8e845f1a9e55f15387df8e85206448aee","aa2d6531a04d6379318d29891de396f61ccc171bfd2f8448cc1649c184becdf2","d422f0c340060a53cb56d0db24dd170e31e236a808130ab106f7ab2c846f1cdb","424403ef35c4c97a7f00ea85f4a5e2f088659c731e75dbe0c546137cb64ef8d8","16900e9a60518461d7889be8efeca3fe2cbcd3f6ce6dee70fea81dfbf8990a76","6daf17b3bd9499bd0cc1733ab227267d48cd0145ed9967c983ccb8f52eb72d6e","e4177e6220d0fef2500432c723dbd2eb9a27dcb491344e6b342be58cc1379ec0","ab710f1ee2866e473454a348cffd8d5486e3c07c255f214e19e59a4f17eece4d","db7ff3459e80382c61441ea9171f183252b6acc82957ecb6285fff4dca55c585","4a168e11fe0f46918721d2f6fcdb676333395736371db1c113ae30b6fde9ccd2","2a899aef0c6c94cc3537fe93ec8047647e77a3f52ee7cacda95a8c956d3623fb","ef2c1585cad462bdf65f2640e7bcd75cd0dbc45bae297e75072e11fe3db017fa","6a52170a5e4600bbb47a94a1dd9522dca7348ce591d8cdbb7d4fe3e23bbea461","6f6eadb32844b0ec7b322293b011316486894f110443197c4c9fbcba01b3b2fa","a51e08f41e3e948c287268a275bfe652856a10f68ddd2bf3e3aaf5b8cdb9ef85","16c144a21cd99926eeba1605aec9984439e91aa864d1c210e176ca668f5f586a","af48a76b75041e2b3e7bd8eed786c07f39ea896bb2ff165e27e18208d09b8bee","ef1aa3da0d6bc679154169c3830ab65441b615641a6e982410ee3cbdc66fa290","deb092bc337b2cb0a1b14f3d43f56bc663e1447694e6d479d6df8296bdd452d6","aa4e4a68ce82cb642b78a1efa5768fb717ba3a019641d161c803a09c748813d1","77165b117f552be305d3bc2ef83424ff1e67afb22bfabd14ebebb3468c21fcaa","128e7c2ffd37aa29e05367400d718b0e4770cefb1e658d8783ec80a16bc0643a","076ac4f2d642c473fa7f01c8c1b7b4ef58f921130174d9cf78430651f44c43ec","396c1e5a39706999ec8cc582916e05fcb4f901631d2c192c1292e95089a494d9","89df75d28f34fc698fe261f9489125b4e5828fbd62d863bbe93373d3ed995056","8ccf5843249a042f4553a308816fe8a03aa423e55544637757d0cfa338bb5186","93b44aa4a7b27ba57d9e2bad6fb7943956de85c5cc330d2c3e30cd25b4583d44","a0c6216075f54cafdfa90412596b165ff85e2cadd319c49557cc8410f487b77c","3c359d811ec0097cba00fb2afd844b125a2ddf4cad88afaf864e88c8d3d358bd","d8ec19be7d6d3950992c3418f3a4aa2bcad144252bd7c0891462b5879f436e4e","f0a6974a1b5d0ceb79f5a589373cc2a291bd80a765eb2d799db6d8d51f2c2462","d62f09256941e92a95b78ae2267e4cf5ff2ca8915d62b9561b1bc85af1baf428","e6223b7263dd7a49f4691bf8df2b1e69f764fb46972937e6f9b28538d050b1ba","2daf06d8e15cbca27baa6c106253b92dad96afd87af9996cf49a47103b97dc95","1db014db736a09668e0c0576585174dbcfd6471bb5e2d79f151a241e0d18d66b","8a153d30edde9cefd102e5523b5a9673c298fc7cf7af5173ae946cbb8dd48f11","abaaf8d606990f505ee5f76d0b45a44df60886a7d470820fcfb2c06eafa99659","8109e0580fc71dbefd6091b8825acf83209b6c07d3f54c33afeafab5e1f88844","d92a80c2c05cf974704088f9da904fe5eadc0b3ad49ddd1ef70ca8028b5adda1","fbd7450f20b4486c54f8a90486c395b14f76da66ba30a7d83590e199848f0660","ece5b0e45c865645ab65880854899a5422a0b76ada7baa49300c76d38a530ee1","62d89ac385aeab821e2d55b4f9a23a277d44f33c67fefe4859c17b80fdb397ea","fdf7c509d71aa2449602687f9689ce294510985f701e97b014f5aef69f5cbec7","fb8dd49a4cd6d802be4554fbab193bb06e2035905779777f32326cb57cf6a2c2","df29ade4994de2d9327a5f44a706bbe6103022a8f40316839afa38d3e078ee06","82d3e00d56a71fc169f3cf9ec5f5ffcc92f6c0e67d4dfc130dafe9f1886d5515","f06737e21dd482dc9ea719299a665460aaa9d0f185c7302703468f46002cc16e","4c30a5cb3097befb9704d16aa4670e64e39ea69c5964a1433b9ffd32e1a5a3a1","1b33478647aa1b771314745807397002a410c746480e9447db959110999873ce","7b3a5e25bf3c51af55cb2986b89949317aa0f6cbfb5317edd7d4037fa52219a9","b4f1cc43cdf2f75f62ea43ab32ac29e26649920906712d9605cef4849f48065b","9fac6ebf3c60ced53dd21def30a679ec225fc3ff4b8d66b86326c285a4eebb5a","8cb83cb98c460cd716d2a98b64eb1a07a3a65c7362436550e02f5c2d212871d1","07bc8a3551e39e70c38e7293b1a09916867d728043e352b119f951742cb91624","e47adc2176f43c617c0ab47f2d9b2bb1706d9e0669bf349a30c3fe09ddd63261","7fec79dfd7319fec7456b1b53134edb54c411ba493a0aef350eee75a4f223eeb","189c489705bb96a308dcde9b3336011d08bfbca568bcaf5d5d55c05468e9de7a","98f4b1074567341764b580bf14c5aabe82a4390d11553780814f7e932970a6f7","dadfa5fd3d5c511ca6bfe240243b5cf2e0f87e44ea63e23c4b2fce253c0d4601","2e252235037a2cd8feebfbf74aa460f783e5d423895d13f29a934d7655a1f8be","763f4ac187891a6d71ae8821f45eef7ff915b5d687233349e2c8a76c22b3bf2a","ac7815e4f927feac26a3c73640aaeb87876472a135232b5a10bc6f918a1444c3","e67a1dfff0eb3f776458f2e21669aa1d57a8adf4431e92f2fb08db1337562df3","8c90fbd4af08caf4e660bb0e217453b6783c966211eb951afb6dd5fa0bfb4399","ee712c31249de1064ec4d9cd4577e5f312a9c3388fd2d48851465ae8abb9bab4","61d0d30796b07001057010c6eb865030dcc645f2bd23e02d90312e2a813fb496","c11afba878cc5062a89e2741751ffcea936f3718c3351128c87bb6a93f842a72","aa69b42f4c46bc294337b5fb24aa1820e64834d5aa88d0cf345c408dec8bd277","0ee7ab8812df5f1a7c4cb5f596167c06ff4868ca07711d6c8a92085e14144344","006c49256b38dd556a0bb3e1da05b400d55321cab859ac1d1f798e4f80b16593","064e412388f3fc803113a9f0a6c9748db61af558659ffd3fcfdf6b523e95aae0","1f22f046ebca492907074395b0de913becdd800f43b5d3f80991307ae9c22ec4","73cb04184c297a3a2250396d99df35225fa614743557a3dfd3ca9941189dc910","19b0fa509f0c04f83487b4d1d03429e88eab6f41ed420e78fa06a17f580391a8","25332f39ac08a905cc4b8ddc11f2f30603607e91fdebe3a5ded251e175f6c12b","0ffecea8e5751aca2736d9ea8458a64fbdbdc62f3e497114cda7b3956145c7d6","124463eb27255384ce60cfcef7bc25a4359a55259c06ba71c9f0829e7b8a06c3","91b03102b008c1bfa7be3b2f4649b9588bfa62418be82393c52ef1625ab72a16","2cdb9312c51f7ddec069354630c4bb1d12612ded5408e78cdedcc97d0b416b01","0f76760e928909011ac0381652a046f2451d5e118a14beeec1a9fc06c423d411","a7cf9e060eb2caa1ed81cb9052861208f968943f88d7e688feb21a26f157d2d2","18c1ae647fdcb9e0ddc75c04cd08e7b376091f4c38952b1769a85450bde44fad","dff5b022e5487090a981e1ec7d8765dabc78984ecfad1578d9e3ca046ef0836a","13091d74f19d333d65da558489b18d25a5180fb9fbfbad15bc7dfe7461c328cf","3f641ab16c05cec621ed5c04777d2f8656a5b41a35c506b75b594d90adc540b9","7cd0c0bf0adc2914931df0ed16f7f1fa1b1698bbc02366db1ae1e429ea4ef155","8f1241f5d9f0d3d72117768b3c974e462840fbd85026fb66685078945404cf2f",{"version":"1507b4389837faba7426ff43a24c06630442435463de56efdef6b789d9953e8c","signature":"957341409a29fce5d54c1d982ce02bc3c7236f261cb852a4fe864a421400e07a"},{"version":"02c79fd502bd990fcefce268909eedc2ba31e844872b5649297e6e51f84a9594","signature":"a9bb0657fdc0d1225bf3f66cf1daa3853dd86fe66d6b1865a3177b853a10a092"},{"version":"893acc186a978de3de7f35bf15f0bc9b80735ec26a4cfee86c560578796301fe","signature":"fac54f4613282350bfa589b6ae7ec652710bdc5773fed1c9fc406b9f3baa239c"},{"version":"4b2c1ccced6a7f872befe82e3d6d15053dcb05d1132e22738ff31e4b9e2df680","signature":"cc4becfba18fffd3789fc25a8ac8ef6c567c7d4b22b9d2060bd2a807369ffbd4"},"b97aa4bb35dfdca3a2fa7ba335b8367f3666fccb04bf3843a6595aa2fe28ddc4","e7a7c88c676c65bbad6da8a5a7486e6344920c35037873fdc7e74b1c903d5525",{"version":"3f107647dc4df9d578ebfd6d342036df49952de98f09ba2853b2006225828683","signature":"e282b9059573bd554ca0969ef1071fef897994a450322ace49991e867ec580db"},{"version":"93b6e590f44b1e85d1faa3bd609572bfe548a099b8634c0b40bcbb268a4ff542","signature":"0a09318879610ef741cf22b30e4b3c7c342eb65de80c83644ba7f39720f4cf2d"},{"version":"bf29e6c22259af160bc1bb91fb461221239fefcf4b1ed2c078323d666c248ea7","signature":"a3630835ac43689d77ea826997015686a30192e1d632f20f5c7f5799ab1fa3c6"},"f587f1b039ce7c40009c5c3471d62d86765f05d7074fbbf53779f25273f9d788",{"version":"d75ff520b33130b1844fb856f4bada896394c571de75a94c1515fa2130c0ebf8","signature":"3b64563bf6f0e39cf9fc1c1e8bc0fe125d6c7f1d08c5df448d704cb18cb8af22"},{"version":"b28f79ebbf06264f51e42062fd8818fa5466f34275b425be95912ff776690178","signature":"dd06d6b7018b5c7329c146fc62496aa745695cacbb3c92973be94a5af16c6265"},{"version":"a5fb3824a431a3bb73974aeda93649aca06521f31bfb9f480b4b3a49fabe4b91","signature":"6ec69216818d16890510cc063f6f1b1883e71b582b2b132ac383d57f8939fec1"},"a4e9e0d92dcad2cb387a5f1bdffe621569052f2d80186e11973aa7080260d296","f6380cc36fc3efc70084d288d0a05d0a2e09da012ee3853f9d62431e7216f129","497c3e541b4acf6c5d5ba75b03569cfe5fe25c8a87e6c87f1af98da6a3e7b918","d9429b81edf2fb2abf1e81e9c2e92615f596ed3166673d9b69b84c369b15fdc0","7e22943ae4e474854ca0695ab750a8026f55bb94278331fda02a4fb42efce063","7da9ff3d9a7e62ddca6393a23e67296ab88f2fcb94ee5f7fb977fa8e478852ac","e1b45cc21ea200308cbc8abae2fb0cfd014cb5b0e1d1643bcc50afa5959b6d83","c9740b0ce7533ce6ba21a7d424e38d2736acdddeab2b1a814c00396e62cc2f10","b3c1f6a3fdbb04c6b244de6d5772ffdd9e962a2faea1440e410049c13e874b87","dcaa872d9b52b9409979170734bdfd38f846c32114d05b70640fd05140b171bb","6c434d20da381fcd2e8b924a3ec9b8653cf8bed8e0da648e91f4c984bd2a5a91","992419d044caf6b14946fa7b9463819ab2eeb7af7c04919cc2087ce354c92266","fa9815e9ce1330289a5c0192e2e91eb6178c0caa83c19fe0c6a9f67013fe795c","5ddfb68ce43fa0c38025992728b3da8bb21c83970b91b17358eaa5f5377f7270","81b171430a6ffd9b495df08a7b9883981483cec487cbc172d3ed307e061e6095","0d8e0ad7c41c8e3fdde54ea670d762736cd84098fce8065870b94ce8571fa715","7e046b9634add57e512412a7881efbc14d44d1c65eadd35432412aa564537975","aac9079b9e2b5180036f27ab37cb3cf4fd19955be48ccc82eab3f092ee3d4026","3d9c38933bc69e0a885da20f019de441a3b5433ce041ba5b9d3a541db4b568cb","606aa2b74372221b0f79ca8ae3568629f444cc454aa59b032e4cb602308dec94","50474eaea72bfda85cc37ae6cd29f0556965c0849495d96c8c04c940ef3d2f44","b4874382f863cf7dc82b3d15aed1e1372ac3fede462065d5bfc8510c0d8f7b19","df10b4f781871afb72b2d648d497671190b16b679bf7533b744cc10b3c6bf7ea","1fdc28754c77e852c92087c789a1461aa6eed19c335dc92ce6b16a188e7ba305","a656dab1d502d4ddc845b66d8735c484bfebbf0b1eda5fb29729222675759884","465a79505258d251068dc0047a67a3605dd26e6b15e9ad2cec297442cbb58820","c78b2d4c7298a61cd1209bb7a5ec611c3f12fd17ed25d85905a2e76aa20d379f","d0e25feadef054c6fc6a7f55ccc3b27b7216142106b9ff50f5e7b19d85c62ca7","111214009193320cacbae104e8281f6cb37788b52a6a84d259f9822c8c71f6ca","01c8e2c8984c96b9b48be20ee396bd3689a3a3e6add8d50fe8229a7d4e62ff45","a4a0800b592e533897b4967b00fb00f7cd48af9714d300767cc231271aa100af","20aa818c3e16e40586f2fa26327ea17242c8873fe3412a69ec68846017219314","f498532f53d54f831851990cb4bcd96063d73e302906fa07e2df24aa5935c7d1","5fd19dfde8de7a0b91df6a9bbdc44b648fd1f245cae9e8b8cf210d83ee06f106","3b8d6638c32e63ea0679eb26d1eb78534f4cc02c27b80f1c0a19f348774f5571","ce0da52e69bc3d82a7b5bc40da6baad08d3790de13ad35e89148a88055b46809","9e01233da81bfed887f8d9a70d1a26bf11b8ddff165806cc586c84980bf8fc24","214a6afbab8b285fc97eb3cece36cae65ea2fca3cbd0c017a96159b14050d202","14beeca2944b75b229c0549e0996dc4b7863e07257e0d359d63a7be49a6b86a4","f7bb9adb1daa749208b47d1313a46837e4d27687f85a3af7777fc1c9b3dc06b1","c549fe2f52101ffe47f58107c702af7cdcd42da8c80afd79f707d1c5d77d4b6e","3966ea9e1c1a5f6e636606785999734988e135541b79adc6b5d00abdc0f4bf05","0b60b69c957adb27f990fbc27ea4ac1064249400262d7c4c1b0a1687506b3406","12c26e5d1befc0ded725cee4c2316f276013e6f2eb545966562ae9a0c1931357","27b247363f1376c12310f73ebac6debcde009c0b95b65a8207e4fa90e132b30a","05bd302e2249da923048c09dc684d1d74cb205551a87f22fb8badc09ec532a08","fe930ec064571ab3b698b13bddf60a29abf9d2f36d51ab1ca0083b087b061f3a","95072d8907c6f2fcfb7d0c8457ad1af36a79ec11854ee84ecd03b7d1aea0b11f","dbfa8af0021ddb4ddebe1b279b46e5bccf05f473c178041b3b859b1d535dd1e5","7ab2721483b53d5551175e29a383283242704c217695378e2462c16de44aff1a","ebafa97de59db1a26c71b59fa4ee674c91d85a24a29d715e29e4db58b5ff267d","16ba4c64c1c5a52cc6f1b4e1fa084b82b273a5310ae7bc1206c877be7de45d03","1538a8a715f841d0a130b6542c72aea01d55d6aa515910dfef356185acf3b252","68eeb3d2d97a86a2c037e1268f059220899861172e426b656740effd93f63a45","d5689cb5d542c8e901195d8df6c2011a516d5f14c6a2283ffdaae381f5c38c01","675e5ac3410a9a186dd746e7b2b5612fa77c49f534283876ffc0c58257da2be7","951a8f023da2905ae4d00418539ff190c01d8a34c8d8616b3982ff50c994bbb6","cb3732a7b44717c331f14e6d122a4521d8a68c305977967d7389fa3827d790ae","8893ebec01e96d34635cbe98b943311060fc63dc2ee2fa562c64e742509f00df","e4b31fc1a59b688d30ff95f5a511bfb05e340097981e0de3e03419cbefe36c0e","16a2ac3ba047eddda3a381e6dac30b2e14e84459967f86013c97b5d8959276f3","45f1c5dbeb6bbf16c32492ba182c17449ab18d2d448cc2751c779275be0713d8","23d9f0f07f316bc244ffaaec77ae8e75219fb8b6697d1455916bc2153a312916","eac028a74dba3e0c2aa785031b7df83586beab4efce9da4903b2f3abad293d3a","4809c7cb9b898a6a2711da871f9c321ab0b9b398f3e625f27924670a1c7aaaf1","3a1fc0aae490201663c926fde22e6203a8ac6aa4c01c7f5532d2dcdde5b512f5","995284f69830cc22f3651c3fd3318842c38a34615501906cf753dbc1f30279d1","53f751014cc08afeae6c3199b89b0ab0718e4f97da8b7845c5b2333748277938","a7f590406204026bf49d737edb9d605bb181d0675e5894a6b80714bbc525f3df","533039607e507410c858c1fa607d473deacb25c8bf0c3f1bd74873af5210e9a0","b09561e71ae9feab2e4d2b06ceb7b89de7fad8d6e3dc556c33021f20b0fb88c4","dd79d768006bfd8dd46cf60f7470dca0c8fa25a56ac8778e40bd46f873bd5687","4daacd053dd57d50a8cdf110f5bc9bb18df43cd9bcc784a2a6979884e5f313de","d103fff68cd233722eea9e4e6adfb50c0c36cc4a2539c50601b0464e33e4f702","3c6d8041b0c8db6f74f1fd9816cd14104bcd9b7899b38653eb082e3bdcfe64d7","4207e6f2556e3e9f7daa5d1dd1fdaa294f7d766ebea653846518af48a41dd8e0","c94b3332d328b45216078155ba5228b4b4f500d6282ac1def812f70f0306ed1c","43497bdd2d9b53afad7eed81fb5656a36c3a6c735971c1eed576d18d3e1b8345","5db2d64cfcfbc8df01eda87ce5937cb8af952f8ba8bbc8fd2a8ef10783614ca7","b13319e9b7e8a9172330a364416d483c98f3672606695b40af167754c91fa4ec","7f8a5e8fc773c089c8ca1b27a6fea3b4b1abc8e80ca0dd5c17086bbed1df6eaa","0d54e6e53636877755ac3e2fab3e03e2843c8ca7d5f6f8a18bbf5702d3771323","124b96661046ec3f63b7590dc13579d4f69df5bb42fa6d3e257c437835a68b4d","bf389b810d5a33e68e528a8b1b71e0e5a3bd60b6ecec5fd19e119c9b05d3e314","0caba5dcc79a55e85a5cba9621bfa8fd759e5da7f2055363a0b07b775a6bce64","5076cf71e2e0e2d612c9327e4de4c04300a340a4a8d9444c35baf11b5dbbd636","20064a8528651a0718e3a486f09a0fd9f39aaca3286aea63ddeb89a4428eab2b","743da6529a5777d7b68d0c6c2b006800d66e078e3b8391832121981d61cd0abc","f87c199c9f52878c8a2f418af250ccfc80f2419d0bd9b8aebf4d4822595d654f","57397be192782bd8bedf04faa9eea2b59de3e0cfa1d69367f621065e7abd253b","df9e6f89f923a5e8acf9ce879ec70b4b2d8d744c3fb8a54993396b19660ac42a","cfcb1aa42e69653afb196120ea3f1e2214de9b6ac1bdeb813e92d850c8622f07","357d9107437961745e9e141ff2bcf0c2d13be077e82e77ff494ce1141f220f3a","100ed467f1a8ea38224fb92df4475797ca6f089fcb5c1a51a0031b73ca70bbab","8038580e10bdc9dd9b657e4f07db4ce030ec125296bc57e1618f9546bba153f0","e3ae8133276eabd3b63a1949563a0c739c90c786d61f99be60619764d0b629fe","876fcf7d77c1212763790b6d37f2c77857637f12a374150c62244ab7d38c8c5a","5aa8aba8b72403bcb922e03ddd1525da4aa58402c5bc1c068012da5f0dfce376","53f751014cc08afeae6c3199b89b0ab0718e4f97da8b7845c5b2333748277938","5c2be411905dba1b271c5c037315393d49d52875d2f136ffb8bb035ea605429e","b46549d078955775366586a31e75028e24ad1f3c4bc1e75ad51447c717151c68","e723d4346889718b1be52a7de4ad96c8b19fc71ca21b3e896c13284232a410a9","d3b8fe4da3222369df6318e051520c89f2b4b8a08f2ac70b70a45ee477e28f87","4f58eb211bd14b46e13381050498c806390bfed66f26710e6507bbf5287316c2","2423fa71d467235a0abffb4169e4650714d37461a8b51dc4e523169e6caac9b8","7b23befec1c066f4759775c55a1dc6700e858e6a4998d3f86281224528682e7d","07ea97f8e11cedfb35f22c5cab2f7aacd8721df7a9052fb577f9ba400932933b","66ab54a2a098a1f22918bd47dc7af1d1a8e8428aa9c3cb5ef5ed0fef45a13fa4","ad81f30f47f1ab2bb5528b97c1e6e4dab5e006413925052f4573a30bf4a632bd","ff3f1d258bd14ca6bbf7c7158580b486d199e317fc4c433f98f13b31e6bb5723","a3f1cac717a25f5b8b6df9deef8fc8d0a0726390fdaa83aed55be430cd532ebf","bf22ee38d4d989e1c72307ab701557022e074e66940cf3d03efa9beb72224723","68ce7df3ae5d096597107619d2507ef4e86a641c0371f88a4a6fa0adac6cb461","0fc0b5aebcca18a99177852db0a5983c14ebda520ff41f4a8270732f0883c342","1553d16fb752521327f101465a3844fe73684503fdd10bed79bd886c6d72a1bc","271119c7cbd09036fd8bd555144ec0ea54d43b59bcb3d8733995c8ef94cb620b","5a51eff6f27604597e929b13ee67a39267df8f44bbd6a634417ed561a2fa05d6","1f93b377bb06ed9de4dc4eb664878edb8dcac61822f6e7633ca99a3d4a1d85da","53e77c7bf8f076340edde20bf00088543230ba19c198346112af35140a0cfac5","6e0f9298ff05cc206fe1ec45fd2b55a8d93d4136b0d75b395c73968814d7c5ba","53f751014cc08afeae6c3199b89b0ab0718e4f97da8b7845c5b2333748277938","68888ec4d4cff782a03aebc26ddc821e1f4dffb3a22940164eff67371997add6","c9018ca6314539bf92981ab4f6bc045d7caaff9f798ce7e89d60bb1bb70f579c","d3180fac64b45ee9ab9ebbdb2c87c08ce0537323dd3627d145660c92510b78bf","b83a3738f76980505205e6c88ca03823d01b1aa48b3700e8ba69f47d72ab8d0f","01b9f216ada543f5c9a37fbc24d80a0113bda8c7c2c057d0d1414cde801e5f9d","f1e9397225a760524141dc52b1ca670084bde5272e56db1bd0ad8c8bea8c1c30","08c43afe12ba92c1482fc4727aab5f788a83fd49339eb0b43ad01ed2b5ad6066","6066b918eb4475bfcce362999f7199ce5df84cea78bd55ed338da57c73043d45","5fd5d02d1ec7d48a180deaefcfec819c364ec4ffddd1371ec2c7ad9d36e8220f","e39514fc08fdedd95766643609b0ede54386156196d79a2d9d49247fb4406dcd","e4a4e40e8bc24425e03de8f002c62448dbaefe284278c0a1d93af2bfd2b528c2","4e6fc96724557945de42c1c5d64912ebd90d181358e1e58cce4bbf7b7b24d422","20328d1ad61e5ef8e47d0f5b9c520d15ebc06e52cc840850f6072e995de07241","b200803e4eaf08cd7e3d16654bffca691a7e3eeb6804d7c999fcbb932f5b90b0","3a068b4954258ea9306603de7a5ec42b7be327be62b20cf4e907354290a20102","53f751014cc08afeae6c3199b89b0ab0718e4f97da8b7845c5b2333748277938","66bcbb14f32b7378ff58e3072a8ed44147f426498106e247128025bd4106218a","1de2e632b3710713715129f773f58c042724df9a36dd3cce49264068bdf1ce76","e804948a45dce9d1f7b2574e005e3df0003e57e4b583eafa397b5fdb02de098c",{"version":"1400a4145306f2e83f285f922c0d6564290c0fa5ead6a7b85845fc5dacfab195","affectsGlobalScope":true},"66c303f279f1a44b9ec72ebbbf35896a15d88874a0cd2447fc48c311aecbe9d1","dcc2705ead5b9bc969e3b96932c71d384cdaf9fce7ce545525d92331e68a38e7","fbb365e81fb1529cec173102623d82d99e76eb2a0316b6d0a131740a7a884ca1","67168b5f67979142e8819950b4f1c8a28ec3dd67c9e56d91774ed59e452fe52f","68d3b7471f46eef88cc91409851e676bb0e8f2babe34cefeaf1163a82335cf71","b9d1750b399975c9e250d90a33b02a35b6f6f967cfe4f66c66e6cc913f513cff","53f751014cc08afeae6c3199b89b0ab0718e4f97da8b7845c5b2333748277938","8c08d9462aea926ca97762998338846866edb4cb89c2f7ee07cb50c9324912cf","c80aa3ff0661e065d700a72d8924dcec32bf30eb8f184c962da43f01a5edeb6f","d0a20f432f1f10dc5dbb04ae3bee7253f5c7cee5865a262f9aac007b84902276","07ab762f55781d94dfa6d58846f40d7b8be6e1f75debb5de45de759a28ddf4f0","c6028d6d6827a51e6188ed230af2b9a7deeed94830f64efe7faa74fb0deec2de","cd8a6ae649ab1e44334f12b4066edcd591b8d3fff858acc5cf4ecad37e4a0ffd","4e03465826d61ddd2a4c727b4799f1c6852616b4de8e2c012f570d73d6a46b9e","cf2bc6fd43fcfef0396f62850947c077a6f64e4825a8a6bc604c1baa23e2a2cf","f9415f9d308ce3add9d0bd004ead1963603ac5c43a06dd4423609ccfab950318","dcc2705ead5b9bc969e3b96932c71d384cdaf9fce7ce545525d92331e68a38e7","4f1aec681b85cd96c666d4f228ecade4a0eb7c5155a6afd8d6fb4c48dc09a7ad","6bed8cc464fd5ce28a9e46a45dd9cb36a9446c214487f75585703350d524031a","8c08d9462aea926ca97762998338846866edb4cb89c2f7ee07cb50c9324912cf","c80aa3ff0661e065d700a72d8924dcec32bf30eb8f184c962da43f01a5edeb6f","67168b5f67979142e8819950b4f1c8a28ec3dd67c9e56d91774ed59e452fe52f","68d3b7471f46eef88cc91409851e676bb0e8f2babe34cefeaf1163a82335cf71","d0a20f432f1f10dc5dbb04ae3bee7253f5c7cee5865a262f9aac007b84902276","7b0d13b17fba793bd34d544dc70e517f0134de4578123efde31b2225907caa2b","785f671e759a4429c3a12cfde16ae320bef31324b75ad3838efd547df0c9c0a1","0eb2c7b28fa553e063372cab2e2eb775ff0752b29c4b588a8d0545eecf70f467","e20f14c3925bd87252bd521708a852a93cedbd338981e2700922a779891a82db","ebd84b1e150e446df27f4b9efca78fa48c0cada5146dc0f64de0be7d611894b2","ba5675f82d2a5429a86089ccbbc553f160479dc468e87c693d909c54ffb335a0","07298e4ef5336013076fbb87a7eaac669fbffa1827b4718a05ab0a966e8dddfc","14b42e07aafc14a31c9604bbef5cb63e32f312d2adbdd188d5b4015e09d83f0b","c76f233c97e3880ce45b5815a2702c3eb797faaa1cc9ddb327facdb33d5ce960","b6579417b4231f0312e715234cc604aa791f237aa4e04b430449181806df1b34","075bf7146e19e373cf1ecfc5c43c75626bdb20e47b7baae17d54b631e2d407be","33bb615855e9cb95ab454048b66152fc189cfcc815a71968f3fba0568a493dac","1a5c3236c4fcdab61fb9d1d9ced27324dce6f9c1f5653a4dfe6f5c8b692a8ed0","66a626e617bfaa4417e6806174ae602d0f7fa631f7f44b88663b272bf1e5eb9e","41ca214cf922678daa4dbfbe0f72cc9ac9c9858baced90041a64d4b29430fb25","e6772530652d0c3c95fe9fc2882261cbafda44bfb0a2dbc360fed8db0132ff42","793b9f1b275af203f9751081adfe2dc11d17690fd5863d97bd90b539fa38c948","015b9253293cee33a84af9a93ac69e0df829fa7f4fa7e73e13bb247e68875d90","f8ce39b41d85f60fe1d9141c8e27e4a0a0e771fd128e9c029dd328ec91f2e6d3","db7caaff7380b6d84b4bde4d3220917238826160fa6a6171d54c3762316adaf1","5f7a9c515c1b7924b9381d40a0f2a3781a2c25a39905191ea4b37d295c97df96","659875f9a0880fb4ae1ce4b35b970304d2337f98fe6f2e4671567d7292780bae","bd6e65808e598fab67ef5761ad9c05309f99f836de38ef7b2a90153edf2a7984","e009f9f511db1a215577f241b2dc6d3f9418f9bc1686b6950a1d3f1b433a37ff","caa48f3b98f9737d51fabce5ce2d126de47d8f9dffeb7ad17cd500f7fd5112e0","64d15723ce818bb7074679f5e8d4d19a6e753223f5965fd9f1a9a1f029f802f7","2900496cc3034767cd31dd8e628e046bc3e1e5f199afe7323ece090e8872cfa7","ba74ef369486b613146fa4a3bccb959f3e64cdc6a43f05cc7010338ba0eab9f7","a22bbe0aeceec1dc02236a03eee7736760ecd39de9c8789229ce9a70777629bb","76cc80d2a2937cce7c868ea790fd00d8203f5eceef6b98010699b5295e74742d","dd68b3074453d9926be489e6b3c5af62fa9d9dad83a71a85ad94a4b854b249a5","ca2ebe3f3791275d3287eed417660b515eb4d171f0b7badcfa95f0f709b149f7","ea87c3c9ae41413d3ca7902142da9aac8e595a272e89ecd4dd33064753e50227","e2a4983a141f4185996e1ab3230cb24754c786d68434f2e7659276c325f3c46c","b2216c0b4c7f32e7e9bba74d0223fc9ad3bec50b71663701d60578cecc323fb5","1cbbd9272af325d7189d845c75bbdb6d467ce1691afe12bcb9964e4bd1270e66","86eb11b1e540fe07b2ebfc9cca24c35b005f0d81edf7701eaf426db1f5702a07","1a12da23f2827e8b945787f8cc66a8f744eabf3d3d3d6ba7ad0d5dfeeb5dfbb4","c4b2c0671a6091712b0489ab5907b82d697df8333bcf4127fef7424620f1284a","2cb440791f9d52fa2222c92654d42f510bf3f7d2f47727bf268f229feced15ba","5bb4355324ea86daf55ee8b0a4d0afdef1b8adadc950aab1324c49a3acd6d74e","64e07eac6076ccb2880461d483bae870604062746415393bfbfae3db162e460a","5b6707397f71e3e1c445a75a06abf882872d347c4530eef26c178215de1e6043","c74d9594bda9fe32ab2a99010db232d712f09686bbee66f2026bc17401fe7b7e","15bbb824c277395f8b91836a5e17fedc86f3bb17df19dcdc5173930fd50cc83e","1c94de96416c02405da00d8f7bde9d196064c3ce1464f0c4df1966202196b558","406cc85801b49efd5f75c84cc557e2bba9155c7f88c758c3fadd4e844ad6b19e","6d235f62eb41ac4010a0dab8ba186c20dec8565f42273a34f0fa3fc3ca9d0dbb","f7663954884610aeb38c78ffd22525749fab19ab5e86e4a53df664180efd1ff5","4ac0045aa4bc48b5f709da38c944d4fec2368eda6b67e4dd224147f3471b7eaf","1d2d7636e3c6906a5d368ab0bab53df39e2a6f99c284bae4625b6445c1d799e7","9555a2d83e46b47c5b72de5637b2afad68b28670deacdb3b514267d780b5423c","3e717eef40648a7d8895219063b1e5cb5bcc404bc1d41a22b91f3140b83bce1d","9b61c06ab1e365e5b32f50a56c0f3bb2491329bb3cd2a46e8caa30edcf0281cc","8f91df3614625daa000bffe84a5c1939b4da0254db9d7c62764f916ebb93dcdc","ee745db646de4c5cf019e495ff5d800ed6f4ee9d9b3aaa7b2c5ca836928bc80e","37482be55ff3f2e8a447b71d6b4dded7cc3594466b28430236ec1abda1d60368","059a7dfc70b0e875ef87a961d1e9b69917a32a6eea1c3950a5aad8c62d8274aa","cf575b64fadf5f646c0f715730c490f317f856f5b3bbe06493638576bad711d9","d260a7eae2f0f643fe2de133cfa3e7d035e9e787cb88119f9628099d4039609c","6306621db4fbb1c1e79883599912c32da2c5974402531b47a2cf2c19ce61200e","a4f50263cd9ef27fcb0ab56c7214ffca3a0871f93ddd3dfb486bfa07aeed55ef","61bf659c0508ae055d056fa5cb7fc921bc25d03847b6b8ac5a258404a5f3d446","f6ff0d0ac0bf324dd366aadf72c5458da333fbd44aa1dae825507be3b3b6ccdc","aa8f659712fd02d08bdf17d3a93865d33bd1ee3b5bcf2120b2aa5e9374a74157","5a06765319ef887a78dd42ca5837e2e46723525b0eaa53dd31b36ba9b9d33b56","27bf29df603ae9c123ffd3d3cfd3b047b1fa9898bf04e6ab3b05db95beebb017","18ff01937979e8d823354642d4860622682d47f09de8f98a0df5676201a596f6","4278526ea26849feb706bbc4cda029b6fd99dd8875fb58daeeca02b346bbdbb4","9d1c3fe1639a48bfd9b086b8ae333071f7da60759344916600b979b7ed6ffaa6","8b3d89d08a132d7a2549ac0a972af3773f10902908a96590b3fe702c325a80ec","450040775fe198d9bf87cf57ca398d1d2e74b4f84bca6e5dbf0b73217cf9004b","63f57eda431bb6a950797ecc4dafe38034d7be7781f2c95f2af32765a2516943","49cfd2c983594c18fe36f64c82d5e1282fd5d42168e925937345ef927b07f073","7b0d13b17fba793bd34d544dc70e517f0134de4578123efde31b2225907caa2b","5e1451d46c41dcddd3cbf7f8d6fa9c9d53a677c10fe11b5ac2a12a36b7eca103","480440377cb8db73b96ec7b68bd91d77e384e5b10d580470786017192f539273","7de84da9deb32a2975ae18d9d4edbd36165da8b7508f0d82b0bfa4724392055e",{"version":"3059e91227cd0bdf2e4627b949e3a6fc8508f88759d5368e1ecf476fdc4941cd","signature":"dc395f14d6dabab664681e4d71f3f68425ee753003a15b1a9f70f34615f6efe4"},{"version":"f357af20f3a7438ccdb2a46d32ef1a7086a7e6aa624c2195e59f8c9dd171d0e3","signature":"ba237149f1438139bd9b5f930ca350f4b1055a5bf85a5b3dfa68ec488b7b2969"},"ba63131c5e91f797736444933af16ffa42f9f8c150d859ec65f568f037a416ea","aa99b580bd92dcb2802c9067534ebc32381f0e1f681a65366bcf3adae208a3a4","340a45cd77b41d8a6deda248167fa23d3dc67ec798d411bd282f7b3d555b1695","0e9aa853b5eb2ca09e0e3e3eb94cbd1d5fb3d682ab69817d4d11fe225953fc57","179683df1e78572988152d598f44297da79ac302545770710bba87563ce53e06","793c353144f16601da994fa4e62c09b7525836ce999c44f69c28929072ca206a",{"version":"fbb0e0702158969fb0c0d8b919686026b8a1ee88a4c1bd085aedb7a59ae83908","affectsGlobalScope":true},"599ac4a84b7aa6a298731179ec1663a623ff8ac324cdc1dabb9c73c1259dc854","3d348edaf4ef0169b476e42e1489ddc800ae03bd5dd3acb12354225718170774","585bc61f439c027640754dd26e480afa202f33e51db41ee283311a59c12c62e7","8f1241f5d9f0d3d72117768b3c974e462840fbd85026fb66685078945404cf2f",{"version":"c7fcaa0a4e8ffa12285a47102ddefbd0defeb79efe4845a05ba22558a9d5349f","signature":"73c1489c3a8c74b7966cf1ceed227f993ffaae557ef83dbe318fa73981944277"},"0bf811dcbddc95e2551f704cfd2afc267bf619f8b8f2b7bdbb94df96ec3cbfe3","03c92769f389dbd9e45232f7eb01c3e0f482b62555aaf2029dcbf380d5cee9e4","feac0f8faa1eee576584b1a20fae6d5ac254ffd4ac1227fab5da2f44a97068a6",{"version":"34636df93a38d9e8b434b45b54d1f2e0eec3e67dfc025ce30fdfb65aa1285eae","signature":"e3e047e8cb263193af5ebae4c6030f0ddb84e6b3c6f8c8be3413ceae2c89969a"},"b97cc1db771cf580d56411fe9221b23f313e9b0d559e5bcf311b8ceccae6f397","c661f18f244838985c029749f111042c97f4cb83a11f907efd374f3e064a3984",{"version":"60edb96b4e2f4b9e2902ec029a88f3ff0c14ecce6cc054f31504da7c7f36201e","signature":"13af7e595b8860936167361777a7348680d31e4c636d4830a32edc957ad71017"},{"version":"4c77764d55cd060ef23a684e3244b93eb4c68e5ce7998ea285baa6d3dcb07511","signature":"07e436cb4945c3a63fdbcd9790a357099b3d445b47165dfafe2c7cf764e7665f"},"7d2b7fe4adb76d8253f20e4dbdce044f1cdfab4902ec33c3604585f553883f7d",{"version":"d204bd5d20ca52a553f7ba993dc2a422e9d1fce0b8178ce2bfe55fbd027c11ae","affectsGlobalScope":true},{"version":"1426b31d3746e940bb595fca5f7d40789d155b99d2a971a0921b02aa531828c2","signature":"c20cc4a0979d790ffcc2d49d8db2570e55f09a706897a1bb7a669342108263a7"},{"version":"d63cb20544a344e7b93db768ab580705a83ecc4cb8ab30a6cd01755a8ea1935e","signature":"613c9a86acf1144a9549772a7f6cee63aca9d82ddbb9a0f2ba196815acf74973"},{"version":"5cfa8c1db320c370f58330873e629c98d9492a85d9e4172f79fcfc0f78f17675","signature":"a40506a7f2ccce3d785a086c1256c7c9e6580e277671a2f5cdcc5420e276416d"},{"version":"f4549dbf5c559078a191d6fef61dffcc3ad02fc29d7aa6b0635c4a8e1acdd519","signature":"79d76a8973dd33f75f13ecf53129a63b494079665675f5d368dde9bab17c8254"},"bdef5d263af61e7e0e872c90bab45056a65b42b94dd9c4574c5f7f20aa13e9b2","89189df027e8910200a4b65af1e29a996225cf25975f5c438fbe9361c008fc6b","2ca57ff4966cce29b180be0e22e9d47ff525db341fd6a767d0f62539d15c79bc","94679d290a509f4f1e00c1b5a3d1ef353eb99b96b627c61d1e77e942f899ff29","165b1e657a2e782586d02365c6e647625d1f83b0f86434e223e5ae79c961c413","45b3baf59d4817d5691ecd36268fd65154edabfb07befd66e24875b59d0fb4b5","4722fd74708636c5ccae96096d2e8105481d8054b1e9f2ba586380d8beae46e9","b42f4a472ebe6420a20a52bdd244168b43b5caf659a81482a09d699e2b3cf5d1","5c356da2c84f4878800c653c500dd9532330f0759cc47f8ff3f4371c27598073","06fdbe25e9708ee8c154147d4130547116feb7538905e4a0ddd3897747f00c7a","6c92284a2b4829e9ae995011130e1577d383073220af9b1b3b10a875e6dc476c","c53532785a3f84a483a04aa815814afc95aca0712d145383220e127adf8428bf","2b0b0dc6c8d721f8fe5f3fa9ae0ddc4ebef8aadb672ca2948d2efdd72229cb01","67860cb1ada55a9e04b8d251e8785a0e5f2f4241ae80f36ac4e68d447e4a5f44","14404a5de56b4ce19b2db5df3771faa206112234500938dac19af8d13745405f","c53ca15b37324f776bdab2d6d93315dfb170ed0eed502f22ffbd5363c4e1b51a","cdfd1790ef396be90b09aacc41205f4b70e905d06fa4fee279810edb8de34913","b87927a4778ff5ef21b768d784afc768241514759417a631f77f254e24563a05","900c6d7b342ed29604a346d6f680a912f7ef60ba97f44e8cb8d5205041969dec","ae82177123b07c3a2b54d5ae961ff92f85b8ed9f5ef2d096802ff7269a550c8c","8d6b7b77814d3beda2224c9d32ab4e77d373a5225f15573b77eae05f03926ed0","2cb76131ee7c1b849d730d266f49ad5617a285d7b8ad7ebc1ac2749ae454e222","c33985ae643458a14ef8a90347c135c67ad20042ae6f707ac5d81155d06f791f","6146c6200c43a0eca96e4c65fc666b37f4db80846217701c8e855217ff924ed7","34bf6d81c6b9e84f1d53c2465d521277bea994f8612a0d80417fcdaad37cfbcd","52801e6d27bdf0b84814362482e7173ee85bcb907247da42419e2450267dfd12","97f27fa4e124b5f8131dc05aa9186a92ae220495c4559ce8d29ad447c1d39774","3c8929b6d85242d708efa07744c2a849fe58015ca2d39cfb0d932389fe423c36","386a43f1433d0cb5816a8f87a0abe9ba1fc789b7730fd1bbd531bbba3e5546cf","ae7a07b3a47a4b023898e5c5c742b2f1f75ee41cf0262b95de77cbe334161ebd","2e59c8382b469370e5c7f60648be896285300a54e25acfb75007422c805c1cc6","b5d44e1f73c803a22ff49593cefaa9d8227877dc9c746c4d57eb9ad731f4a664","b1269623af3af28b18a28dacc74a381e8fcdbc4ec381736738c55cec1098c29a","9f3fa90acbe8bfa078069ad166b4c267404b1859bd42babd2aafbbd2747ff4a5","1bdf93cfb8b270ca905a8dfd106ff88277aef6c70cb72077db4faf75b30b94e3","dd898187f336e05599358274088ecb2c460fd2a16a465eced59de86b84cac9a0","c7798f43272b09de550520ead6df45f0ddf81bd97000784351d764df923e08d8","6bb4cff7be2ee4e7e726f295a7afe5b3c35262d6ae34f139f27aa5b4ce417a54","bac51c1e94eb2aa95f5795c3f2ec49eeacc930a032328f1bd4b8677ac01f1a54","59072991567e25db58f001983512157902cfc8fc5cf20a5a9a71d60736e549aa","6059431c97b4a6e55388a85918e6b8a0c11c69343b2c25751c042297c5508539","27e33d56686f59ef5595608160907e039b88d3328ee5e8fcdaff1eae00494a8e","82af965d0bbe372b7cea4ee17c2a96ecbbfe0eecca081c4aeaf63e102affcd88","9458a8792a2b3ccdb0b560c163ffc13f355766c32fca40c13356ffb413cbfd1b","dd426604fd5545c549e406e22d584bab9bcf08fbf76d4e2a14504ca6e5a6240f","d53ef95f86456d701950d9e83c7f2383cd797e6a2f9639a104488e6831b10b75","d8814232c5c4d48c345354a9175b7a6fa51bdb69b5cee34baf626851f112a561","26fdb3dab639a4a1e173b81f3b58d8f21153be2b74adaaf3e01ab113442c678f","0e3bff1ef96e028f6b5ceb035486ce989d1bc04c0f0a0b7017ebc60f100a1837","2e2bc02af7b535d267be8cecbc5831466dd71c5af294401821791b26cb363c47","986affe0f60331f20df7d708ee097056b0973d85422ec2ce754af19c1fa4e4b1","8f06c2807459f1958b297f4ad09c6612d7dbd7997c9ccfc6ea384f7538e0cea8","a7de30cd043d7299bfe9daaca3732b086e734341587c3e923b01f3fd74d31126","78f7fad319e4ac305ffe8e03027423279b53a8af4db305096aa75d446b1ec7af","3bf58923a1d27819745bdad52bca1bdced9fef12cc0c7f8a3fd5f4e0206b684a","8fc11f102df58f03d36fcbf0da3efa37c177f5f18f534c76179ceef0c3a672cd","e6935ab0f64a886e778c12a54ed6e9075ce7e7f44723ff0d52020a654b025a09","9829af7653a29f1b85d3dd688a6c6256087c0b737b85d84b630e7f93fd420faf","3d9d985d41e536fcf79fc95082925c2f1ae5ade75814ad2bd70c0944747f7ac4","167fdeb976d2a67158d372f4b9159ebf1e9fed6fc30345a577a8506ae998a274","b0e6f1b1569779cf567317c2265d67460d1d3b4de4e79126533109d87dc16d50","18cb8be1326ffa4158abd8d84c9b0a189c0f52201f12f7af2d2af830c077f2bf","b08fc2b6ccd4d3db42af01b3c6390fc1e30dc1d95496d9a8ee5f9319c2e4883f","0de68916e23c1e3df800f9f61cdd7c506ceb0656fcbc245ee9974aad26786781","80c538ee6a62249e77ba3de07efb23d4a7ca8946499c065261bf5079f1cd3cf0","ad4277862bdcbe1cf5c1e0d43b39770e1ccc033da92f5b9ff75ca8c3a03a569b","46a86c47400a564df04a1604fcac41cb599ebbada392527a1462c9dfe4713d78","f342dcb96ad26855757929a9f6632704b7013f65786573d4fdcd4da09f475923","dcd467dc444953a537502d9e140d4f2dc13010664d4216cc8e6977b3c5c3efa3","ca476924dfa6120b807a14e0a8aea7b061b8bdaa7eecdb303d7957c769102e96","5d82f2d07d9a079efe29ab47910c7f194ed5839db3d48a140e3a5cafcfc347c1","f3bb275073b5db8931c042d347fdce888775436a4774836221af57fdccec32ff","03cb8cb2f8ef002a5cac9b8c9a0c02e5fd09de128b9769c5b920a6cbfc080087","3e5ebc3a6a938a03a361f4cdb9a26c9f5a1bac82b46273e11d5d37cd8eccc918","a0a7800e71c504c21f3051a29f0f6f948f0b8296c9ebffeb67033822aabf92e0","6a219f12b3e853398d51192736707e320699a355052687bad4729784649ff519","4294a84634c56529e67301a3258448019e41c101de6b9646ea41c0ecdc70df92","80fc027e10234b809a9a40086114a8154657dcb8478d58c85ef850592d352870","27f24ba43083d406b372e9eff72dbc378afa0503dac1c1dd32499cc92fc9cb22","12594611a054ca7fe69962f690a4e79922d563b4b434716eb855d63a9d11a78f","1440eca2d8bc47ebdbc5a901b369de1b7b39c3297e5b4ac9631899f49ea9740b","fc9897fbada879bda954603ea204c6e5df913262a90ad848b5efaab182b58033","93443b2da120bea58eb48bd7da86559d4cf868dc2d581eebf9b48b51ba1e8894","182f9553b74cf62425ef64d82075bf16452cc7096450aca1aa6a1e863594a45d","c2956026078814be6dc01515213aeb1eb816e81715085952bbc97b7c81fe3f6d","ac3a69c529ab256532825b08902aec65d0d88c66963e39ae19a3d214953aedc5","fe29108f3ddf7030c3d573c5226ebe03213170b3beca5200ca7cb33755184017","04d5bfb0a0eecd66c0b3f522477bf69065a9703be8300fbea5566a0fc4a97b9d","d5e3e13faca961679bed01d80bc38b3336e7de598ebf9b03ec7d31081af735ad","de05a488fb501de32c1ec0af2a6ddfe0fdef46935b9f4ffb3922d355b15da674","9f00f2bc49f0c10275a52cb4f9e2991860d8b7b0922bfab6eafe14178377aa72","af1e2889c68a697192a0ecbda332193f022032018158f890ad403b6513e9ec17","0e7c3660d1df392b6f6ae7fa697f0629ae4404e5b7bac05dd81136247aff32d5","d110a9869e09144198be68ed9224e3f509d8409a01d578ff1c471f92b0b4c58c","c6688fd4c2a8a24c9b80da3660a7a06b93ed37d12d84f3ba4aa071ffc125e75f","20efc25890a0b2f09e4d224afaaf84917baa77b1aee60d9dfd11ff8078d73f93","d00b48096854d711cee688e7ff1ca796c1bf0d27ca509633c2a98b85cc23d47d","30f116226d0e53c6cbbdbc967479d5c8036935f771b2af51987c2e8d4cc7fc6a","8be98ffc3c54fb40b220796b796388f8ade50c8ba813a811bffccf98006566d5","4e82eed3c1b5084132708ce030f8ec90b69e4b7bb844dcaacd808045ae24c0e2","eae8c7cbcb175b997ce8e76cd6e770eca5dba07228f6cb4a44e1b0a11eb87685","b3ded8e50b3cdf548d7c8d3b3b5b2105932b04a2f08b392564f4bc499407e4e5","4ed2d8fb4c598719985b8fbef65f7de9c3f5ae6a233fc0fe20bd00193c490908","6da51da9b74383988b89e17298ceca510357f63830f78b40f72afe4d5a9cee3e","512a079a1a3de2492c80aa599e173b2ea8cc6afb2800e3e99f14330b34155fe1","28b0c5477937d40bbdc0cd329d2a9ce7c6bc9fcfd3b3cd880f62c983137bde52","8e3842ba15690ab4b340893a4552a8c3670b8f347fbb835afe14be98891eef10","9e7817283b8b1ca62652bbc10475e2e89df05b8ddc6ff4a8e32d65d9f68622e7","15911b87a2ad4b65b30c445802d55fa6186c66068603113042e8c3dfa4a35e2a","a9dc7b8d06b1f69d219f61fa3f7ac621e6e3a8d5a430e800cd7d1a755cc058c3","f8c496656cb5fd737931b4d6c60bd72a97c48f37c07dcb74a593dd24ac3f684a","abcb5db28886eec7437cb341a42fec07580fb1fbc927d1bd4f0f22b558a7aa9a","0fa43815d4b05eafe97c056dae73c313f23a9f00b559f1e942d042c7a04db93c","9d2e963a1608ebeea2728bea165742680cab4dea64542b7382a70644f82da649","a02db6aabaa291a85cf52b0c3f02a75301b80be856db63d44af4feea2179f37b","e1e94e41f47a4496566a9f40e815687a2eca1e7b7910b67704813cf61248b869","557ba6713b2a6fefd943399d5fb6c64e315dc461e9e05eaa6300fdbeeda5d0a1","94d594a0f3ce879202ea19c736e1da53b60d14bf6affac40c72c783afdd8d350","6c689f6498e87962dbbe36cedcd07ad89f9dc876f23687a41544fc485d63e92f","1a014a8365354f37ea245349a4361d3b46589be7921fe7f1dbf408cc0f084bab","e58c601cdc72f2f982b495cea79b36438f1ebc068529cb878901ec8648d30566","73c0b8df0e282e26a53820f53502847a043bd77a9cda78782207d5349842fba2","5bae6e8aeb6486bc8503767978e4960e25ce1ea16b7e89c1ea4eed1c3ab62788","e758ff8f1bf17f80b220a79139c007bad7eaa18aae8ab5e004cd13be20fb7b64","8c676a0f3158205c4c261ce9bd1ce0362923c9fd24c0bcdb17077e5ba0360bab","d6db974317fd9ff66a923555464850dcf87976054a7adacf09d53323f64686d1","92a094c28709aa6062b8cd162ae188d1755761c8e11ec7b164323152926704ce","7df6dfe294fd23c1ab8482ba7957cad3cf3419df2c64dda1f258ec87f80aea5a","9af4db510139f651fd9262340e29bc1bbd5441fc1f5518af82f3277804913402","9fb5226917009e53461dd0211acc975c720e45d9d610629efda0c1c0162501c4","a9417a980a4300048d179d0295e5b7dd76e4db7b566344779ee576cbd084b3c4","b96760c030c41fa078b35ea05fc3e7e4d2a81710a8329271d42b6abc110d5dbe","ef8ff23609cec5eb95e2beb98132ad90c0c5075415b50228b12f89ffaf981a4a","1154ed167b954ffb24a95ec3b11b1519a597024e7fda1df63c144962bc523aaf","174a3381f98fc78c451528cb1aa1baaa37a51852ec6fa90d42efd876301537c1","2c0de27d99a9331cfac8bc5c6bbd174e0593628bf3df268faa6c4188962a9549","1a17bcbc124a098987f7b1adbbcd412f8372ecb37e352b1c50165dac439eee5e","0ef49170735d9e5902f55b72465accadd0db93cae52544e3c469cbc8fbdbf654","f68a30e88dfa7d12d8dd4609bc9d5226a31d260bf3526de5554feed3f0bf0cb6","1fffef141820a0556f60aa6050eccb17dbcdc29ecd8a17ee4366573fd9c96ce3","d2598c755c11170e3b5f85cd0c237033e783fd4896070c06c35b2246879612b8","8d2044a28963c6c85a2cf4e334eb49bb6f3dd0c0dfe316233148a9be74510a0e","4c1f2da4e18122d57a16e4c6ea4b6fe60ea4f65b14e77cb20339f9158b27ca12","54a4f21be5428d7bff9240efb4e8cae3cb771cad37f46911978e013ff7289238","2411942fcfd1c06aa6a24a12e12819366c5cf0556600c73a3f02f10d5f11d5f1","cc4483c79688bd3f69c11cb3299a07d5dcf87646c35b869c77cde553c42893cf","faf76eeb5dd5d4d1e37c6eb875d114fa97297c2b50b10e25066fed09e325a77a","b741703daf465b44177ef31cc637bde5cd5345e6c048d5807108e6e868182b01","bbca0eb1a05fd2e38f4ffc686ba36ffece50c11ba13420cc662a73433c94bf74","d8acc6f92c85e784acbbc72036156a4c1168a18cba5390c7d363040479c39396","0cf6ed6724677967d5eb331c3755757ed23795f3d5be9a52a7fabefd4ceea890","5eb09226bfa1928721a438e37c004647fc19d8d1f4817bddcc350e57fb32935f","5994ed389d7fc28c03dad647ecb62e5349160bde443b0c7a54e0e10d6368bcbd","e1ff7df643e1aa1dbf1863113a913358844ed66f1af452e774834b0008e578b2","c5114285d0283d05e09cd959e605a4f76e5816c2fbe712241993fd66496083e5","2752e949c871f2cbd146efa21ebc34e4693c0ac8020401f90a45d4e150682181","c349cea980e28566998972522156daac849af8a9e4a9d59074845e319b975f5d","0370682454d1d243b75a7c7031bc8589531a472e927b67854c1b53b55ee496ea","cf6b4dbb5a1ac9ece24761c3a08682029851b292b67113a93b5e2bfd2e64e49d","5f117aca99483d48657676bd9d055e0da373dd1dff62d07a5979243345d28c5c","cb2fea712720bb7951d7e5d63db8670bf4a400d3e0fb197bceb6ef44efe36ec3","d1b5663356da50b06bf7a8c547dd30161d6435f8061678437c06efe2d1c3f66c","ef19d5fe42541f8b529bccd10f488d12caefa3b57a0deb1ed6143219cba716b4","84b5e6269d7cf53008a479eeb533ef09d025eafb4febe3729301b8d4daf37ff2","04196b5d9edd60b9648daa329c3355d7c95f33b7e520e7835eb21002174a8b8c","e17b09f8011ab42eb55095225b126ae67d8944fe86a32e5d8c6feb0f11a0f49b","762ca0ff9c7ee821b2958085a504ee6f9c47e10f466ee7e4a1a79702931a402b","c8eeffebe6c2c6800f73aa59d1436d4dadbad7f3ddda02a831ffa66114c3122d","caf3f141f93cbf527ad18ecce326311d70342fe1e16ce93e5ce8d6bcdf02bd48","4283d88023e6e9645626475e392565464eae99068f17e324cfc40a27d10fe94f","51e3b73dea24e2a9638345fb7a2a7ef5d3aa2e7a285ad6bd446b45fab826def1","546157e2534fc81242dab0ed3d69f77c82a18442a2bf0899bdafb328cc9ccd8c","c78bb1275f640e4902ad5c3383ab4f54f73322a59c95924ab671125ba9546294","1cb0838371e8213ce116a1497bb86bcf01a11a755b77587980ee7cfb2d625ece","7adaa31af611851bb98f0d111447221c24d090df7c757e32463583ca48a4e238","4e8fb81d7a8a0299f03196db93017e1811a47e8977f3f8dde0c122352b23e1a6","10b322f5bc001bec9bf08513c978c120adb0abe3c82793b11bdaf75873426c05","51b4efdc8dc92bc6ae2c44d4edad265decad70e8577d5653fc7f85200cbf6c6e","ab159dda8873292919fb0d498cafd4c922c2969928eced2b834062b4ffc2d7c7","81f80859aeaa50bde911c32c824cdb73609010dd36173e2d0ad6cc05d294eb1b","3e855437e99a09e54d2813e8e0ddcc78caf14dc9709c35ac93cdc35f2b581abd","5d6a095deeceaeff22c90fc3fdc773034fa6db61384f7b0cd115fd3e142e430c","32f9169fb6cad29917b3f1670550df48ba30dee34dcb0bffaed13947b2e0d2d2","f922ee0d3c98c614919041e327e65f1d18b9d8311ead1e16a2e89be419598a58","6df6afb0424a7c7581ee98a9333d30e893b943d0a4709b88f18c252ddc3101b4","59c2cbf84c22fae87f4f506f36a7258a72b931b602115067dfd6008ee526f8c0","1e09cd1bc6b6baa0733e1e799c4533105ea79cbb109937c71e8c870e14693216","ba25681012e5117866a2456dd3557e24aa5a946ed641126aa4469880db526883","2b1e058a8c3944890c7ce7c712ecfd0f2645420ee67537ac031d7afe6feda6e0","175dbcd1f226eebd93fd9628e9180fb537bb1171489b33db7b388ef0f4e73b37","69ec6331ee3a7cd6bade5d5f683f1705c1041ff77432aa18c50d2097e61f93db","06f34a0f2151b619314fc8a54e4352a40fd5606bda50623c326c3be365cc1ef9","fcdd4523a8af4337c755c713d7dfb23b8116ec07a98010f49df4aed8aeb6c4f5","4c9786f6198be0310ababe89f5ca93c7f048618783f21524e3596a402b34a56f","6c3d3586d8fff56a9763c47133b4a9230480534471b38c7a2f688eac5d819164","1b91b4d73641b4434ca2603b42e20f6a579cc5d2e29dd09676721cd64e9fd6a3","42852f35ebc5733c0f09eb4cb495ed78a1a12f9664eb7cf7ae877acd999d885c","70a3659d557bb683091f9d318762a330a3acb3954f5e89e5134d24c9272192f1","d9fe2c804f7db2f19e4323601278b748dc2984798f265c37cd37bb84e6c88ab8","3525647a73ae2124fa8f353f0a078b44ff1ee6f82958c2bb507de61575f12fff","d7238315cbd18ebeed93f41ad756a0ed9759824b9b158c3d7a1e0b71682d8966","eeba7376ce9721610d3282a4159f3c60154b7b3877fb251f7b3211b085cfdc18","54b0cc65b2e86cc59adf157b32b4fde2143ac2ed733f91a26f06c90d93ed9fe6","788c870cac6b39980a5cc41bf610b1873952ecdd339b781f0687d42682ffc5dc","d51a2e050c8a131b13ec9330a0869e5ac75b9ac4ebde52d5f474e819510b5263","3544b854dccadff219b992b2e5dadfbd7a8e0b9815d6d56006775a17e6500568","6c034655fa83236bd779cacfc1d5b469d6e2150a1993e66ecca92376a8b2c6a7","6bd6933efe9d6263d9f1a534a28a8f88b1e4c331b95d85d39350cf02eca8dce0","658cf468a05b2b591fcd5455a76d9927face59ac4a21b4965982b3c234f5d289","6bf893d1b824bde22ee5880c0c760c1dd0a5163c38d22311441a3341b6965d2d","18006f71012652a98486900031259844ab599473acd3ea89052d9276f27e7c0f","4fed67df4d254bc1196516fd0858e2be233d13a96b8cda58b1e9c9aabf2b74a4","28b415e70f9da0346545b7d2bcf361844a8e5778bd6b45bc1a2859f99700ff5b","a905f2f6785e3971bd97c42191394209d97f2aefb11841f7353dd9789821fa8c","e099c5ebddf80ae7285d380c7dd3b5d49c1347346ced51ae121b846833a8d102","aec91730b9f4d83758b4a45596317d34d6ecdbe9330a44629f53af47641b96ee","0ec0a1138652e89501946ebe3ec376fb0228fd637262a9c2b3a01746cc5a0b58","a096ec0badb5f63acd58ab838159b70e5e5e6351cbfa91cc4272bb81325539b8","738ddac5ab5b61d70d3466f3906d6b3c83c8786e922c6e726a6597296181ae87","90d202ace592f7b51b131a5890ec93e4df774c8677a485391c280cef0ea53f48","b34e1861949a545916696ef40f4a7fe71793661e72dd4db5e04cacc60ef23f7a","f27936f9aaf66c489f785928b887c4ac53d056b9b4ce12b4471d530bc4f2b7a6","a3ee2eb87d12e95e37defeffbe209e0901190a82f234cafd67de3d2e2a08eb4a","5c60d93010bd9b998fa8ba50e1f9914458643b3756edbdc5fa8ff53d2e6762db","69dd38e25b0a8ecd40638fadcb47935834a02b2b631bc4811484ef9fa4a7c83b","fdabf0c2593658f129c87c8052c5f8bff9a959f8dd2c5b6522ff3d10f64ad9d5","7ed8c65a78b5116d015b22bcac6a413f8c60edf5396cff3d474b5065a10720a2","d2ff82b084732349284d12417b09d44c35f86b01302c13acb618628c0ff88a79","21f253f734e5e4a615203036822a5d497965415d4940f2a66abe76d3def3713c","74ffa4541a56571f379060acaf9ab86da6c889dfe1f588425807e0117e62bba5","cf4dc15ca9dc6c0995dd2a9264e5ec37d09d9d551c85f395034e812abdf60a99","73e8b003f39c7ce46d2811749dab1dd1b309235fd5c277bd672c30a98b5cf90f","4cb49e79595c6413fcb01af55a8a574705bf385bd2ec5cf8b777778952e2914a","d6b44382b2670f38c8473e7c16b6e8a9bfa546b396b920afc4c53410eeb22abf","3b5c6f451b7ad87e3fcd2008d3a6cb69bd33803e541e9c0fe35754201389158f","8329556a2e85e3c3ff3dff43141790ff624b0f5138cedec5bb793164cf8b088f","e38609d74a50114800997624542cb06e4248426086e5d383f0de91c1718dc2fc","77cedad06715a4f0c60f0d26f3ee579df36a4187824c88053fc21350cd625df4","7232467057ec57666b884924f84fd21cd3a79cc826430c312e61a5bc5758f879","77c4c9f71f3736ed179043a72c4fad9832023855804fbe5261a956428b26a7a6","f5aa57712223d7438799be67b0c4a0e5ac3841f6397b5e692673944374f58a83","774c37f8faed74c238915868ccc36d0afedfbafb1d2329d6a230966457f57cbd","bc41b711477270e8d6f1110d57863284d084b089a22592c7c09df8d4cc3d1d20","ff405ec0cc453987823304b18b82dbe3e68e6f8bd2e56f5041c41effcc4ce717","228ed3721f42cc25bfebceef33754ce4766414d975ff71d012f01f141dbe3549","08985cdb65bbfe3c70d0037794a3d0f0a5613f55c278c77277a7acc17205db57","a32bef91fa483b905391e5d37ef9e1ae9be3355ba73f8c9e14c0a9066593bf12","22f4d25a372f587dc27e0169ff1b4aa9780d979c6101f91f2ae77f5be20e4c4c","c86fea295c21ea01c93410eba2ec6e4f918b97d0c3bf9f1bb1960eabe417e7eb","05d41b3e7789381ff4d7f06d8739bf54cc8e75b835cb28f22e59c1d212e48ff3","6fbcfc270125b77808679b682663c7c6ad36518f5a528c5f7258bcd635096770","9d3bd4ee558de42e9d8434f7293b404c4b7a09b344e77c36bbe959696328d594","f63be9b46a22ee5894316cf71a4ba7581809dd98cf046109060a1214ee9e2977","dd3cc41b5764c9435b7cae3cc830be4ee6071f41a607188e43aa1edeba4fbb3e","b2dbb9485701a1d8250d9a35b74afd41b9a403c32484ed40ed195e8aa369ae70","5aa7565991c306061181bd0148c458bcce3472d912e2af6a98a0a54904cd84fc","9629e70ae80485928a562adb978890c53c7be47c3b3624dbb82641e1da48fd2f","c33d86e1d4753d035c4ea8d0fdb2377043bc894e4227be3ceabc8e6a5411ab2e","f9ec74382c95cbc85804daf0e9dabed56511a6dfb72f8a2868aa46a0b9b5eafc","be32c0a0576265a4dee467f328c5945805a832e6268d312ed768cae1f2666fa6","af9692ce3b9db8b94dcfbaa672cb6a87472f8c909b83b5aeea043d6e53e8b107","782f2628a998fd03f4ccbe9884da532b8c9be645077556e235149ca9e6bd8c7d","269b7db8b769d5677f8d5d219e74ea2390b72ea2c65676b307e172e8f605a74a","ae731d469fae328ba73d6928e4466b72e3966f92f14cd1a711f9a489c6f93839","90878ed33999d4ff8da72bd2ca3efb1cde76d81940767adc8c229a70eb9332b2","d7236656e70e3a7005dba52aa27b2c989ba676aff1cab0863795ac6185f8d54f","e327901e9f31d1ad13928a95d95604ee4917d72ad96092da65612879d89aba42","868914e3630910e58d4ad917f44b045d05303adc113931e4b197357f59c3e93e","7d59adb080be18e595f1ce421fc50facd0073672b8e67abac5665ba7376b29b9","275344839c4df9f991bcf5d99c98d61ef3ce3425421e63eeb4641f544cb76e25","c4f1cc0bd56665694e010a6096a1d31b689fa33a4dd2e3aa591c4e343dd5181c","81c3d9b4d90902aa6b3cbd22e4d956b6eb5c46c4ea2d42c8ff63201c3e9676da","5bfc3a4bd84a6f4b992b3d285193a8140c80bbb49d50a98c4f28ad14d10e0acc","a7cf6a2391061ca613649bc3497596f96c1e933f7b166fa9b6856022b68783ab","864c844c424536df0f6f745101d90d69dd14b36aa8bd6dde11268bb91e7de88e","c74a70a215bbd8b763610f195459193ab05c877b3654e74f6c8881848b9ddb7f","3fa94513af13055cd79ea0b70078521e4484e576f8973e0712db9aab2f5dd436","48ffc1a6b67d61110c44d786d520a0cba81bb89667c7cdc35d4157263bfb7175","7cb4007e1e7b6192af196dc1dacd29a0c3adc44df23190752bef6cbbc94b5e0b","3d409649b4e73004b7561219ce791874818239913cac47accc083fad58f4f985","051908114dee3ca6d0250aacb0a4a201e60f458085177d5eda1fc3cde2e570f3","3744239074f9d681192bc60dea91e30360e28c96207f53d2e80d64956ac8e63a","d82609394127fb33eed0b58e33f8a0f55b62b21c2b6c10f1d7348b4781e392cb","b0f8a6436fbaf3fb7b707e2551b3029650bfaeb51d4b98e089e9a104d5b559b5","eae0ac4f87d56dcf9fbcf9314540cc1447e7a206eee8371b44afa3e2911e520c","b585e7131070c77b28cc682f9b1be6710e5506c196a4b6b94c3028eb865de4a7","b92ac4cc40d551450a87f9154a8d088e31cff02c36e81db2976d9ff070ba9929","6f99b4a552fbdc6afd36d695201712901d9b3f009e340db8b8d1d3415f2776f5","43700e8832b12f82e6f519b56fae2695e93bb18dddb485ddea6583a0d1482992","e8165ea64af5de7f400d851aeea5703a3b8ac021c08bebc958859d341fa53387","6db546ea3ced87efda943e6016c2a748e150941a0704af013dfe535936e820e1","f521c4293b6d8f097e885be50c2fef97de3dd512ad26f978360bb70c766e7eae","a0666dfd499f319cc51a1e6d9722ed9c830b040801427bbdd2984b73f98d292a","a7d86611d7882643dd8c529d56d2e2b698afd3a13a5adc2d9e8157b57927c0da","7e4615c366c93399f288c7bfbaa00a1dc123578be9d8ac96b15d489efc3f4851","f2e6c87a2c322ee1473cb0bd776eb20ee7bff041bc56619e5d245134ab73e83d","ee89bc94431b2dfaf6a7e690f8d9a5473b9d61de4ddcb637217d11229fe5b69f","a19c1014936f60281156dd4798395ad4ab26b7578b5a6a062b344a3e924a4333","5608be84dd2ca55fc6d9b6da43f67194182f40af00291198b6487229403a98fe","4a800f1d740379122c473c18343058f4bd63c3dffdef4d0edba668caa9c75f54","8e6868a58ca21e92e09017440fdb42ebfe78361803be2c1e7f49883b7113fdc2","2fbb72a22faefa3c9ae0dfb2a7e83d7b3d82ec625a74a8800a9da973511b0672","3e8c1a811bad9e5cd313c3d90c39a99867befa746098cdad81a9578ac3392541","d88f78b4e272864f414d98e5ed0996cd09f7a3bb01c5b7528320386f7383153d","0b9c34da2c6f0170e6a357112b91f2351712c5a537b76e42adfee9a91308b122","47adac87ec85a52ed2562cb4a3b441383551727ed802e471aa05c12e7cc7e27e","d1cacf181763c5d0960986f6d0abd1a36fc58fc06a707c9f5060b6b5526179ca","92610d503212366ff87801c2b9dc2d1bccfa427f175261a5c11331bc3588bb3f","805e2737ce5d94d7da549ed51dfa2e27c2f06114b19573687e9bde355a20f0ff","77fece0e88132fb5383810d303de6152ea8f2ff1ed2cd4ac1abd69a7fc570cc5","a37b576e17cf09938090a0e7feaec52d5091a1d2bbd73d7335d350e5f0e8be95","98971aa63683469692fef990fcba8b7ba3bae3077de26ac4be3e1545d09874b8","c6d36fa611917b6177e9c103a2719a61421044fb81cdd0accd19eba08d1b54de","77081112c1ca3ad1670df79cdfd28a1f2fd6334a593623aaf7268c353798e5c3","5eb39c56462b29c90cb373676a9a9a179f348a8684b85990367b3bbc6be5a6e9","d77a02413f5b0f845a39546255af68ab04c906b07c5f3385f9b6fb64fb75d5f1","731d07940d9b4313122e6cc58829ea57dcc5748003df9a0cad7eb444b0644685","b3ead4874138ce39966238b97f758fdb06f56a14df3f5e538d77596195ece0b5","032b40b5529f2ecce0524974dbec04e9c674278ae39760b2ee0d7fce1bb0b165","c25736b0cb086cd2afa4206c11959cb8141cea9700f95a766ad37c2712b7772b","033c269cd9631b3f56bb69a9f912c1f0d6f83cf2cff4d436ee1c98f6e655e3b5","bd6d692a4a950abbfabe29131420abe804e7f3cc187c3c451f9811e9cf4408ce","a9b6411417d4bffd9a89c41dc9dedda7d39fb4fa378eaa0ab55ec9ea1a94eb6a","1329e7cd7aca4d223ef5a088d82bc3f6f302ce70581c8d3823a050ea155eec3b","09248c76437c5b1efce189b4050c398f76a9385135af75c5fb46308b0d1432e0","b8df115bf7b30cceeb4550c0be507082b9930ee6268539a1a1aaffb0791cc299","dde00f41a2d2b1e70df6df8ac33de7cb3a658956212c7bee326245cc01c990c2","115d092e2748990ff0f67f376f47e9a45a2f21f7c7784102419c14b32c4362d1","bad694fd79dc34f31d401f890c05f5423232bff88f2c3aa8b14eb6c809d7eeda","5cd5a999e218c635ea6c3e0d64da34a0f112757e793f29bc097fd18b5267f427","cc14b99b4e1bbedab2e3fbf058ed95231d8ced691f0645f2a206c32464f1bd7b","e6db934da4b03c1f4f1da6f4165a981ec004e9e7d956c585775326b392d4d886","53e65282ab040a9f535f4ad2e3c8d8346034d8d69941370886d17055874b348d","6ecb85c8cbb289fe72e1d302684e659cc01ef76ae8e0ad01e8b2203706af1d56","35ab64ba795a16668247552da22f2efe1c5fbc5bc775392c534747be7f91df04","34283015304de5df8d6e3740b9bca58e40513ec6333b3fb0a3fa3aa4c43b856b","4a397c8a3d1cccf28751bcca469d57faeb637e76b74f6826e76ad66a3c57c7b8","34c1bb0d4cf216f2acb3d013ad2c79f906fe89ce829e23a899029dfa738f97e0","b70b5b3d14d125d6dcc16a9ac43cafe8801f644954ac36cb2918723f9cbbd4fe","b50f05738b1e82cbb7318eb35a7aaf25036f5585b75bbf4377cfa2bad15c40bf","c682cb23f38a786bb37901b3f64727bd3c6210292f5bb36f3b11b63fbe2b23ee","d6592cf10dc7797d138af32800d53ff4707fdcd6e053812ce701404f5f533351","997f6604cd3d35281083706aa2862e8181ed1929a6cbb004c087557d6c7f23c4","9584dd669a3bf285e079502ebbb683e7da0bf7f7c1eb3d63f6ef929350667541","41a10e2db052a8bf53ed4d933d9b4f5caa30bdaee5a9d978af95f6641ce44860","1dd236a02d5974092780f456750107a3158124002de00ca17342f3a4819e297b","652e51858bafd77e1abcc4d4e9d5e48cc4426c3dd2910021abd8cc664961e135","8c5c602045ffdfebeffc7a71cd2bf201fe147a371274b5fcbded765a92f2af78","6392ce794eef6f9b57818264bb0eeb24a46cf923f7695a957c15d3d087fbb6cc","b10f123e8100aa98723c133af16f1226a6360ec5b6990a0fe82b165d289549db","93d20368cdb5fff7f7398bfc9b2b474b2a2d5867277a0631a33b7db7fd53d5b4","b1e69b9834104482fabf7fba40e86a282ee10e0600ffd75123622f4610b0ef9e","ad5bb6c450cb574289db945ff82be103ed5d0ad8ee8c76164cee7999c695ae01","217761e8a5482b3ad20588a801521c2f5f9f7fb2fbb416d4eff3aff9b57f8471","7ad780687331f05998c62277d73b6f15ee3e8045b0187a515ffc49c0ad993606","e9aa5ccb42e118f5418721d2ac8c0ebdebeb9502007db9b4c1b7c9b8d493013e","d300868212b3cc4d13228f5dc2e9880d5959dc742c0c55be2fc43bcda8504c8f","0c55daad827669843bd2401f1ddd163b74d9f922680b08ae6e162ceb6c11b078","fe45a9bc654dfd1550c9466c0dad9c8017f2626476ed9d25c65ddfc1943f6b74","03abcbc7b5b68887525be71a194dd7f9f68276b5fb5b8989abae9a91585ddc33","5055e86e689cfe39104ab71298757e5aac839c2ea9d1f12299e76fa79303d47d","42266c387025558423c19d624f671352aac3e449c23906cb636f9ae317b72d7e","b8263f60855a11e955b7a229dd3554b9df204e03ce3f221079687a242545050b","af1af59e70d7cd03669420193574e8b8d2667213e1c874f17fcbf78e3e96d185","9b21e8a79f4213c1cf29f3c408f85a622f9eb6f4902549ccb9a2c00717a0b220","d556e498591413e254793f9d64d3108b369a97bd50f9dd4015b5552888e975ef","e2c652c7a45072e408c1749908ca39528d3a9a0eb6634a8999b8cf0e35ef20c8","ec08224b320739d26aaf61cead7f1e0f82e6581df0216f6fe048aa6f5042cb8c","4eadaa271acca9bd20fc6ac1ea5e4bf9ab6698b8ccf3ec07c33df4970f8130f1","3a0a397189726902c046697f7bf38fecb557a79d5a644aac9ec983024b4c3d17","46f1df33bc635aa84313579ff51a7269707b58a8a32728e4e5fc7ab47816b44a","5ecd8fdeb6c87db9c320eefbfa9ea27efccbdce853ed38d5ba58e2da482edf1f","19a4d116285e7d77e91411966930761a2204ce2d20915afdb12652681a4a88d7","c30ca82112586c5dae7477d7e82cc91a7e0d1e658c581f9ec3df07c4485bba84","68fca1813d17ee736f41124ccc958d0364cdef79ad1222951bfacc36b2630a58","7813329e568df1d42e5a6c52312b1a7c69700e35a561cf085158c345be155b22","561067dc7b6b7635277d3cad0a0e11f698d377063dd2c15dfac43ef78847eef4","438247e782a8a9b9abdce618e963667cf95157cc6d3f5194a452d3c7d9e9655c","253f79802f33f405c1807f33efa7d78e0a26143ee694297d4f8e1477c7ed5e28","f1e8eca509487806fdf979349cfcdb6ffdeb20f11b7e95666c4309d12dcd9ba6","83724b26b711d85d6cfc9dd92fd5d666ffaae27fcfb1a0110401b98814ea26c0","869a27c929366c3c864013a991fd4c4c86af73eba25513e8ae915f814d3d349c","756e3f41a7f2501a34e1a070283c7f5550e200eeb43fed3c806e3f2edd924a75","59935cc13dcb7c3c7825e770a61e6696bfd11b65e3e47c28acc410dbdf8461c0","85e2808cc73ab3ac07774802b34a6ff0d7e1e46c26de7bc2dbe08e04b3340edb","f766e5cdea938e0c9d214533fd4501ab0ee23ab4efca9edba334fa02d2869f11","eb380820a3a1feda3a182a3d078da18e0d5b7da08ae531ce11133a84b479678c","7fba5cc3088ad9acada3daeff52dae0f2cac8d84d19508abd78af5924dc96bea","14176cfdbc3d1d633ad9b5daf044ab4c7d0d73be61ca2f14388800e21f0989cd","648acdbcbcd01b1a91e8b0ad390ed59fada685977f44b90e148b65bd8159dfe8","8309898ba0ac6f2856a94a11723d499091253a6d5df34ddebc6149d43480bfd2","a317ae0eb092da3fd799d1717a2da319a74abebe85e2914cb259222969f95705","36d76e2dbd5f5243bd566b018c589e2ba707e34b24ec7d285feb11ba6bf23fbe","f780879a2ca63dbb59b36f772bc28dccd2840f1377d8d632e8c978b99c26a45f","335c2e013b572967a9a282a70f9dded38631189b992381f1df50e966c7f315d6","8b7a519edbd0b7654491300d8e3cbd2cb3ef921003569ca39ebd33e77479bb99","c90f8038c75600e55db93d97bab73c0ab8fb618d75392d1d1ad32e2f6e9c7908","ca083f3bf68e813b5bded56ecbf177636aa75833eb86c7b40e3d75b8ce4c2f78","3c8bf00283ef468da8389119d3f5662c81106e302c8810f40ea86b1018df647e","67b248e4bac845c5139898b44cbd3e1213674bcc9831039701b5f0f957243a24","63d49516f359186f7b3e3115f2c829ed75c319b34022c97b56beead032a073b7","9f5f256c7b5cc4a98ef557ea9720f81e96319d569f731c897ddb4514936242b4","a20ded6c920f6e566537e93d69cbad79bc57d7e3ce85686003078cf88c1c9cfc","40b2d781df7b4a76d33454cb917c3883655ec1d8d05424b7a80d01610ad5082f","703ea2acd8b4741248897a5709cd46e22fcd9d13f01ff3481322a86505f0b77c","e09c56f8c446225e061b53cb2f95fcbbc8555483ab29165f6b0f39bc82c8d773","51ebaff0cba6b3adf43f13b57bb731d56946cabd06d14cf9dfc7c5eaa8f95770","d5cb1de6b2e971bd60a936d95a0e0f99803b248c7dde1091cd9d21f992931543","6e2533e27eba5ff02d6eed37e0a7eb69ae7982e0f72fd8f74c90ab201f061867","58c62e415bf74b1423bf443587e33d7951a8bf19d7b03073f26e86d9b43ba9ea","dd6ec67ad168e92b8bf79ba975c6e0be8c60e403ba704d1c1b31a6059c12f967","bcaf468eea143f8e68ca40e5da58d640656b4f36697170c339042500be78ac5d","92de961d1db5fe075db8c0b6414a6eec430adaf9022465fe9d0a23f437aafcb3","ab8424a42a580a76317f4020d047f1732424066e22d198c47735b13727790cb1","7355edff7686f91edbca25e0fe9d6c3359df2520d48d3dc6d857aa47047f8ddf","9a4e56ec89f4716609ca2cb5b92798adbdbabd7167e2738f85597685d8211964","b25556c4111afad4cb174aa4674db2e5b23a6b191dc6a3e42c7c3417ea446a68","f9568a3a6c74013aee8b09d73ef04175596b51ce6f5d9dcd4885418170fe9306","bd3910ccd4fcd05ebd83fbfeb62f5a82a6674c85c6c0e4755c16298df7abe4d7","2bfad224656e6eea9e6e59683cd0b8468f557969dd3d3acdcaaf47ee3d295604","70137204b720e4dd1b81260a70578f0f4f417c53837f8a13859b2f58e20d7150","b28b6875a761fd153ebf120fecb359660de80fd36e90c9b3d72a12318bd5d789","65cb25590953015354787742ef5b08b24d9cb7a8bf13df3e72adec7b3d770099","a4709d5d466ad8dcf4ddccb905ad95348131df1616f964185be9739f96526bde","73b0fd6255f24e82be861f800a264f0175984062b6ccca3052578b03ed6f397b","4a3f7c6f02cb01eb7a9800548b41cfa03a57e476fc92a72869983f37efa8067a","a640f7a6345f4dec86a07f53ae796ba2afa0f48c2acac68232f0915f074a1593",{"version":"aeefe017b71a6509dc5609cf6908c7c277f6e46d03b6f61e52a853010d79ce65","signature":"06596257cfe528fe74bbc95af35bdbf20dfbbf570a9361794e6a0d0648dfb274"},{"version":"da19256f818459a100be5c730c834ff48bd9a6c1d97a62b1aed801809da81846","signature":"f33cd44d93a4dea30c8eeec6aa9db72cbe175d9d8fc450fef31d2308dab717f1"},{"version":"1ac06e3473cf88827d6d071f4c5a1271e069a36168c568324593bfe5773d5771","signature":"976351801a39130d5dad2b86c18afd580f828ceab54fe754bcc90d96a1571bf9"},{"version":"d039307e4c2aa151e7aa6737f06932c7acfd02353018d68dfb9863598362b303","signature":"880e0f493bbd14466c51606f2f0b36398bd62ee3b04dace8c253a762997270c3"},{"version":"93824dc6338c57e09e2ff4ce4ed164019de60aec2f845fd10c478122e9fbcbd9","signature":"37e1ec415e868b7cced2130eaf7a64b16a3ac5279e50cba09fd6de54f29b4835"},{"version":"f552898cea3c003539f670f31e9a763402dd5503dea4083e29096cb1ea139049","signature":"0a09318879610ef741cf22b30e4b3c7c342eb65de80c83644ba7f39720f4cf2d"},{"version":"e5a065221d29bc22b6ddcb29da8a108cc1331a332952a9772f70fbde47ec07d8","signature":"1a5561ad0a120ab21aeabcd99ee993b1676acbb0887e96d04c40eb5cf3655f49"},"87f287f296f3ff07dbd14ea7853c2400d995dccd7bd83206196d6c0974774e96","78ef0198c323d0f7b16f993ada3459f0e7e20567e7f56fe0c5ee78f31cb0840c","88533ff507514078998ea6e02390b4a7934bcff52fe9b8389e06037af8619cb2","6d1675231de1aa366144f91852cddb2eb3cad8d9f2e7e48f4e5e0031e7046ddc","b788ef070e70003842cbd03c3e04f87d46b67a47b71e9e7d8713fd8c58c5f5ec","583d365dc19f813f1e2767771e844c7c4ea9ab1a01e85e0119f2e083488379c2","16ab5b20dbc2b0860c3c59941570e616f8a6fc31a689fdc8c1b984b96dcd11af","591e8b31c7c740e1635c246e08b54fd3e66f20de99188f7b3f0c03e72ac9204e","58c7f7820dc027a539b0437be7e1f8bdf663f91fbc9e861d80bb9368a38d4a94","f8e6a8fa14ad7cfab128f9922505b57fb4fbd82828047c46d7137c066c9bff21","57ab70cf1fcc245d66577501f0846fae49a953c92f004e7927e5ea7bb57c6a68","bbc49fd9dc6ee162ba3d270c834398e0c1d44e657ac4edfa55ac837902b7e0da","6993f360de4984b6743764fad3b88246d5dc6cfa45567783fc23833ad4e50c13","715682cddbefe50e27e5e7896acf4af0ffc48f9e18f64b0a0c2f8041e3ea869b","6d2f5a67bfe2034aa77b38f10977a57e762fd64e53c14372bcc5f1d3175ca322","4ff4add7b8cf26df217f2c883292778205847aefb0fd2aee64f5a229d0ffd399","33859aa36b264dd91bef77c279a5a0d259c6b63684d0c6ad538e515c69a489ec","33fa69f400b34c83e541dd5f4474f1c6fb2788614a1790c6c7b346b5c7eaa7dd","be213d7cbc3e5982b22df412cf223c2ac9d841c75014eae4c263761cd9d5e4c0","66451f9540fdf68a5fd93898257ccd7428cf7e49029f2e71b8ce70c8d927b87a","8a051690018330af516fd9ea42b460d603f0839f44d3946ebb4b551fe3bc7703","301fb04ef91ae1340bec1ebc3acdd223861c887a4a1127303d8eef7638b2d893","06236dfec90a14b0c3db8249831069ea3f90b004d73d496a559a4466e5a344a4","fc26991e51514bfc82e0f20c25132268b1d41e8928552dbaed7cc6f3d08fc3ac","5d82bb58dec5014c02aaeb3da465d34f4b7d5c724afea07559e3dfca6d8da5bc","44448f58f4d731dc28a02b5987ab6f20b9f77ad407dcf57b68c853fe52195cd7","b2818e8d05d6e6ad0f1899abf90a70309240a15153ea4b8d5e0c151e117b7338","1c708c15bb96473ce8ec2a946bd024ecded341169a0b84846931f979172244ba","ba1b8e276abe5519e0ba134fd0afba6668ba26d8d5a1fb359d88aff6357457c2","dc187f457333356ddc1ab8ec7833cd836f85e0bbcade61290dc55116244867cb","25525e173de74143042e824eaa786fa18c6b19e9dafb64da71a5faacc5bd2a5c","7a3d649f2de01db4b316cf4a0ce5d96832ee83641f1dc84d3e9981accf29c3a1","26e4260ee185d4af23484d8c11ef422807fb8f51d33aa68d83fab72eb568f228","c4d52d78e3fb4f66735d81663e351cf56037270ed7d00a9b787e35c1fc7183ce","b6c29a4a451678dee9f8682301a6064138a2a592a8ce39d6d86ca350b55ae24e","54bcb32ab0c7c72b61becd622499a0ae1c309af381801a30878667e21cba85bb","5d5f0cd1779e9c268860400922a943c305c7c094d88dc2b426e520500a2623e0","28439c9ebd31185ae3353dd8524115eaf595375cd94ca157eefcf1280920436a","13fbfe7b7c149df1280ca6abb06ad98a63aae3f80fc5f7dab60344071c9af398","66738976a7aa2d5fb2770a1b689f8bc643af958f836b7bc08e412d4092de3ab9","f6c226d8222108b3485eb0745e8b0ee48b0b901952660db20e983741e8852654","0f5e35d119da74f6591b902d34dff887589666746ac80cc3909d8b613f54073c","0146912d3cad82e53f779a0b7663f181824bba60e32715adb0e9bd02c560b8c6","b515457bebb2ad795d748d1c30d9d093a1364946379baf1fbb6f83fd17523ed5","220783c7ca903c6ce296b210fae5d7e5c5cc1942c5a469b23d537f0fbd37eb18","0974c67cf3e2d539d0046c84a5e816e235b81c8516b242ece2ed1bdbb5dbd3d6","b4186237e7787a397b6c5ae64e155e70ac2a43fdd13ff24dfb6c1e3d2f930570","2647784fffa95a08af418c179b7b75cf1d20c3d32ed71418f0a13259bf505c54","0480102d1a385b96c05316b10de45c3958512bb9e834dbecbbde9cc9c0b22db3","eea44cfed69c9b38cc6366bd149a5cfa186776ca2a9fb87a3746e33b7e4f5e74","7f375e5ef1deb2c2357cba319b51a8872063d093cab750675ac2eb1cef77bee9","b7f06aec971823244f909996a30ef2bbeae69a31c40b0b208d0dfd86a8c16d4f","0421510c9570dfae34b3911e1691f606811818df00354df7abd028cee454979f","3edc716bccdc88ed1ed8f05d92640698299565de4f9422109bc328fc233abfc8","f4889d8aeb1604d17b067ca2c3d1be751961452ea5e1cc46cc89a338ef3029b6","f9d42875a91472253f10659ab6124fb94511e5faa8b6d95bc450712db20a420a","0504070e7eaba788f5d0d5926782ed177f1db01cee28363c488fae94950c0bbc","6847334317c1bc1e6fc4b679b0095bbd2b6ee3b85fe3f26fc26bac462f68ef5e","2125380d127f602090671355ecc9f021caf3af71b79c7c9fbc8cfd9cfec45b10",{"version":"64d4b35c5456adf258d2cf56c341e203a073253f229ef3208fc0d5020253b241","affectsGlobalScope":true},"ee7d8894904b465b072be0d2e4b45cf6b887cdba16a467645c4e200982ece7ea","f3d8c757e148ad968f0d98697987db363070abada5f503da3c06aefd9d4248c1","4fe9991629a58a54c551309b080498b7a9e2a11195e83a6e5bf308ea1d286420","1f68ab0e055994eb337b67aa87d2a15e0200951e9664959b3866ee6f6b11a0fe","7cc39a5732dd9a5efb00d49aa3dc600ebe2f1693c4d7bbc9cc3d6f4c415a5377","ff281735449be3e11b6297b79b2806b054e8e8aabbd19464c5e7bd0c8646d7f7","219a526112fedefed96c72b17e805cab7c07297ecd59acd11e054c2bf96f9293","b589f9ee1a8f0c277957ab3ca973e6a04bdca979ad71e4ba0ef8477adb83f9aa","f6175a5c362acd3e46b12ec6b8164e6a28d7f8c0dbb9d199b0a09014989f262e","6a9d3a15e3f0679a1552e5b0f7fae3361536d5eac476b29f3d0b65dd2c672621","a73051918bd9cef5a4ad258bf2eead5dd3b1cde95bb6b11935970f687628c44e","d8c31ee1c0e1ba3a1fbad968941f5c733cdd530344c9336926d3cae45b747d89","3f841292a135503a4cc1a9029af59dae135595810cfad5ca62ec1b2ad9846e8e","be00321090ed100e3bd1e566c0408004137e73feb19d6380eba57d68519ff6c5","96d14f21b7652903852eef49379d04dbda28c16ed36468f8c9fa08f7c14c9538","7e8d3f08435ad2cefe67f58182618bfc9a0a29db08cf2544b94cbcae754a9bd9","c39e1ee964fa0bb318ee2db72c430b3aede3b50dbde414b03b4e43915f80c292","41ab75ee7cef1e86c663595cfac0e1d2d092cc6b6d18e6fd9fc19f993371d29b","8ea84a2aeaa6e3f0ee7536f290f21aa0516b1beeb8afd9a345746c202d4fecd5","96c20da97c904138c80c9838a00f48f0b6b4f610b676d31e1a11becb79d75e60","17668c1aab598920796050ee5a00d961ede5e92595f6ac8908a975ed75a537e5","f60e3e3060207ac982da13363181fd7ee4beecc19a7c569f0d6bb034331066c2","17230b34bb564a3a2e36f9d3985372ccab4ad1722df2c43f7c5c2b553f68e5db","87ed0f84f0691d5c724b23159db96342e6b04ac69201b02c65936f4281ce1fbe","13868c5792808236b17dfe2803eafce911ea4d09d3b2fda95391891a494f988f","0dfe35191a04e8f9dc7caeb9f52f2ee07402736563d12cbccd15fb5f31ac877f","fd29886b17d20dc9a8145d3476309ac313de0ee3fe57db4ad88de91de1882fd8","8d9d40cbfd510ac16d39ab40eadca2c63a240b5ab38b0c6de2df6bf507a3194d","5b5337f28573ffdbc95c3653c4a7961d0f02fdf4788888253bf74a3b5a05443e","9871b7ee672bc16c78833bdab3052615834b08375cb144e4d2cba74473f4a589","c863198dae89420f3c552b5a03da6ed6d0acfa3807a64772b895db624b0de707","8b03a5e327d7db67112ebbc93b4f744133eda2c1743dbb0a990c61a8007823ef","86c73f2ee1752bac8eeeece234fd05dfcf0637a4fbd8032e4f5f43102faa8eec","42fad1f540271e35ca37cecda12c4ce2eef27f0f5cf0f8dd761d723c744d3159","ff3743a5de32bee10906aff63d1de726f6a7fd6ee2da4b8229054dfa69de2c34","83acd370f7f84f203e71ebba33ba61b7f1291ca027d7f9a662c6307d74e4ac22","1445cec898f90bdd18b2949b9590b3c012f5b7e1804e6e329fb0fe053946d5ec","0e5318ec2275d8da858b541920d9306650ae6ac8012f0e872fe66eb50321a669","cf530297c3fb3a92ec9591dd4fa229d58b5981e45fe6702a0bd2bea53a5e59be","c1f6f7d08d42148ddfe164d36d7aba91f467dbcb3caa715966ff95f55048b3a4","f4e9bf9103191ef3b3612d3ec0044ca4044ca5be27711fe648ada06fad4bcc85","0c1ee27b8f6a00097c2d6d91a21ee4d096ab52c1e28350f6362542b55380059a","7677d5b0db9e020d3017720f853ba18f415219fb3a9597343b1b1012cfd699f7","bc1c6bc119c1784b1a2be6d9c47addec0d83ef0d52c8fbe1f14a51b4dfffc675","52cf2ce99c2a23de70225e252e9822a22b4e0adb82643ab0b710858810e00bf1","770625067bb27a20b9826255a8d47b6b5b0a2d3dfcbd21f89904c731f671ba77","d1ed6765f4d7906a05968fb5cd6d1db8afa14dbe512a4884e8ea5c0f5e142c80","799c0f1b07c092626cf1efd71d459997635911bb5f7fc1196efe449bba87e965","2a184e4462b9914a30b1b5c41cf80c6d3428f17b20d3afb711fff3f0644001fd","9eabde32a3aa5d80de34af2c2206cdc3ee094c6504a8d0c2d6d20c7c179503cc","397c8051b6cfcb48aa22656f0faca2553c5f56187262135162ee79d2b2f6c966","a8ead142e0c87dcd5dc130eba1f8eeed506b08952d905c47621dc2f583b1bff9","a02f10ea5f73130efca046429254a4e3c06b5475baecc8f7b99a0014731be8b3","c2576a4083232b0e2d9bd06875dd43d371dee2e090325a9eac0133fd5650c1cb","4c9a0564bb317349de6a24eb4efea8bb79898fa72ad63a1809165f5bd42970dd","f40ac11d8859092d20f953aae14ba967282c3bb056431a37fced1866ec7a2681","cc11e9e79d4746cc59e0e17473a59d6f104692fd0eeea1bdb2e206eabed83b03","b444a410d34fb5e98aa5ee2b381362044f4884652e8bc8a11c8fe14bbd85518e","c35808c1f5e16d2c571aa65067e3cb95afeff843b259ecfa2fc107a9519b5392","14d5dc055143e941c8743c6a21fa459f961cbc3deedf1bfe47b11587ca4b3ef5","a3ad4e1fc542751005267d50a6298e6765928c0c3a8dce1572f2ba6ca518661c","f237e7c97a3a89f4591afd49ecb3bd8d14f51a1c4adc8fcae3430febedff5eb6","3ffdfbec93b7aed71082af62b8c3e0cc71261cc68d796665faa1e91604fbae8f","662201f943ed45b1ad600d03a90dffe20841e725203ced8b708c91fcd7f9379a","c9ef74c64ed051ea5b958621e7fb853fe3b56e8787c1587aefc6ea988b3c7e79","2462ccfac5f3375794b861abaa81da380f1bbd9401de59ffa43119a0b644253d","34baf65cfee92f110d6653322e2120c2d368ee64b3c7981dff08ed105c4f19b0","85f8ebd7f245e8bf29da270e8b53dcdd17528826ffd27176c5fc7e426213ef5a","7abf54763b6709a2b72ecd1247c3cfe96f8c44fe6e7ce3897951ee8f4c394640","c130f9616a960edc892aa0eb7a8a59f33e662c561474ed092c43a955cdb91dab","9eb48a18d9d78d2dc2683bfb79d083954d13cf066d9579cbdb8652b86601fbd7","2f4f96af192dc44a12bf238bcc08ebac498c9073f459740f6497fe0f8e1a432c","c5b3da7e2ecd5968f723282aba49d8d1a2e178d0afe48998dad93f81e2724091","efd2860dc74358ffa01d3de4c8fa2f966ae52c13c12b41ad931c078151b36601","09acacae732e3cc67a6415026cfae979ebe900905500147a629837b790a366b3","72154a9d896b0a0aed69fd2a58aa5aa8ab526078a65ff92f0d3c2237e9992610","99236ea5c4c583082975823fd19bcce6a44963c5c894e20384bc72e7eccf9b03","f6688a02946a3f7490aa9e26d76d1c97a388e42e77388cbab010b69982c86e9e","b027979b9e4e83be23db2d81e01d973b91fefe677feb93823486a83762f65012","346599d03c24e6a35ae9e25b639e63c351dc8c7146019648f0ced0e710924073"],"root":[138,496,[635,638],[641,643],[645,647],891,892,904,908,911,912,[915,918],[1346,1352]],"options":{"allowSyntheticDefaultImports":true,"declaration":true,"emitDecoratorMetadata":true,"esModuleInterop":true,"experimentalDecorators":true,"module":1,"removeComments":true,"sourceMap":true,"target":4},"fileIdsList":[[108,136,137,914],[101,485,495,914],[634,914],[914],[137,485,495,640,641,642,914],[485,495,644,645,646,914],[644,914],[390,914],[485,914],[140,391,392,393,394,395,396,397,398,399,400,401,402,403,914],[343,377,914],[350,914],[340,390,485,914],[408,409,410,411,412,413,414,415,914],[345,914],[390,485,914],[404,407,416,914],[405,406,914],[381,914],[345,346,347,348,914],[418,914],[363,914],[418,419,420,421,422,423,424,425,426,427,428,429,430,431,432,433,434,435,436,437,438,439,914],[446,914],[441,442,914],[116,135,443,445,914],[139,349,390,417,440,445,447,454,477,482,484,914],[145,343,914],[144,914],[145,335,336,547,552,914],[335,343,914],[144,334,914],[343,456,914],[337,458,914],[334,338,914],[144,390,914],[342,343,914],[355,914],[357,358,359,360,361,914],[349,914],[349,350,365,369,914],[363,364,370,371,372,914],[135,914],[141,142,143,144,145,335,336,337,338,339,340,341,342,343,344,350,355,356,362,369,373,374,375,377,385,386,387,388,389,914],[368,914],[351,352,353,354,914],[343,351,352,914],[343,349,350,914],[343,353,914],[343,381,914],[376,378,379,380,381,382,383,384,914],[141,343,914],[377,914],[141,343,376,380,382,914],[352,914],[378,914],[343,377,378,379,914],[367,914],[343,347,367,385,914],[365,366,368,914],[339,341,350,356,365,370,386,387,390,914],[145,339,341,344,386,387,914],[348,914],[334,914],[367,390,448,452,914],[452,453,914],[390,448,914],[390,448,449,914],[449,450,914],[449,450,451,914],[344,914],[469,470,914],[469,914],[470,471,472,473,474,475,914],[468,914],[460,470,914],[470,471,472,473,474,914],[344,469,470,473,914],[455,461,462,463,464,465,466,467,476,914],[344,390,461,914],[344,460,914],[344,460,485,914],[337,343,344,456,457,458,459,460,914],[334,390,456,457,478,914],[390,456,914],[480,914],[417,478,914],[478,479,481,914],[367,444,914],[376,914],[349,390,914],[483,914],[365,369,390,485,914],[516,914],[390,485,536,537,914],[518,914],[485,530,535,536,914],[540,541,914],[145,390,531,536,550,914],[485,517,543,914],[144,485,544,547,914],[390,531,536,538,549,551,555,914],[144,553,554,914],[544,914],[334,390,485,558,914],[390,485,531,536,538,550,914],[557,559,560,914],[390,536,914],[536,914],[390,485,558,914],[144,390,485,914],[390,485,530,531,536,556,558,561,564,569,570,583,584,914],[543,546,585,914],[570,582,914],[139,517,538,539,542,545,577,582,586,589,593,594,595,597,599,605,607,914],[390,485,524,532,535,536,914],[390,528,914],[390,485,518,527,528,529,530,535,536,538,608,914],[530,531,534,536,572,581,914],[390,485,523,535,536,914],[571,914],[485,531,536,914],[485,524,531,535,576,914],[390,485,518,523,535,914],[485,529,530,534,574,578,579,580,914],[485,524,531,532,533,535,536,914],[343,485,914],[390,518,531,534,536,914],[535,914],[520,521,522,531,535,536,575,914],[527,576,587,588,914],[485,518,536,914],[485,518,914],[519,520,521,522,525,527,914],[524,914],[526,527,914],[485,519,520,521,522,525,526,914],[562,563,914],[390,531,536,538,550,914],[573,914],[374,914],[355,390,590,591,914],[592,914],[390,538,914],[390,531,538,914],[368,390,485,524,531,532,533,535,536,914],[365,367,390,485,517,531,538,576,594,914],[368,369,485,516,596,914],[566,567,568,914],[485,565,914],[598,914],[115,135,485,914],[601,603,604,914],[600,914],[602,914],[485,530,535,601,914],[548,914],[390,485,518,531,535,536,538,573,574,576,577,914],[606,914],[485,514,914],[139,485,514,608,609,914],[485,514,610,613,614,616,914],[139,633,914],[618,619,620,621,914],[139,514,914],[139,914],[334,485,514,608,610,611,612,914],[514,515,613,914],[624,625,626,627,628,629,914],[514,515,610,611,612,613,614,617,622,623,630,632,914],[497,914],[485,499,503,510,914],[501,914],[334,501,914],[497,501,914],[497,501,506,914],[497,498,499,500,501,502,503,504,505,506,507,508,509,510,511,512,513,914],[508,914],[334,497,501,914],[631,914],[334,485,514,914],[485,514,530,535,536,615,914],[139,334,485,514,609,914],[609,914],[633,914],[485,894,896,914],[893,896,897,898,900,901,914],[894,895,914],[485,894,914],[899,914],[896,914],[902,914],[836,837,838,914],[835,836,837,838,839,840,841,914],[835,836,914],[835,914],[695,914],[836,837,914],[654,914],[657,914],[662,664,914],[650,654,666,667,914],[677,680,686,688,914],[649,654,914],[648,914],[649,914],[656,914],[659,914],[649,650,651,652,653,654,655,656,657,658,659,660,661,662,663,664,665,666,668,669,670,671,672,673,674,675,676,677,678,679,680,681,682,683,684,685,686,687,689,690,691,692,693,694,914],[665,914],[661,914],[662,914],[653,654,660,914],[661,662,914],[668,914],[689,914],[653,914],[654,671,674,914],[670,914],[671,914],[669,671,914],[654,674,676,677,678,914],[677,678,680,914],[654,669,672,675,682,914],[669,670,914],[651,652,669,671,673,914],[671,674,914],[652,669,672,675,914],[654,674,676,914],[677,678,914],[695,699,914],[699,914],[696,697,698,699,700,701,702,703,704,705,709,715,716,717,718,719,720,721,722,723,724,725,726,727,728,729,730,731,732,914],[703,914],[714,914],[705,914],[706,707,708,710,711,712,713,914],[109,135,914],[709,914],[831,832,914],[733,777,831,914],[781,784,785,914],[783,914],[782,914],[781,914],[733,914],[733,777,781,914],[799,800,914],[800,801,914],[135,695,799,914],[818,819,820,821,914],[495,799,819,914],[695,799,818,914],[101,127,135,813,814,914],[814,815,816,914],[101,103,127,135,695,813,914],[101,127,695,814,914],[808,914],[803,807,808,809,810,811,812,914],[695,803,914],[803,914],[806,914],[805,914],[788,803,804,914],[695,803,807,914],[823,824,914],[799,914],[796,914],[787,795,796,797,798,914],[695,787,794,914],[794,914],[790,791,792,793,914],[787,788,789,914],[791,914],[695,787,795,914],[787,914],[736,914],[734,735,914],[753,914],[734,735,736,914],[747,748,749,750,914],[734,735,736,737,746,751,752,914],[745,914],[734,736,737,914],[738,739,740,741,742,743,744,914],[735,736,914],[695,734,735,914],[834,845,846,849,914],[733,843,849,914],[733,843,914],[695,843,846,914],[695,733,753,842,914],[845,846,849,914],[834,843,845,846,847,848,849,850,851,852,856,914],[753,834,842,846,914],[834,842,846,914],[695,733,753,842,843,844,914],[695,845,914],[855,914],[834,853,914],[854,914],[695,862,863,864,876,914],[695,862,863,864,867,868,876,914],[864,865,866,869,870,871,914],[695,862,863,876,914],[862,873,875,914],[733,862,875,876,877,878,914],[733,862,875,876,878,914],[695,733,753,862,864,875,914],[733,862,873,875,876,914],[876,914],[862,873,875,876,877,879,880,914],[878,879,881,914],[862,863,864,873,874,875,876,877,878,879,881,882,883,884,885,914],[695,874,914],[695,753,874,880,881,914],[695,733,914],[863,864,872,875,914],[859,875,914],[859,914],[858,860,861,873,875,914],[695,733,753,777,780,857,886,888,889,914],[695,753,777,780,857,886,888,914],[695,753,777,813,857,886,914],[695,753,756,759,777,914],[695,756,758,759,761,762,914],[733,758,759,914],[695,758,761,762,914],[695,733,753,757,914],[695,758,759,761,762,914],[733,758,914],[754,755,756,757,758,759,760,761,762,763,768,769,770,771,772,773,774,775,776,914],[767,914],[756,764,914],[765,766,914],[754,914],[755,914],[695,755,914],[695,733,753,757,758,763,914],[695,758,761,914],[695,733,753,756,760,762,914],[695,753,754,755,914],[777,914],[777,778,779,914],[777,778,914],[827,829,914],[828,914],[826,914],[101,135,914],[98,135,909,914],[914,1354,1355,1356,1357,1358,1359,1360,1361,1362,1363,1364,1365,1366,1367,1368,1369,1370,1371,1372,1373,1374,1375,1389,1390,1391,1392,1393,1394,1395,1396,1397,1398,1399,1400,1401,1402,1403,1404,1405,1406],[914,1356],[914,1356,1360],[914,1354,1356,1358],[914,1354,1356],[914,1356,1362],[914,1355,1356],[914,1366],[914,1356,1372,1373,1374],[914,1356,1376],[914,1356,1377,1378,1379,1380,1381,1382,1383,1384,1385,1386,1387,1388],[914,1356,1366],[101,135,493,914],[98,135,914],[101,135,493,495,914,1410],[101,106,116,135,914,919],[98,116,135,914,920],[914,1413,1415],[914,1412,1413,1414],[98,101,135,487,488,489,914],[488,490,492,494,914],[101,103,116,127,133,135,137,914,1417,1418,1419,1421,1422,1423],[914,1420],[101,116,135,914],[98,116,124,135,914],[91,135,914],[914,1429],[98,101,102,106,112,127,135,491,914,1353,1409,1410,1411,1425,1428],[50,914],[85,914],[86,91,119,914],[87,98,99,106,116,127,914],[87,88,98,106,914],[89,128,914],[90,91,99,107,914],[91,116,124,914],[92,94,98,106,914],[93,914],[94,95,914],[98,914],[96,98,914],[85,98,914],[98,99,100,116,127,914],[98,99,100,113,116,119,914],[83,86,132,914],[94,98,101,106,116,127,914],[98,99,101,102,106,116,124,127,914],[101,103,116,124,127,914],[50,51,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,914],[98,104,914],[105,127,132,914],[94,98,106,116,914],[107,914],[108,914],[85,109,914],[110,126,132,914],[111,914],[112,914],[98,113,114,914],[113,115,128,130,914],[86,98,116,117,118,119,914],[86,116,118,914],[116,117,914],[119,914],[120,914],[85,116,914],[98,122,123,914],[122,123,914],[91,106,116,124,914],[125,914],[106,126,914],[86,101,112,127,914],[91,128,914],[116,129,914],[105,130,914],[131,914],[86,91,98,100,109,116,127,130,132,914],[116,133,914],[495,905,906,914],[495,899,906,914],[495,899,914],[101,495,914],[914,1439],[98,116,124,135,914,1434,1435,1438,1439],[914,1441,1480],[914,1441,1465,1480],[914,1480],[914,1441],[914,1441,1466,1480],[914,1441,1442,1443,1444,1445,1446,1447,1448,1449,1450,1451,1452,1453,1454,1455,1456,1457,1458,1459,1460,1461,1462,1463,1464,1465,1466,1467,1468,1469,1470,1471,1472,1473,1474,1475,1476,1477,1478,1479],[914,1466,1480],[99,116,135,486,914],[101,135,486,491,914],[116,135,914],[98,101,103,106,116,135,914],[98,124,135,914],[914,1483,1484,1485,1486,1487,1488,1489,1490,1491],[914,1492],[127,135,914],[639,914],[135,914,1435,1436,1437],[116,135,914,1435],[146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,202,203,204,205,206,207,208,209,210,211,212,213,215,216,217,218,219,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,265,266,267,269,278,280,281,282,283,284,285,287,288,290,292,293,294,295,296,297,298,299,300,301,302,303,304,305,306,308,309,310,311,312,313,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,333,914],[191,914],[147,150,914],[149,914],[149,150,914],[146,147,148,150,914],[147,149,150,307,914],[150,914],[146,149,191,914],[149,150,307,914],[149,315,914],[147,149,150,914],[159,914],[182,914],[203,914],[149,150,191,914],[150,198,914],[149,150,191,209,914],[149,150,209,914],[150,250,914],[150,191,914],[146,150,268,914],[146,150,269,914],[291,914],[275,277,914],[286,914],[275,914],[146,150,268,275,276,914],[268,269,277,914],[289,914],[146,150,275,276,277,914],[148,149,150,914],[146,150,914],[147,149,269,270,271,272,914],[191,269,270,271,272,914],[269,271,914],[149,270,271,273,274,278,914],[146,149,914],[150,293,914],[151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,192,193,194,195,196,197,199,200,201,202,203,204,205,206,207,208,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,914],[279,914],[914,923,924,925,926,927,928,930],[914,929],[116,914],[914,941],[914,933,934,936,938,939],[135,914,932,933],[135,914,931],[116,135,914,921,935],[914,921,937],[914,921],[914,932,933,937,940,942,943],[914,931,945,947,949,957],[914,944,954,955,956],[914,944,955],[116,135,914,945,950],[135,914,950],[914,931,945,949,952],[116,135,914,921,922,944,945,947,948,949,950,951],[116,135,914,921,945,946,947,950],[914,931,944,945,948,949,950,951,952,953,955,956,957,958,963,964,965,966],[914,921,931,944],[116,135,914,922,945,947,948,949],[914,922,944,945],[914,921,946,947],[914,921,947],[914,921,944,947],[914,921,946],[914,947,959,960,961,962],[914,1029,1147],[914,974,1345],[914,1032],[914,1135],[914,1131,1135],[914,1131],[914,989,1025,1026,1027,1028,1030,1031,1135],[914,974,975,984,989,1026,1030,1033,1037,1067,1084,1085,1087,1089,1093,1094,1095,1096,1131,1132,1133,1134,1140,1147,1166],[914,1098,1100,1102,1103,1112,1114,1115,1116,1117,1118,1119,1120,1122,1124,1125,1126,1127,1130],[914,978,980,981,1011,1248,1249,1250,1251,1252,1253],[914,981],[914,978,981],[914,1257,1258,1259],[914,1266],[914,978,1264],[914,1294],[914,1282],[914,1025],[914,1281],[914,979],[914,978,979,980],[914,1017],[914,1013],[914,978],[914,969,970,971],[914,1010],[914,969],[914,1345],[914,978,979],[914,1014,1015],[914,972,974],[914,1166],[914,1137,1138],[914,970],[914,1301],[914,1032,1121],[124,914],[914,1032,1097],[914,970,971,978,984,986,988,1002,1003,1004,1007,1008,1032,1033,1035,1036,1140,1146,1147],[914,1032,1043],[914,986,988,1006,1033,1035,1042,1043,1057,1069,1073,1077,1084,1135,1144,1146,1147],[94,106,124,914,1041,1042],[914,1032,1099],[914,1032,1113],[914,1032,1101],[914,1032,1123],[914,1128,1129],[914,1005],[914,1104,1105,1106,1107,1108,1109,1110],[914,1032,1111],[914,974,975,984,1043,1045,1049,1050,1051,1052,1053,1079,1081,1082,1083,1085,1087,1088,1089,1091,1092,1094,1135,1147,1166],[914,975,984,1002,1043,1046,1050,1054,1055,1078,1079,1081,1082,1083,1093,1135,1140],[914,1093,1135,1147],[914,1024],[914,978,979,1011],[914,1009,1012,1016,1017,1018,1019,1020,1021,1022,1023,1345],[914,968,969,970,971,975,1013,1014,1015],[914,1183],[914,1140,1183],[914,978,1002,1028,1183],[914,975,1183],[914,1096,1183],[914,1183,1184,1185,1188,1189,1190,1191,1192,1193,1194,1195,1196,1197,1198,1199,1200,1201,1202,1203,1204,1205,1206,1207,1208,1209,1210,1211,1212,1213,1214,1215,1216,1217,1218,1219,1220,1221,1222,1223,1224,1225,1226,1227,1228,1229,1230,1231,1232,1233,1234,1235,1236,1237,1238,1239,1240,1241,1242,1243,1244,1245,1246],[914,991,1183],[914,991,1140,1183],[914,1183,1187],[914,1037,1183],[914,1040],[914,1049],[914,1038,1045,1046,1047,1048],[914,979,984,1039],[914,1043],[914,984,1049,1050,1086,1140,1166],[914,1040,1043,1044],[914,1054],[914,984,1049],[914,1040,1044],[914,984,1040],[914,974,975,984,1084,1085,1087,1093,1094,1131,1132,1135,1166,1178,1179],[139,914,972,974,975,978,979,981,984,985,986,987,989,1009,1010,1012,1013,1015,1016,1017,1024,1025,1026,1027,1028,1031,1033,1034,1035,1037,1038,1039,1040,1043,1044,1045,1046,1047,1048,1049,1050,1051,1052,1053,1056,1057,1058,1059,1060,1061,1062,1063,1064,1065,1066,1067,1070,1073,1074,1077,1080,1081,1082,1083,1084,1085,1086,1087,1093,1094,1095,1096,1131,1135,1140,1143,1144,1145,1146,1147,1157,1158,1159,1160,1162,1163,1164,1165,1166,1179,1180,1181,1182,1247,1254,1255,1256,1260,1261,1262,1263,1265,1267,1268,1269,1270,1271,1272,1273,1274,1275,1276,1277,1278,1279,1280,1281,1282,1283,1284,1285,1286,1287,1288,1289,1290,1291,1292,1293,1295,1296,1297,1298,1299,1300,1302,1303,1304,1305,1306,1307,1308,1309,1310,1311,1312,1313,1314,1315,1316,1317,1318,1319,1320,1321,1322,1323,1324,1325,1326,1327,1328,1329,1330,1332,1333,1334,1335,1336,1337,1338,1339,1340,1342,1344],[914,1026,1027,1147],[914,1026,1147,1326],[914,1026,1027,1147,1326],[914,1147],[914,1026],[914,981,982],[914,996],[914,975],[914,1169],[914,977,983,992,993,997,999,1071,1075,1136,1139,1141,1167,1168,1169,1170,1171,1172,1173,1174,1175,1176,1177],[914,968,972,973,976],[914,1017,1018,1345],[914,989,1071,1140],[914,978,979,983,984,991,1001,1135,1140],[914,991,992,994,995,998,1000,1002,1135,1140,1142],[914,984,996,997,1001,1140],[914,984,990,991,994,995,998,1000,1001,1002,1017,1018,1072,1076,1135,1136,1137,1138,1139,1142,1345],[914,989,1075,1140],[914,969,970,971,989,1002,1140],[914,989,1001,1002,1140,1141],[914,991,1140,1166,1167],[914,984,991,993,1140,1166],[914,968,969,970,971,973,977,984,990,1001,1002,1140],[914,1002],[914,969,989,999,1001,1002,1140],[914,1095],[914,1096,1135,1147],[914,989,1146],[914,989,1338],[914,988,1146],[914,984,991,1002,1140,1186],[914,991,1002,1187],[98,99,116,914],[914,1140],[914,1158],[914,975,984,1083,1135,1147,1157,1158,1165],[914,1036],[914,975,984,1002,1079,1081,1090,1165],[914,991,1135,1140,1149,1156],[914,1157],[914,975,984,1002,1037,1079,1135,1140,1147,1148,1149,1155,1156,1157,1159,1160,1161,1162,1163,1164,1166],[914,984,991,1002,1017,1036,1135,1140,1148,1149,1150,1151,1152,1153,1154,1155,1165],[914,984],[914,991,1140,1156,1166],[914,984,991,1135,1147,1166],[914,984,1165],[914,1080],[914,984,1080],[914,975,984,991,1017,1042,1045,1046,1047,1048,1050,1140,1147,1153,1154,1156,1157,1158,1165],[914,975,984,1017,1082,1135,1147,1157,1158,1165],[914,984,1140],[914,984,1017,1079,1082,1135,1147,1157,1158,1165],[914,984,1157],[914,984,986,988,1006,1033,1035,1042,1057,1069,1073,1077,1080,1089,1093,1135,1144,1146],[914,974,984,1087,1093,1094,1166],[914,975,1043,1045,1049,1050,1051,1052,1053,1079,1081,1082,1083,1091,1092,1094,1166,1331],[914,984,1043,1049,1050,1054,1055,1084,1094,1147,1166],[914,975,984,1043,1045,1049,1050,1051,1052,1053,1079,1081,1082,1083,1091,1092,1093,1147,1166,1345],[914,984,1086,1094,1166],[914,1036,1090],[914,985,1034,1056,1070,1074,1143],[914,985,1002,1006,1007,1135,1140,1147],[914,1006],[914,986,1035,1037,1057,1073,1077,1140,1144,1145],[914,1070,1072],[914,985],[914,1074,1076],[914,990,1034,1037],[914,1142,1143],[914,1000,1056],[914,987,1345],[914,984,991,1002,1067,1068,1140,1147],[914,1058,1059,1060,1061,1062,1063,1064,1065,1066],[914,1093,1135,1140,1147],[914,1062],[914,984,991,1002,1093,1135,1140,1147],[914,986,988,1002,1005,1025,1035,1040,1044,1057,1073,1077,1084,1132,1140,1144,1146,1157,1159,1160,1161,1162,1163,1164,1166,1187,1331,1332,1333,1341],[914,1093,1140,1343],[60,64,127,914],[60,116,127,914],[55,914],[57,60,124,127,914],[106,124,914],[55,135,914],[57,60,106,127,914],[52,53,56,59,86,98,116,127,914],[52,58,914],[56,60,86,119,127,135,914],[86,135,914],[76,86,135,914],[54,55,135,914],[60,914],[54,55,56,57,58,59,60,61,62,64,65,66,67,68,69,70,71,72,73,74,75,77,78,79,80,81,82,914],[60,67,68,914],[58,60,68,69,914],[59,914],[52,55,60,914],[60,64,68,69,914],[64,914],[58,60,63,127,914],[52,57,58,60,64,67,914],[86,116,914],[55,60,76,86,132,135,914],[138,485,695,753,777,780,786,802,817,822,825,830,833,890,914],[485,891,914],[485,903,914],[138,485,903,907,914],[138,485,910,914],[138,485,642,891,911,912,913,914],[138,485,642,891,911,912,914,916],[485,892,911,914,915,917],[139,485,914,967,1345],[138,139,485,911,914,967],[138,496,905,914],[137,485,914],[101,485,495],[485],[799,819,914,1493],[101,127,135,799,814,914],[101,103,127,135,695,799,914],[914,1494,1495,1496,1497,1498,1499,1500],[695,753,757,758,763,914,1501],[485,695],[485,891],[334,485,903],[907],[485,910],[891,911],[485,911],[139,967,1345],[139,911,967],[137]],"referencedMap":[[138,1],[496,2],[635,3],[636,3],[637,3],[638,4],[643,5],[647,6],[645,7],[646,7],[1418,4],[1422,4],[1423,4],[518,4],[402,4],[140,4],[391,8],[392,8],[393,4],[394,9],[404,10],[395,4],[396,11],[397,4],[398,4],[399,8],[400,8],[401,8],[403,12],[411,13],[413,4],[410,4],[416,14],[414,4],[412,4],[408,15],[409,16],[415,4],[417,17],[405,4],[407,18],[406,19],[346,4],[349,20],[345,4],[565,4],[347,4],[348,4],[434,21],[419,21],[426,21],[423,21],[436,21],[427,21],[433,21],[418,22],[437,21],[440,23],[431,21],[421,21],[439,21],[424,21],[422,21],[432,21],[428,21],[438,21],[425,21],[435,21],[420,21],[430,21],[429,21],[447,24],[443,25],[442,4],[441,4],[446,26],[485,27],[141,4],[142,4],[143,4],[547,28],[145,29],[553,30],[552,31],[335,32],[336,29],[456,4],[365,4],[366,4],[457,33],[337,4],[458,4],[459,34],[144,4],[339,35],[340,4],[338,36],[341,35],[342,4],[344,37],[356,38],[357,4],[362,39],[358,4],[359,4],[360,4],[361,4],[363,4],[364,40],[370,41],[373,42],[371,4],[372,43],[390,44],[374,4],[375,4],[596,45],[355,46],[353,47],[351,48],[352,49],[354,4],[382,50],[376,4],[385,51],[378,52],[383,53],[381,54],[384,55],[379,56],[380,57],[368,58],[386,59],[369,60],[388,61],[389,62],[377,4],[343,4],[350,63],[387,64],[453,65],[448,4],[454,66],[449,67],[450,68],[451,69],[452,70],[455,71],[471,72],[470,73],[476,74],[468,4],[469,75],[472,72],[473,76],[475,77],[474,78],[477,79],[462,80],[463,81],[466,82],[465,82],[464,81],[467,81],[461,83],[479,84],[478,85],[481,86],[480,87],[482,88],[444,58],[445,89],[367,4],[483,90],[460,91],[484,92],[516,93],[517,94],[538,95],[539,96],[540,4],[541,97],[542,98],[551,99],[544,100],[548,101],[556,102],[554,9],[555,103],[545,104],[557,4],[559,105],[560,106],[561,107],[550,108],[546,109],[570,110],[558,111],[585,112],[543,94],[586,113],[583,114],[584,9],[608,115],[533,116],[529,117],[531,118],[582,119],[524,120],[572,121],[571,4],[532,122],[579,123],[536,124],[580,4],[581,125],[534,126],[528,127],[535,128],[530,129],[523,4],[576,130],[589,131],[587,9],[519,9],[575,132],[520,16],[521,96],[522,133],[526,134],[525,135],[588,136],[527,137],[564,138],[562,105],[563,139],[573,16],[574,140],[577,141],[592,142],[593,143],[590,144],[591,145],[594,146],[595,147],[597,148],[569,149],[566,150],[567,8],[568,139],[599,151],[598,152],[605,153],[537,9],[601,154],[600,9],[603,155],[602,4],[604,156],[549,157],[578,158],[607,159],[606,9],[515,160],[610,161],[617,162],[618,163],[619,163],[622,164],[620,165],[621,166],[613,167],[623,168],[624,4],[630,169],[625,4],[626,4],[627,4],[628,4],[629,4],[633,170],[498,171],[499,171],[500,171],[497,4],[615,172],[502,173],[503,173],[504,173],[501,4],[505,174],[506,175],[507,176],[514,177],[509,178],[510,178],[511,178],[512,4],[508,4],[513,179],[632,180],[631,181],[614,161],[616,182],[611,183],[612,184],[609,64],[634,185],[893,4],[897,186],[902,187],[894,9],[896,188],[895,4],[898,189],[900,190],[901,191],[903,192],[841,193],[842,194],[839,195],[840,193],[836,196],[837,197],[838,198],[835,197],[656,199],[659,200],[665,201],[668,202],[689,203],[667,204],[648,4],[649,205],[650,206],[653,4],[651,4],[652,4],[690,207],[655,199],[654,4],[691,208],[658,200],[657,4],[695,209],[692,210],[662,211],[664,212],[661,213],[663,214],[660,211],[693,215],[666,199],[694,216],[669,217],[688,218],[685,219],[687,220],[672,221],[679,222],[681,223],[683,224],[682,225],[674,226],[671,219],[675,4],[686,227],[676,228],[673,4],[684,4],[670,4],[677,229],[678,4],[680,230],[696,197],[704,197],[697,4],[698,197],[700,231],[701,232],[702,197],[699,197],[703,4],[733,233],[732,234],[715,235],[706,236],[707,4],[708,4],[714,237],[711,238],[710,239],[712,4],[713,43],[716,197],[709,4],[718,197],[719,197],[720,197],[721,197],[722,197],[723,197],[724,197],[717,197],[730,4],[705,197],[725,4],[726,4],[727,4],[728,4],[729,232],[731,4],[833,240],[832,241],[831,43],[786,242],[784,243],[783,244],[782,245],[781,246],[785,247],[801,248],[802,249],[800,250],[821,4],[818,4],[822,251],[820,252],[819,253],[815,254],[817,255],[814,256],[816,257],[809,258],[813,259],[804,260],[810,261],[811,261],[807,262],[806,263],[805,264],[803,197],[808,265],[812,261],[824,4],[825,266],[823,267],[797,268],[799,269],[789,270],[795,271],[794,272],[790,273],[792,274],[793,274],[791,4],[787,197],[796,275],[798,276],[734,277],[752,278],[747,279],[749,279],[748,280],[750,280],[751,281],[753,282],[735,277],[746,283],[738,4],[739,280],[741,284],[745,285],[740,280],[742,284],[743,280],[744,280],[737,286],[736,287],[853,288],[850,289],[852,289],[849,290],[848,291],[843,292],[851,293],[857,294],[844,295],[847,296],[845,297],[846,298],[856,299],[854,300],[855,301],[834,279],[865,302],[867,4],[868,4],[869,303],[866,302],[872,304],[870,302],[871,302],[864,305],[877,306],[862,4],[884,307],[883,308],[876,309],[878,310],[879,311],[881,312],[882,313],[886,314],[875,315],[885,316],[880,4],[863,317],[873,318],[858,197],[860,319],[861,320],[859,4],[874,321],[890,322],[889,323],[888,324],[887,259],[760,325],[764,326],[769,327],[770,327],[772,328],[758,329],[771,330],[759,331],[754,4],[777,332],[768,333],[765,334],[767,335],[766,336],[755,197],[773,337],[774,337],[775,338],[776,337],[761,339],[762,340],[757,197],[763,341],[756,342],[778,343],[780,344],[779,345],[830,346],[829,347],[828,4],[827,348],[826,4],[1353,349],[910,350],[909,4],[1354,4],[1355,4],[1356,4],[1407,351],[1357,352],[1397,353],[1359,354],[1358,355],[1360,352],[1361,352],[1363,356],[1362,352],[1364,357],[1365,357],[1367,358],[1368,352],[1369,358],[1370,352],[1372,352],[1373,352],[1374,352],[1375,359],[1371,352],[1376,4],[1377,360],[1378,360],[1379,360],[1380,360],[1381,360],[1389,361],[1382,360],[1383,360],[1384,360],[1385,360],[1386,360],[1387,360],[1388,360],[1390,352],[1391,352],[1366,352],[1392,352],[1393,352],[1394,352],[1396,352],[1395,352],[1398,352],[1400,352],[1401,362],[1399,352],[1402,352],[1403,352],[1404,352],[1405,352],[1406,352],[494,363],[1408,364],[493,349],[1409,4],[1411,365],[920,366],[921,367],[1416,368],[1412,4],[1415,369],[1413,4],[490,370],[495,371],[1417,4],[1424,372],[1421,373],[1419,374],[1425,4],[491,4],[1426,375],[1414,4],[1427,4],[905,376],[1410,4],[1428,377],[1429,378],[1430,377],[1431,364],[1420,4],[486,4],[1432,375],[50,379],[51,379],[85,380],[86,381],[87,382],[88,383],[89,384],[90,385],[91,386],[92,387],[93,388],[94,389],[95,389],[97,390],[96,391],[98,392],[99,393],[100,394],[84,395],[134,4],[101,396],[102,397],[103,398],[135,399],[104,400],[105,401],[106,402],[107,403],[108,404],[109,405],[110,406],[111,407],[112,408],[113,409],[114,409],[115,410],[116,411],[118,412],[117,413],[119,414],[120,415],[121,416],[122,417],[123,418],[124,419],[125,420],[126,421],[127,422],[128,423],[129,424],[130,425],[131,426],[132,427],[133,428],[907,429],[1433,430],[906,431],[899,432],[1440,433],[1439,434],[488,4],[489,4],[1465,435],[1466,436],[1441,437],[1444,437],[1463,435],[1464,435],[1454,435],[1453,438],[1451,435],[1446,435],[1459,435],[1457,435],[1461,435],[1445,435],[1458,435],[1462,435],[1447,435],[1448,435],[1460,435],[1442,435],[1449,435],[1450,435],[1452,435],[1456,435],[1467,439],[1455,435],[1443,435],[1480,440],[1479,4],[1474,439],[1476,441],[1475,439],[1468,439],[1469,439],[1471,439],[1473,439],[1477,441],[1478,441],[1470,441],[1472,441],[487,442],[492,443],[788,4],[1481,444],[919,445],[1482,446],[913,4],[1492,447],[1483,448],[1484,4],[1485,4],[1486,4],[1487,4],[1488,4],[1489,4],[1490,4],[1491,4],[914,4],[136,449],[640,450],[639,4],[137,4],[1438,451],[1435,43],[1437,452],[1436,43],[1434,4],[644,4],[139,4],[334,453],[307,4],[285,454],[283,454],[333,455],[298,456],[297,456],[198,457],[149,458],[305,457],[306,457],[308,459],[309,457],[310,460],[209,461],[311,457],[282,457],[312,457],[313,462],[314,457],[315,456],[316,463],[317,457],[318,457],[319,457],[320,457],[321,456],[322,457],[323,457],[324,457],[325,457],[326,464],[327,457],[328,457],[329,457],[330,457],[331,457],[148,455],[151,460],[152,460],[153,460],[154,460],[155,460],[156,460],[157,460],[158,457],[160,465],[161,460],[159,460],[162,460],[163,460],[164,460],[165,460],[166,460],[167,460],[168,457],[169,460],[170,460],[171,460],[172,460],[173,460],[174,457],[175,460],[176,460],[177,460],[178,460],[179,460],[180,460],[181,457],[183,466],[182,460],[184,460],[185,460],[186,460],[187,460],[188,464],[189,457],[190,457],[204,467],[192,468],[193,460],[194,460],[195,457],[196,460],[197,460],[199,469],[200,460],[201,460],[202,460],[203,460],[205,460],[206,460],[207,460],[208,460],[210,470],[211,460],[212,460],[213,460],[214,457],[215,460],[216,471],[217,471],[218,471],[219,457],[220,460],[221,460],[222,460],[227,460],[223,460],[224,457],[225,460],[226,457],[228,460],[229,460],[230,460],[231,460],[232,460],[233,460],[234,457],[235,460],[236,460],[237,460],[238,460],[239,460],[240,460],[241,460],[242,460],[243,460],[244,460],[245,460],[246,460],[247,460],[248,460],[249,460],[250,460],[251,472],[252,460],[253,460],[254,460],[255,460],[256,460],[257,460],[258,457],[259,457],[260,457],[261,457],[262,457],[263,460],[264,460],[265,460],[266,460],[284,473],[332,457],[269,474],[268,475],[292,476],[291,477],[287,478],[286,477],[288,479],[277,480],[275,481],[290,482],[289,479],[276,4],[278,483],[191,484],[147,485],[146,460],[281,4],[273,486],[274,487],[271,4],[272,488],[270,460],[279,489],[150,490],[299,4],[300,4],[293,4],[296,456],[295,4],[301,4],[302,4],[294,491],[303,4],[304,4],[267,492],[280,493],[929,4],[928,4],[925,4],[931,494],[923,4],[930,495],[927,496],[924,4],[926,4],[942,497],[941,4],[940,498],[934,499],[943,4],[932,500],[936,501],[935,4],[938,502],[939,503],[933,4],[937,4],[944,504],[958,505],[955,4],[957,506],[956,507],[965,508],[966,509],[951,510],[952,511],[954,512],[967,513],[948,514],[950,515],[953,4],[945,444],[946,516],[922,4],[949,4],[962,517],[959,517],[960,517],[961,518],[964,519],[947,520],[963,521],[1030,522],[1029,4],[1051,4],[975,523],[1031,4],[984,4],[974,4],[1092,4],[1182,4],[1128,524],[1336,525],[1179,526],[1335,527],[1334,527],[1181,4],[1032,528],[1135,529],[1131,530],[1331,526],[1303,4],[1254,531],[1255,532],[1256,532],[1268,532],[1261,533],[1260,534],[1262,532],[1263,532],[1267,535],[1265,536],[1295,537],[1292,4],[1291,538],[1293,532],[1306,539],[1304,4],[1305,4],[1300,540],[1269,4],[1270,4],[1273,4],[1271,4],[1272,4],[1274,4],[1275,4],[1278,4],[1276,4],[1277,4],[1279,4],[1280,4],[980,541],[1251,4],[1250,4],[1252,4],[1249,4],[981,542],[1248,4],[1253,4],[1282,543],[1281,4],[1013,4],[1014,544],[1015,544],[1259,545],[1257,545],[1258,4],[972,546],[1011,547],[1301,548],[979,4],[1266,541],[1294,549],[1264,550],[1283,544],[1284,551],[1285,552],[1286,552],[1287,552],[1288,552],[1289,553],[1290,553],[1299,554],[1298,4],[1296,4],[1297,555],[1302,556],[1121,4],[1122,557],[1125,524],[1126,524],[1127,524],[1097,558],[1098,559],[1116,524],[1037,560],[1120,524],[1041,4],[1115,561],[1078,562],[1043,563],[1099,4],[1100,564],[1119,524],[1113,4],[1114,565],[1101,558],[1102,566],[1005,4],[1118,524],[1123,4],[1124,567],[1129,4],[1130,568],[1006,569],[1103,524],[1117,524],[1105,4],[1106,4],[1107,4],[1108,4],[1109,4],[1104,4],[1110,4],[1333,4],[1111,570],[1112,571],[978,4],[1003,4],[1028,4],[1008,4],[1010,4],[1089,4],[1004,545],[1033,4],[1036,4],[1093,572],[1084,573],[1132,574],[1025,575],[1020,4],[1012,576],[1340,539],[1021,4],[1009,4],[1022,532],[1024,577],[1023,553],[1016,578],[1019,548],[1185,579],[1208,579],[1189,579],[1192,580],[1194,579],[1244,579],[1220,579],[1184,579],[1212,579],[1241,579],[1191,579],[1221,579],[1206,579],[1209,579],[1197,579],[1231,581],[1226,579],[1219,579],[1201,582],[1200,582],[1217,580],[1227,579],[1246,583],[1247,584],[1232,585],[1223,579],[1204,579],[1190,579],[1193,579],[1225,579],[1210,580],[1218,579],[1215,586],[1233,586],[1216,580],[1202,579],[1228,579],[1211,579],[1245,579],[1235,579],[1222,579],[1243,579],[1224,579],[1203,579],[1239,579],[1229,579],[1205,579],[1234,579],[1242,579],[1207,579],[1230,582],[1213,579],[1238,587],[1188,587],[1199,579],[1198,579],[1196,588],[1183,4],[1195,579],[1240,586],[1236,586],[1214,586],[1237,586],[1044,589],[1050,590],[1049,591],[1040,592],[1039,4],[1048,593],[1047,593],[1046,593],[1325,594],[1045,595],[1086,4],[1038,4],[1055,596],[1054,597],[1307,589],[1308,589],[1309,589],[1310,589],[1311,589],[1312,589],[1313,598],[1318,589],[1314,589],[1315,589],[1324,589],[1316,589],[1317,589],[1319,589],[1320,589],[1321,589],[1322,589],[1323,599],[1017,4],[1180,600],[1345,601],[1326,602],[1327,603],[1329,604],[1026,605],[1027,606],[1328,603],[1071,4],[983,607],[1173,4],[992,4],[997,608],[1174,609],[1171,4],[1075,4],[1177,4],[1141,4],[1172,532],[1169,4],[1170,610],[1178,611],[1168,4],[1167,553],[993,553],[977,612],[1136,613],[1175,4],[1176,4],[1139,554],[982,4],[999,548],[1072,614],[1002,615],[1001,616],[998,617],[1140,618],[1076,619],[990,620],[1142,621],[995,622],[994,623],[991,624],[1138,625],[969,4],[996,4],[970,4],[971,4],[973,4],[976,609],[968,4],[1018,4],[1137,4],[1000,626],[1096,627],[1337,628],[1095,605],[1338,629],[1339,630],[989,631],[1187,632],[1186,633],[1042,634],[1149,635],[1157,636],[1160,637],[1090,638],[1162,639],[1150,640],[1164,641],[1165,642],[1148,4],[1156,643],[1079,644],[1152,645],[1151,645],[1134,646],[1133,646],[1163,647],[1083,648],[1081,649],[1082,649],[1153,4],[1166,650],[1154,4],[1161,651],[1088,652],[1159,653],[1155,4],[1158,654],[1080,4],[1147,655],[1330,656],[1332,657],[1343,4],[1085,658],[1053,4],[1094,659],[1052,4],[1087,660],[1091,661],[1070,4],[985,4],[1074,4],[1034,4],[1143,4],[1145,662],[1056,4],[987,549],[1341,663],[1007,664],[1146,665],[1073,666],[986,667],[1077,668],[1035,669],[1144,670],[1057,671],[988,672],[1069,673],[1068,4],[1067,674],[1063,675],[1064,675],[1066,676],[1062,675],[1065,676],[1058,574],[1059,574],[1060,574],[1061,677],[1342,678],[1344,679],[47,4],[48,4],[8,4],[9,4],[13,4],[12,4],[2,4],[14,4],[15,4],[16,4],[17,4],[18,4],[19,4],[20,4],[21,4],[3,4],[4,4],[22,4],[49,4],[26,4],[23,4],[24,4],[25,4],[27,4],[28,4],[29,4],[5,4],[30,4],[31,4],[32,4],[33,4],[6,4],[37,4],[34,4],[35,4],[36,4],[38,4],[7,4],[39,4],[44,4],[45,4],[40,4],[41,4],[42,4],[43,4],[1,4],[46,4],[11,4],[10,4],[67,680],[74,681],[66,680],[81,682],[58,683],[57,684],[80,43],[75,685],[78,686],[60,687],[59,688],[55,689],[54,690],[77,691],[56,692],[61,693],[62,4],[65,693],[52,4],[83,694],[82,693],[69,695],[70,696],[72,697],[68,698],[71,699],[76,43],[63,700],[64,701],[73,702],[53,703],[79,704],[891,705],[892,706],[904,707],[908,708],[911,709],[915,710],[917,711],[918,712],[1346,713],[1347,714],[641,9],[1348,9],[1349,4],[1350,715],[912,4],[1351,4],[642,4],[916,4],[1352,716]],"exportedModulesMap":[[496,717],[643,718],[1418,4],[1422,4],[1423,4],[518,4],[402,4],[140,4],[391,8],[392,8],[393,4],[394,9],[404,10],[395,4],[396,11],[397,4],[398,4],[399,8],[400,8],[401,8],[403,12],[411,13],[413,4],[410,4],[416,14],[414,4],[412,4],[408,15],[409,16],[415,4],[417,17],[405,4],[407,18],[406,19],[346,4],[349,20],[345,4],[565,4],[347,4],[348,4],[434,21],[419,21],[426,21],[423,21],[436,21],[427,21],[433,21],[418,22],[437,21],[440,23],[431,21],[421,21],[439,21],[424,21],[422,21],[432,21],[428,21],[438,21],[425,21],[435,21],[420,21],[430,21],[429,21],[447,24],[443,25],[442,4],[441,4],[446,26],[485,27],[141,4],[142,4],[143,4],[547,28],[145,29],[553,30],[552,31],[335,32],[336,29],[456,4],[365,4],[366,4],[457,33],[337,4],[458,4],[459,34],[144,4],[339,35],[340,4],[338,36],[341,35],[342,4],[344,37],[356,38],[357,4],[362,39],[358,4],[359,4],[360,4],[361,4],[363,4],[364,40],[370,41],[373,42],[371,4],[372,43],[390,44],[374,4],[375,4],[596,45],[355,46],[353,47],[351,48],[352,49],[354,4],[382,50],[376,4],[385,51],[378,52],[383,53],[381,54],[384,55],[379,56],[380,57],[368,58],[386,59],[369,60],[388,61],[389,62],[377,4],[343,4],[350,63],[387,64],[453,65],[448,4],[454,66],[449,67],[450,68],[451,69],[452,70],[455,71],[471,72],[470,73],[476,74],[468,4],[469,75],[472,72],[473,76],[475,77],[474,78],[477,79],[462,80],[463,81],[466,82],[465,82],[464,81],[467,81],[461,83],[479,84],[478,85],[481,86],[480,87],[482,88],[444,58],[445,89],[367,4],[483,90],[460,91],[484,92],[516,93],[517,94],[538,95],[539,96],[540,4],[541,97],[542,98],[551,99],[544,100],[548,101],[556,102],[554,9],[555,103],[545,104],[557,4],[559,105],[560,106],[561,107],[550,108],[546,109],[570,110],[558,111],[585,112],[543,94],[586,113],[583,114],[584,9],[608,115],[533,116],[529,117],[531,118],[582,119],[524,120],[572,121],[571,4],[532,122],[579,123],[536,124],[580,4],[581,125],[534,126],[528,127],[535,128],[530,129],[523,4],[576,130],[589,131],[587,9],[519,9],[575,132],[520,16],[521,96],[522,133],[526,134],[525,135],[588,136],[527,137],[564,138],[562,105],[563,139],[573,16],[574,140],[577,141],[592,142],[593,143],[590,144],[591,145],[594,146],[595,147],[597,148],[569,149],[566,150],[567,8],[568,139],[599,151],[598,152],[605,153],[537,9],[601,154],[600,9],[603,155],[602,4],[604,156],[549,157],[578,158],[607,159],[606,9],[515,160],[610,161],[617,162],[618,163],[619,163],[622,164],[620,165],[621,166],[613,167],[623,168],[624,4],[630,169],[625,4],[626,4],[627,4],[628,4],[629,4],[633,170],[498,171],[499,171],[500,171],[497,4],[615,172],[502,173],[503,173],[504,173],[501,4],[505,174],[506,175],[507,176],[514,177],[509,178],[510,178],[511,178],[512,4],[508,4],[513,179],[632,180],[631,181],[614,161],[616,182],[611,183],[612,184],[609,64],[634,185],[893,4],[897,186],[902,187],[894,9],[896,188],[895,4],[898,189],[900,190],[901,191],[903,192],[841,193],[842,194],[839,195],[840,193],[836,196],[837,197],[838,198],[835,197],[656,199],[659,200],[665,201],[668,202],[689,203],[667,204],[648,4],[649,205],[650,206],[653,4],[651,4],[652,4],[690,207],[655,199],[654,4],[691,208],[658,200],[657,4],[695,209],[692,210],[662,211],[664,212],[661,213],[663,214],[660,211],[693,215],[666,199],[694,216],[669,217],[688,218],[685,219],[687,220],[672,221],[679,222],[681,223],[683,224],[682,225],[674,226],[671,219],[675,4],[686,227],[676,228],[673,4],[684,4],[670,4],[677,229],[678,4],[680,230],[696,197],[704,197],[697,4],[698,197],[700,231],[701,232],[702,197],[699,197],[703,4],[733,233],[732,234],[715,235],[706,236],[707,4],[708,4],[714,237],[711,238],[710,239],[712,4],[713,43],[716,197],[709,4],[718,197],[719,197],[720,197],[721,197],[722,197],[723,197],[724,197],[717,197],[730,4],[705,197],[725,4],[726,4],[727,4],[728,4],[729,232],[731,4],[833,240],[832,241],[831,43],[786,242],[784,243],[783,244],[782,245],[781,246],[785,247],[801,248],[802,249],[800,250],[821,4],[818,4],[822,251],[820,719],[819,253],[815,720],[817,255],[814,721],[816,257],[809,258],[813,722],[804,260],[810,261],[811,261],[807,262],[806,263],[805,264],[803,197],[808,265],[812,261],[824,4],[825,266],[823,267],[797,268],[799,269],[789,270],[795,271],[794,272],[790,273],[792,274],[793,274],[791,4],[787,197],[796,275],[798,276],[734,277],[752,278],[747,279],[749,279],[748,280],[750,280],[751,281],[753,282],[735,277],[746,283],[738,4],[739,280],[741,284],[745,285],[740,280],[742,284],[743,280],[744,280],[737,286],[736,287],[853,288],[850,289],[852,289],[849,290],[848,291],[843,292],[851,293],[857,294],[844,295],[847,296],[845,297],[846,298],[856,299],[854,300],[855,301],[834,279],[865,302],[867,4],[868,4],[869,303],[866,302],[872,304],[870,302],[871,302],[864,305],[877,306],[862,4],[884,307],[883,308],[876,309],[878,310],[879,311],[881,312],[882,313],[886,314],[875,315],[885,316],[880,4],[863,317],[873,318],[858,197],[860,319],[861,320],[859,4],[874,321],[890,322],[889,323],[888,324],[887,259],[760,325],[764,326],[769,327],[770,327],[772,328],[758,329],[771,330],[759,331],[754,4],[777,332],[768,333],[765,334],[767,335],[766,336],[755,197],[773,337],[774,337],[775,338],[776,337],[761,723],[762,340],[757,197],[763,341],[756,342],[778,343],[780,344],[779,345],[830,346],[829,347],[828,4],[827,348],[826,4],[1353,349],[910,350],[909,4],[1354,4],[1355,4],[1356,4],[1407,351],[1357,352],[1397,353],[1359,354],[1358,355],[1360,352],[1361,352],[1363,356],[1362,352],[1364,357],[1365,357],[1367,358],[1368,352],[1369,358],[1370,352],[1372,352],[1373,352],[1374,352],[1375,359],[1371,352],[1376,4],[1377,360],[1378,360],[1379,360],[1380,360],[1381,360],[1389,361],[1382,360],[1383,360],[1384,360],[1385,360],[1386,360],[1387,360],[1388,360],[1390,352],[1391,352],[1366,352],[1392,352],[1393,352],[1394,352],[1396,352],[1395,352],[1398,352],[1400,352],[1401,362],[1399,352],[1402,352],[1403,352],[1404,352],[1405,352],[1406,352],[494,363],[1408,364],[493,349],[1409,4],[1411,365],[920,366],[921,367],[1416,368],[1412,4],[1415,369],[1413,4],[490,370],[495,371],[1417,4],[1424,372],[1421,373],[1419,374],[1425,4],[491,4],[1426,375],[1414,4],[1427,4],[905,376],[1410,4],[1428,377],[1429,378],[1430,377],[1431,364],[1420,4],[486,4],[1432,375],[50,379],[51,379],[85,380],[86,381],[87,382],[88,383],[89,384],[90,385],[91,386],[92,387],[93,388],[94,389],[95,389],[97,390],[96,391],[98,392],[99,393],[100,394],[84,395],[134,4],[101,396],[102,397],[103,398],[135,399],[104,400],[105,401],[106,402],[107,403],[108,404],[109,405],[110,406],[111,407],[112,408],[113,409],[114,409],[115,410],[116,411],[118,412],[117,413],[119,414],[120,415],[121,416],[122,417],[123,418],[124,419],[125,420],[126,421],[127,422],[128,423],[129,424],[130,425],[131,426],[132,427],[133,428],[907,429],[1433,430],[906,431],[899,432],[1440,433],[1439,434],[488,4],[489,4],[1465,435],[1466,436],[1441,437],[1444,437],[1463,435],[1464,435],[1454,435],[1453,438],[1451,435],[1446,435],[1459,435],[1457,435],[1461,435],[1445,435],[1458,435],[1462,435],[1447,435],[1448,435],[1460,435],[1442,435],[1449,435],[1450,435],[1452,435],[1456,435],[1467,439],[1455,435],[1443,435],[1480,440],[1479,4],[1474,439],[1476,441],[1475,439],[1468,439],[1469,439],[1471,439],[1473,439],[1477,441],[1478,441],[1470,441],[1472,441],[487,442],[492,443],[788,4],[1481,444],[919,445],[1482,446],[913,4],[1492,447],[1483,448],[1484,4],[1485,4],[1486,4],[1487,4],[1488,4],[1489,4],[1490,4],[1491,4],[914,4],[136,449],[640,450],[639,4],[137,4],[1438,451],[1435,43],[1437,452],[1436,43],[1434,4],[644,4],[139,4],[334,453],[307,4],[285,454],[283,454],[333,455],[298,456],[297,456],[198,457],[149,458],[305,457],[306,457],[308,459],[309,457],[310,460],[209,461],[311,457],[282,457],[312,457],[313,462],[314,457],[315,456],[316,463],[317,457],[318,457],[319,457],[320,457],[321,456],[322,457],[323,457],[324,457],[325,457],[326,464],[327,457],[328,457],[329,457],[330,457],[331,457],[148,455],[151,460],[152,460],[153,460],[154,460],[155,460],[156,460],[157,460],[158,457],[160,465],[161,460],[159,460],[162,460],[163,460],[164,460],[165,460],[166,460],[167,460],[168,457],[169,460],[170,460],[171,460],[172,460],[173,460],[174,457],[175,460],[176,460],[177,460],[178,460],[179,460],[180,460],[181,457],[183,466],[182,460],[184,460],[185,460],[186,460],[187,460],[188,464],[189,457],[190,457],[204,467],[192,468],[193,460],[194,460],[195,457],[196,460],[197,460],[199,469],[200,460],[201,460],[202,460],[203,460],[205,460],[206,460],[207,460],[208,460],[210,470],[211,460],[212,460],[213,460],[214,457],[215,460],[216,471],[217,471],[218,471],[219,457],[220,460],[221,460],[222,460],[227,460],[223,460],[224,457],[225,460],[226,457],[228,460],[229,460],[230,460],[231,460],[232,460],[233,460],[234,457],[235,460],[236,460],[237,460],[238,460],[239,460],[240,460],[241,460],[242,460],[243,460],[244,460],[245,460],[246,460],[247,460],[248,460],[249,460],[250,460],[251,472],[252,460],[253,460],[254,460],[255,460],[256,460],[257,460],[258,457],[259,457],[260,457],[261,457],[262,457],[263,460],[264,460],[265,460],[266,460],[284,473],[332,457],[269,474],[268,475],[292,476],[291,477],[287,478],[286,477],[288,479],[277,480],[275,481],[290,482],[289,479],[276,4],[278,483],[191,484],[147,485],[146,460],[281,4],[273,486],[274,487],[271,4],[272,488],[270,460],[279,489],[150,490],[299,4],[300,4],[293,4],[296,456],[295,4],[301,4],[302,4],[294,491],[303,4],[304,4],[267,492],[280,493],[929,4],[928,4],[925,4],[931,494],[923,4],[930,495],[927,496],[924,4],[926,4],[942,497],[941,4],[940,498],[934,499],[943,4],[932,500],[936,501],[935,4],[938,502],[939,503],[933,4],[937,4],[944,504],[958,505],[955,4],[957,506],[956,507],[965,508],[966,509],[951,510],[952,511],[954,512],[967,513],[948,514],[950,515],[953,4],[945,444],[946,516],[922,4],[949,4],[962,517],[959,517],[960,517],[961,518],[964,519],[947,520],[963,521],[1030,522],[1029,4],[1051,4],[975,523],[1031,4],[984,4],[974,4],[1092,4],[1182,4],[1128,524],[1336,525],[1179,526],[1335,527],[1334,527],[1181,4],[1032,528],[1135,529],[1131,530],[1331,526],[1303,4],[1254,531],[1255,532],[1256,532],[1268,532],[1261,533],[1260,534],[1262,532],[1263,532],[1267,535],[1265,536],[1295,537],[1292,4],[1291,538],[1293,532],[1306,539],[1304,4],[1305,4],[1300,540],[1269,4],[1270,4],[1273,4],[1271,4],[1272,4],[1274,4],[1275,4],[1278,4],[1276,4],[1277,4],[1279,4],[1280,4],[980,541],[1251,4],[1250,4],[1252,4],[1249,4],[981,542],[1248,4],[1253,4],[1282,543],[1281,4],[1013,4],[1014,544],[1015,544],[1259,545],[1257,545],[1258,4],[972,546],[1011,547],[1301,548],[979,4],[1266,541],[1294,549],[1264,550],[1283,544],[1284,551],[1285,552],[1286,552],[1287,552],[1288,552],[1289,553],[1290,553],[1299,554],[1298,4],[1296,4],[1297,555],[1302,556],[1121,4],[1122,557],[1125,524],[1126,524],[1127,524],[1097,558],[1098,559],[1116,524],[1037,560],[1120,524],[1041,4],[1115,561],[1078,562],[1043,563],[1099,4],[1100,564],[1119,524],[1113,4],[1114,565],[1101,558],[1102,566],[1005,4],[1118,524],[1123,4],[1124,567],[1129,4],[1130,568],[1006,569],[1103,524],[1117,524],[1105,4],[1106,4],[1107,4],[1108,4],[1109,4],[1104,4],[1110,4],[1333,4],[1111,570],[1112,571],[978,4],[1003,4],[1028,4],[1008,4],[1010,4],[1089,4],[1004,545],[1033,4],[1036,4],[1093,572],[1084,573],[1132,574],[1025,575],[1020,4],[1012,576],[1340,539],[1021,4],[1009,4],[1022,532],[1024,577],[1023,553],[1016,578],[1019,548],[1185,579],[1208,579],[1189,579],[1192,580],[1194,579],[1244,579],[1220,579],[1184,579],[1212,579],[1241,579],[1191,579],[1221,579],[1206,579],[1209,579],[1197,579],[1231,581],[1226,579],[1219,579],[1201,582],[1200,582],[1217,580],[1227,579],[1246,583],[1247,584],[1232,585],[1223,579],[1204,579],[1190,579],[1193,579],[1225,579],[1210,580],[1218,579],[1215,586],[1233,586],[1216,580],[1202,579],[1228,579],[1211,579],[1245,579],[1235,579],[1222,579],[1243,579],[1224,579],[1203,579],[1239,579],[1229,579],[1205,579],[1234,579],[1242,579],[1207,579],[1230,582],[1213,579],[1238,587],[1188,587],[1199,579],[1198,579],[1196,588],[1183,4],[1195,579],[1240,586],[1236,586],[1214,586],[1237,586],[1044,589],[1050,590],[1049,591],[1040,592],[1039,4],[1048,593],[1047,593],[1046,593],[1325,594],[1045,595],[1086,4],[1038,4],[1055,596],[1054,597],[1307,589],[1308,589],[1309,589],[1310,589],[1311,589],[1312,589],[1313,598],[1318,589],[1314,589],[1315,589],[1324,589],[1316,589],[1317,589],[1319,589],[1320,589],[1321,589],[1322,589],[1323,599],[1017,4],[1180,600],[1345,601],[1326,602],[1327,603],[1329,604],[1026,605],[1027,606],[1328,603],[1071,4],[983,607],[1173,4],[992,4],[997,608],[1174,609],[1171,4],[1075,4],[1177,4],[1141,4],[1172,532],[1169,4],[1170,610],[1178,611],[1168,4],[1167,553],[993,553],[977,612],[1136,613],[1175,4],[1176,4],[1139,554],[982,4],[999,548],[1072,614],[1002,615],[1001,616],[998,617],[1140,618],[1076,619],[990,620],[1142,621],[995,622],[994,623],[991,624],[1138,625],[969,4],[996,4],[970,4],[971,4],[973,4],[976,609],[968,4],[1018,4],[1137,4],[1000,626],[1096,627],[1337,628],[1095,605],[1338,629],[1339,630],[989,631],[1187,632],[1186,633],[1042,634],[1149,635],[1157,636],[1160,637],[1090,638],[1162,639],[1150,640],[1164,641],[1165,642],[1148,4],[1156,643],[1079,644],[1152,645],[1151,645],[1134,646],[1133,646],[1163,647],[1083,648],[1081,649],[1082,649],[1153,4],[1166,650],[1154,4],[1161,651],[1088,652],[1159,653],[1155,4],[1158,654],[1080,4],[1147,655],[1330,656],[1332,657],[1343,4],[1085,658],[1053,4],[1094,659],[1052,4],[1087,660],[1091,661],[1070,4],[985,4],[1074,4],[1034,4],[1143,4],[1145,662],[1056,4],[987,549],[1341,663],[1007,664],[1146,665],[1073,666],[986,667],[1077,668],[1035,669],[1144,670],[1057,671],[988,672],[1069,673],[1068,4],[1067,674],[1063,675],[1064,675],[1066,676],[1062,675],[1065,676],[1058,574],[1059,574],[1060,574],[1061,677],[1342,678],[1344,679],[47,4],[48,4],[8,4],[9,4],[13,4],[12,4],[2,4],[14,4],[15,4],[16,4],[17,4],[18,4],[19,4],[20,4],[21,4],[3,4],[4,4],[22,4],[49,4],[26,4],[23,4],[24,4],[25,4],[27,4],[28,4],[29,4],[5,4],[30,4],[31,4],[32,4],[33,4],[6,4],[37,4],[34,4],[35,4],[36,4],[38,4],[7,4],[39,4],[44,4],[45,4],[40,4],[41,4],[42,4],[43,4],[1,4],[46,4],[11,4],[10,4],[67,680],[74,681],[66,680],[81,682],[58,683],[57,684],[80,43],[75,685],[78,686],[60,687],[59,688],[55,689],[54,690],[77,691],[56,692],[61,693],[62,4],[65,693],[52,4],[83,694],[82,693],[69,695],[70,696],[72,697],[68,698],[71,699],[76,43],[63,700],[64,701],[73,702],[53,703],[79,704],[891,724],[892,725],[904,726],[908,727],[911,728],[915,729],[917,729],[918,730],[1346,731],[1347,732],[1352,733]],"semanticDiagnosticsPerFile":[138,496,635,636,637,638,643,647,645,646,1418,1422,1423,518,402,140,391,392,393,394,404,395,396,397,398,399,400,401,403,411,413,410,416,414,412,408,409,415,417,405,407,406,346,349,345,565,347,348,434,419,426,423,436,427,433,418,437,440,431,421,439,424,422,432,428,438,425,435,420,430,429,447,443,442,441,446,485,141,142,143,547,145,553,552,335,336,456,365,366,457,337,458,459,144,339,340,338,341,342,344,356,357,362,358,359,360,361,363,364,370,373,371,372,390,374,375,596,355,353,351,352,354,382,376,385,378,383,381,384,379,380,368,386,369,388,389,377,343,350,387,453,448,454,449,450,451,452,455,471,470,476,468,469,472,473,475,474,477,462,463,466,465,464,467,461,479,478,481,480,482,444,445,367,483,460,484,516,517,538,539,540,541,542,551,544,548,556,554,555,545,557,559,560,561,550,546,570,558,585,543,586,583,584,608,533,529,531,582,524,572,571,532,579,536,580,581,534,528,535,530,523,576,589,587,519,575,520,521,522,526,525,588,527,564,562,563,573,574,577,592,593,590,591,594,595,597,569,566,567,568,599,598,605,537,601,600,603,602,604,549,578,607,606,515,610,617,618,619,622,620,621,613,623,624,630,625,626,627,628,629,633,498,499,500,497,615,502,503,504,501,505,506,507,514,509,510,511,512,508,513,632,631,614,616,611,612,609,634,893,897,902,894,896,895,898,900,901,903,841,842,839,840,836,837,838,835,656,659,665,668,689,667,648,649,650,653,651,652,690,655,654,691,658,657,695,692,662,664,661,663,660,693,666,694,669,688,685,687,672,679,681,683,682,674,671,675,686,676,673,684,670,677,678,680,696,704,697,698,700,701,702,699,703,733,732,715,706,707,708,714,711,710,712,713,716,709,718,719,720,721,722,723,724,717,730,705,725,726,727,728,729,731,833,832,831,786,784,783,782,781,785,801,802,800,821,818,822,820,819,815,817,814,816,809,813,804,810,811,807,806,805,803,808,812,824,825,823,797,799,789,795,794,790,792,793,791,787,796,798,734,752,747,749,748,750,751,753,735,746,738,739,741,745,740,742,743,744,737,736,853,850,852,849,848,843,851,857,844,847,845,846,856,854,855,834,865,867,868,869,866,872,870,871,864,877,862,884,883,876,878,879,881,882,886,875,885,880,863,873,858,860,861,859,874,890,889,888,887,760,764,769,770,772,758,771,759,754,777,768,765,767,766,755,773,774,775,776,761,762,757,763,756,778,780,779,830,829,828,827,826,1353,910,909,1354,1355,1356,1407,1357,1397,1359,1358,1360,1361,1363,1362,1364,1365,1367,1368,1369,1370,1372,1373,1374,1375,1371,1376,1377,1378,1379,1380,1381,1389,1382,1383,1384,1385,1386,1387,1388,1390,1391,1366,1392,1393,1394,1396,1395,1398,1400,1401,1399,1402,1403,1404,1405,1406,494,1408,493,1409,1411,920,921,1416,1412,1415,1413,490,495,1417,1424,1421,1419,1425,491,1426,1414,1427,905,1410,1428,1429,1430,1431,1420,486,1432,50,51,85,86,87,88,89,90,91,92,93,94,95,97,96,98,99,100,84,134,101,102,103,135,104,105,106,107,108,109,110,111,112,113,114,115,116,118,117,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,907,1433,906,899,1440,1439,488,489,1465,1466,1441,1444,1463,1464,1454,1453,1451,1446,1459,1457,1461,1445,1458,1462,1447,1448,1460,1442,1449,1450,1452,1456,1467,1455,1443,1480,1479,1474,1476,1475,1468,1469,1471,1473,1477,1478,1470,1472,487,492,788,1481,919,1482,913,1492,1483,1484,1485,1486,1487,1488,1489,1490,1491,914,136,640,639,137,1438,1435,1437,1436,1434,644,139,334,307,285,283,333,298,297,198,149,305,306,308,309,310,209,311,282,312,313,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,148,151,152,153,154,155,156,157,158,160,161,159,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,183,182,184,185,186,187,188,189,190,204,192,193,194,195,196,197,199,200,201,202,203,205,206,207,208,210,211,212,213,214,215,216,217,218,219,220,221,222,227,223,224,225,226,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,284,332,269,268,292,291,287,286,288,277,275,290,289,276,278,191,147,146,281,273,274,271,272,270,279,150,299,300,293,296,295,301,302,294,303,304,267,280,929,928,925,931,923,930,927,924,926,942,941,940,934,943,932,936,935,938,939,933,937,944,958,955,957,956,965,966,951,952,954,967,948,950,953,945,946,922,949,962,959,960,961,964,947,963,1030,1029,1051,975,1031,984,974,1092,1182,1128,1336,1179,1335,1334,1181,1032,1135,1131,1331,1303,1254,1255,1256,1268,1261,1260,1262,1263,1267,1265,1295,1292,1291,1293,1306,1304,1305,1300,1269,1270,1273,1271,1272,1274,1275,1278,1276,1277,1279,1280,980,1251,1250,1252,1249,981,1248,1253,1282,1281,1013,1014,1015,1259,1257,1258,972,1011,1301,979,1266,1294,1264,1283,1284,1285,1286,1287,1288,1289,1290,1299,1298,1296,1297,1302,1121,1122,1125,1126,1127,1097,1098,1116,1037,1120,1041,1115,1078,1043,1099,1100,1119,1113,1114,1101,1102,1005,1118,1123,1124,1129,1130,1006,1103,1117,1105,1106,1107,1108,1109,1104,1110,1333,1111,1112,978,1003,1028,1008,1010,1089,1004,1033,1036,1093,1084,1132,1025,1020,1012,1340,1021,1009,1022,1024,1023,1016,1019,1185,1208,1189,1192,1194,1244,1220,1184,1212,1241,1191,1221,1206,1209,1197,1231,1226,1219,1201,1200,1217,1227,1246,1247,1232,1223,1204,1190,1193,1225,1210,1218,1215,1233,1216,1202,1228,1211,1245,1235,1222,1243,1224,1203,1239,1229,1205,1234,1242,1207,1230,1213,1238,1188,1199,1198,1196,1183,1195,1240,1236,1214,1237,1044,1050,1049,1040,1039,1048,1047,1046,1325,1045,1086,1038,1055,1054,1307,1308,1309,1310,1311,1312,1313,1318,1314,1315,1324,1316,1317,1319,1320,1321,1322,1323,1017,1180,1345,1326,1327,1329,1026,1027,1328,1071,983,1173,992,997,1174,1171,1075,1177,1141,1172,1169,1170,1178,1168,1167,993,977,1136,1175,1176,1139,982,999,1072,1002,1001,998,1140,1076,990,1142,995,994,991,1138,969,996,970,971,973,976,968,1018,1137,1000,1096,1337,1095,1338,1339,989,1187,1186,1042,1149,1157,1160,1090,1162,1150,1164,1165,1148,1156,1079,1152,1151,1134,1133,1163,1083,1081,1082,1153,1166,1154,1161,1088,1159,1155,1158,1080,1147,1330,1332,1343,1085,1053,1094,1052,1087,1091,1070,985,1074,1034,1143,1145,1056,987,1341,1007,1146,1073,986,1077,1035,1144,1057,988,1069,1068,1067,1063,1064,1066,1062,1065,1058,1059,1060,1061,1342,1344,47,48,8,9,13,12,2,14,15,16,17,18,19,20,21,3,4,22,49,26,23,24,25,27,28,29,5,30,31,32,33,6,37,34,35,36,38,7,39,44,45,40,41,42,43,1,46,11,10,67,74,66,81,58,57,80,75,78,60,59,55,54,77,56,61,62,65,52,83,82,69,70,72,68,71,76,63,64,73,53,79,891,892,904,908,911,915,917,918,1346,1347,641,1348,1349,1350,912,1351,642,916,1352]},"version":"5.3.2"} \ No newline at end of file diff --git a/src/building-blocks/types/exeptions/application.exception.js.map b/src/building-blocks/types/exeptions/application.exception.js.map index b1c989e..0b6aaa1 100644 --- a/src/building-blocks/types/exeptions/application.exception.js.map +++ b/src/building-blocks/types/exeptions/application.exception.js.map @@ -1 +1 @@ -{"version":3,"file":"application.exception.js","sourceRoot":"","sources":["application.exception.ts"],"names":[],"mappings":";;;AAAA,2CAA4C;AAE5C,MAAa,oBAAqB,SAAQ,KAAK;IAI3C,YACI,OAA2B,EAC3B,aAAqB,mBAAU,CAAC,WAAW,EAC3C,aAAa,GAAG,IAAI,EACpB,KAAK,GAAG,EAAE;QAEV,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;QAC7B,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;QACnC,IAAI,KAAK,EAAE,CAAC;YACR,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;QACvB,CAAC;aAAM,CAAC;YACJ,KAAK,CAAC,iBAAiB,CAAC,IAAI,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC;QACpD,CAAC;IACL,CAAC;CACJ;AAnBD,oDAmBC;AAED,kBAAe,oBAAoB,CAAC"} \ No newline at end of file +{"version":3,"file":"application.exception.js","sourceRoot":"","sources":["application.exception.ts"],"names":[],"mappings":";;;AAAA,2CAA4C;AAE5C,MAAa,oBAAqB,SAAQ,KAAK;IAI7C,YACE,OAA2B,EAC3B,aAAqB,mBAAU,CAAC,WAAW,EAC3C,aAAa,GAAG,IAAI,EACpB,KAAK,GAAG,EAAE;QAEV,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;QAC7B,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;QACnC,IAAI,KAAK,EAAE,CAAC;YACV,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;QACrB,CAAC;aAAM,CAAC;YACN,KAAK,CAAC,iBAAiB,CAAC,IAAI,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC;QAClD,CAAC;IACH,CAAC;CACF;AAnBD,oDAmBC;AAED,kBAAe,oBAAoB,CAAC"} \ No newline at end of file diff --git a/src/building-blocks/types/exeptions/application.exception.ts b/src/building-blocks/types/exeptions/application.exception.ts index 1416c17..f1e16eb 100644 --- a/src/building-blocks/types/exeptions/application.exception.ts +++ b/src/building-blocks/types/exeptions/application.exception.ts @@ -1,24 +1,24 @@ import { HttpStatus } from '@nestjs/common'; export class ApplicationException extends Error { - statusCode: number; - isOperational: boolean; + statusCode: number; + isOperational: boolean; - constructor( - message: string | undefined, - statusCode: number = HttpStatus.BAD_REQUEST, - isOperational = true, - stack = '', - ) { - super(message); - this.statusCode = statusCode; - this.isOperational = isOperational; - if (stack) { - this.stack = stack; - } else { - Error.captureStackTrace(this, this.constructor); - } + constructor( + message: string | undefined, + statusCode: number = HttpStatus.BAD_REQUEST, + isOperational = true, + stack = '' + ) { + super(message); + this.statusCode = statusCode; + this.isOperational = isOperational; + if (stack) { + this.stack = stack; + } else { + Error.captureStackTrace(this, this.constructor); } + } } export default ApplicationException; diff --git a/src/building-blocks/types/exeptions/http-client.exception.js.map b/src/building-blocks/types/exeptions/http-client.exception.js.map index c05793f..cb9d333 100644 --- a/src/building-blocks/types/exeptions/http-client.exception.js.map +++ b/src/building-blocks/types/exeptions/http-client.exception.js.map @@ -1 +1 @@ -{"version":3,"file":"http-client.exception.js","sourceRoot":"","sources":["http-client.exception.ts"],"names":[],"mappings":";;;AAAA,2CAA0C;AAE1C,MAAa,mBAAoB,SAAQ,KAAK;IAI5C,YACE,OAA2B,EAC3B,aAAqB,mBAAU,CAAC,WAAW,EAC3C,aAAa,GAAG,IAAI,EACpB,KAAK,GAAG,EAAE;QAEV,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;QAC7B,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;QACnC,IAAI,KAAK,EAAE,CAAC;YACV,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;QACrB,CAAC;aAAM,CAAC;YACN,KAAK,CAAC,iBAAiB,CAAC,IAAI,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC;QAClD,CAAC;IACH,CAAC;CACF;AAnBD,kDAmBC;AAED,kBAAe,mBAAmB,CAAC"} \ No newline at end of file +{"version":3,"file":"http-client.exception.js","sourceRoot":"","sources":["http-client.exception.ts"],"names":[],"mappings":";;;AAAA,2CAA4C;AAE5C,MAAa,mBAAoB,SAAQ,KAAK;IAI5C,YACE,OAA2B,EAC3B,aAAqB,mBAAU,CAAC,WAAW,EAC3C,aAAa,GAAG,IAAI,EACpB,KAAK,GAAG,EAAE;QAEV,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;QAC7B,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;QACnC,IAAI,KAAK,EAAE,CAAC;YACV,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;QACrB,CAAC;aAAM,CAAC;YACN,KAAK,CAAC,iBAAiB,CAAC,IAAI,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC;QAClD,CAAC;IACH,CAAC;CACF;AAnBD,kDAmBC;AAED,kBAAe,mBAAmB,CAAC"} \ No newline at end of file diff --git a/src/building-blocks/types/exeptions/http-client.exception.ts b/src/building-blocks/types/exeptions/http-client.exception.ts index 9b99a52..39b09ec 100644 --- a/src/building-blocks/types/exeptions/http-client.exception.ts +++ b/src/building-blocks/types/exeptions/http-client.exception.ts @@ -1,4 +1,4 @@ -import {HttpStatus} from "@nestjs/common"; +import { HttpStatus } from '@nestjs/common'; export class HttpClientException extends Error { statusCode: number; diff --git a/src/building-blocks/utils/encryption.js b/src/building-blocks/utils/encryption.js index efb089b..51a420b 100644 --- a/src/building-blocks/utils/encryption.js +++ b/src/building-blocks/utils/encryption.js @@ -15,13 +15,23 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( }) : function(o, v) { o["default"] = v; }); -var __importStar = (this && this.__importStar) || function (mod) { - if (mod && mod.__esModule) return mod; - var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); - __setModuleDefault(result, mod); - return result; -}; +var __importStar = (this && this.__importStar) || (function () { + var ownKeys = function(o) { + ownKeys = Object.getOwnPropertyNames || function (o) { + var ar = []; + for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k; + return ar; + }; + return ownKeys(o); + }; + return function (mod) { + if (mod && mod.__esModule) return mod; + var result = {}; + if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]); + __setModuleDefault(result, mod); + return result; + }; +})(); var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; diff --git a/src/building-blocks/utils/encryption.js.map b/src/building-blocks/utils/encryption.js.map index 84b90cf..9ca55bb 100644 --- a/src/building-blocks/utils/encryption.js.map +++ b/src/building-blocks/utils/encryption.js.map @@ -1 +1 @@ -{"version":3,"file":"encryption.js","sourceRoot":"","sources":["encryption.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wDAA8B;AAC9B,kDAAoC;AACpC,iEAAyC;AAGlC,MAAM,eAAe,GAAG,KAAK,EAAE,QAAgB,EAAE,EAAE;IACxD,MAAM,iBAAiB,GAAG,MAAM,kBAAM,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC;IACzD,OAAO,iBAAiB,CAAC;AAC3B,CAAC,CAAC;AAHW,QAAA,eAAe,mBAG1B;AAEK,MAAM,eAAe,GAAG,KAAK,EAAE,QAAgB,EAAE,YAAoB,EAAE,EAAE;IAC9E,OAAO,kBAAM,CAAC,OAAO,CAAC,QAAQ,EAAE,YAAY,CAAC,CAAC;AAChD,CAAC,CAAC;AAFW,QAAA,eAAe,mBAE1B;AAEK,MAAM,eAAe,GAAG,KAAK,IAAqB,EAAE;IACzD,MAAM,QAAQ,GAAG;QACf,MAAM,EAAE,UAAU;QAClB,MAAM,EAAE,CAAC,MAAM,EAAE,OAAO,CAAC;KAC1B,CAAC;IACF,OAAO,GAAG,CAAC,IAAI,CAAC,QAAQ,EAAE,iBAAO,CAAC,GAAG,CAAC,MAAM,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;AACrE,CAAC,CAAC;AANW,QAAA,eAAe,mBAM1B"} \ No newline at end of file +{"version":3,"file":"encryption.js","sourceRoot":"","sources":["encryption.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wDAA8B;AAC9B,kDAAoC;AACpC,iEAAyC;AAGlC,MAAM,eAAe,GAAG,KAAK,EAAE,QAAgB,EAAE,EAAE;IACxD,MAAM,iBAAiB,GAAG,MAAM,kBAAM,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC;IACzD,OAAO,iBAAiB,CAAC;AAC3B,CAAC,CAAC;AAHW,QAAA,eAAe,mBAG1B;AAEK,MAAM,eAAe,GAAG,KAAK,EAAE,QAAgB,EAAE,YAAoB,EAAE,EAAE;IAC9E,OAAO,kBAAM,CAAC,OAAO,CAAC,QAAQ,EAAE,YAAY,CAAC,CAAC;AAChD,CAAC,CAAC;AAFW,QAAA,eAAe,mBAE1B;AAEK,MAAM,eAAe,GAAG,KAAK,IAAqB,EAAE;IACzD,MAAM,QAAQ,GAAG;QACf,MAAM,EAAE,UAAU;QAClB,MAAM,EAAE,CAAC,MAAM,EAAE,OAAO,CAAC;KAC1B,CAAC;IACF,OAAO,GAAG,CAAC,IAAI,CAAC,QAAQ,EAAE,iBAAO,CAAC,GAAG,CAAC,MAAM,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;AACrE,CAAC,CAAC;AANW,QAAA,eAAe,mBAM1B"} \ No newline at end of file diff --git a/src/building-blocks/utils/encryption.ts b/src/building-blocks/utils/encryption.ts index fea27e8..86de1e7 100644 --- a/src/building-blocks/utils/encryption.ts +++ b/src/building-blocks/utils/encryption.ts @@ -1,7 +1,6 @@ import bcrypt from 'bcryptjs'; import * as jwt from 'jsonwebtoken'; -import configs from "../configs/configs"; -import {HttpContext} from "../context/context"; +import configs from '../configs/configs'; export const encryptPassword = async (password: string) => { const encryptedPassword = await bcrypt.hash(password, 8); diff --git a/src/building-blocks/utils/serilization.js.map b/src/building-blocks/utils/serilization.js.map index 1cc9a2d..b6acf6f 100644 --- a/src/building-blocks/utils/serilization.js.map +++ b/src/building-blocks/utils/serilization.js.map @@ -1 +1 @@ -{"version":3,"file":"serilization.js","sourceRoot":"","sources":["serilization.ts"],"names":[],"mappings":";;;AAAO,MAAM,eAAe,GAAG,CAAC,KAAU,EAAU,EAAE;IAClD,IAAI,CAAC;QACD,OAAO,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC;IACjC,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACb,MAAM,IAAI,KAAK,CAAC,yBAAyB,KAAK,EAAE,CAAC,CAAC;IACtD,CAAC;AACL,CAAC,CAAC;AANW,QAAA,eAAe,mBAM1B;AAEK,MAAM,iBAAiB,GAAG,CAAI,KAAa,EAAK,EAAE;IACrD,IAAI,CAAC;QACD,OAAO,IAAI,CAAC,KAAK,CAAC,KAAK,CAAM,CAAC;IAClC,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACb,MAAM,IAAI,KAAK,CAAC,2BAA2B,KAAK,EAAE,CAAC,CAAC;IACxD,CAAC;AACL,CAAC,CAAC;AANW,QAAA,iBAAiB,qBAM5B"} \ No newline at end of file +{"version":3,"file":"serilization.js","sourceRoot":"","sources":["serilization.ts"],"names":[],"mappings":";;;AAAO,MAAM,eAAe,GAAG,CAAC,KAAU,EAAU,EAAE;IACpD,IAAI,CAAC;QACH,OAAO,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC;IAC/B,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,MAAM,IAAI,KAAK,CAAC,yBAAyB,KAAK,EAAE,CAAC,CAAC;IACpD,CAAC;AACH,CAAC,CAAC;AANW,QAAA,eAAe,mBAM1B;AAEK,MAAM,iBAAiB,GAAG,CAAI,KAAa,EAAK,EAAE;IACvD,IAAI,CAAC;QACH,OAAO,IAAI,CAAC,KAAK,CAAC,KAAK,CAAM,CAAC;IAChC,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,MAAM,IAAI,KAAK,CAAC,2BAA2B,KAAK,EAAE,CAAC,CAAC;IACtD,CAAC;AACH,CAAC,CAAC;AANW,QAAA,iBAAiB,qBAM5B"} \ No newline at end of file diff --git a/src/building-blocks/utils/serilization.ts b/src/building-blocks/utils/serilization.ts index ee0b497..b99685e 100644 --- a/src/building-blocks/utils/serilization.ts +++ b/src/building-blocks/utils/serilization.ts @@ -1,15 +1,15 @@ export const serializeObject = (value: any): string => { - try { - return JSON.stringify(value); - } catch (error) { - throw new Error(`Serialization failed: ${error}`); - } + try { + return JSON.stringify(value); + } catch (error) { + throw new Error(`Serialization failed: ${error}`); + } }; export const deserializeObject = (value: string): T => { - try { - return JSON.parse(value) as T; - } catch (error) { - throw new Error(`Deserialization failed: ${error}`); - } + try { + return JSON.parse(value) as T; + } catch (error) { + throw new Error(`Deserialization failed: ${error}`); + } }; diff --git a/src/building-blocks/utils/time.js b/src/building-blocks/utils/time.js index c333b33..ce26c68 100644 --- a/src/building-blocks/utils/time.js +++ b/src/building-blocks/utils/time.js @@ -1,10 +1,9 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.sleep = void 0; +exports.sleep = sleep; function sleep(ms) { return new Promise((resolve) => { setTimeout(resolve, ms); }); } -exports.sleep = sleep; //# sourceMappingURL=time.js.map \ No newline at end of file diff --git a/src/building-blocks/utils/time.js.map b/src/building-blocks/utils/time.js.map index f7767d4..7538f3a 100644 --- a/src/building-blocks/utils/time.js.map +++ b/src/building-blocks/utils/time.js.map @@ -1 +1 @@ -{"version":3,"file":"time.js","sourceRoot":"","sources":["time.ts"],"names":[],"mappings":";;;AAAA,SAAgB,KAAK,CAAC,EAAU;IAC9B,OAAO,IAAI,OAAO,CAAO,CAAC,OAAO,EAAE,EAAE;QACnC,UAAU,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC;IAC1B,CAAC,CAAC,CAAC;AACL,CAAC;AAJD,sBAIC"} \ No newline at end of file +{"version":3,"file":"time.js","sourceRoot":"","sources":["time.ts"],"names":[],"mappings":";;AAAA,sBAIC;AAJD,SAAgB,KAAK,CAAC,EAAU;IAC9B,OAAO,IAAI,OAAO,CAAO,CAAC,OAAO,EAAE,EAAE;QACnC,UAAU,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC;IAC1B,CAAC,CAAC,CAAC;AACL,CAAC"} \ No newline at end of file diff --git a/src/flight/.eslintrc.js b/src/flight/.eslintrc.js deleted file mode 100644 index b88d1be..0000000 --- a/src/flight/.eslintrc.js +++ /dev/null @@ -1,25 +0,0 @@ -module.exports = { - parser: '@typescript-eslint/parser', - parserOptions: { - project: 'tsconfig.json', - sourceType: 'module', - }, - plugins: ['@typescript-eslint/eslint-plugin'], - extends: [ - 'plugin:@typescript-eslint/recommended', - 'plugin:prettier/recommended', - ], - root: true, - env: { - node: true, - jest: true, - }, - ignorePatterns: ['.eslintrc.js'], - rules: { - '@typescript-eslint/interface-name-prefix': 'off', - '@typescript-eslint/explicit-function-return-type': 'off', - '@typescript-eslint/explicit-module-boundary-types': 'off', - '@typescript-eslint/no-explicit-any': 'off', - "@typescript-eslint/no-var-requires": "off" - }, -}; diff --git a/src/flight/.prettierignore b/src/flight/.prettierignore new file mode 100644 index 0000000..a7db0d7 --- /dev/null +++ b/src/flight/.prettierignore @@ -0,0 +1,3 @@ +node_modules/ +dist/ +build/ \ No newline at end of file diff --git a/src/flight/.prettierrc b/src/flight/.prettierrc index f4f39af..c6f2a11 100644 --- a/src/flight/.prettierrc +++ b/src/flight/.prettierrc @@ -1,5 +1,7 @@ { - "singleQuote": true, - "trailingComma": "all", - "tabWidth": 4 -} + "semi": true, + "tabWidth": 2, + "printWidth": 100, + "singleQuote": true, + "trailingComma": "none" +} \ No newline at end of file diff --git a/src/flight/eslint.config.js b/src/flight/eslint.config.js new file mode 100644 index 0000000..53c4d9d --- /dev/null +++ b/src/flight/eslint.config.js @@ -0,0 +1,12 @@ +// https://denar90.github.io/eslint.github.io/docs/rules/ +export default [ + { + rules: { + semi: 'error', + 'prefer-const': 'warn', + 'no-unused-vars': 'warn', + 'no-debugger': 'warn', + 'no-console': 'warn' + } + } +]; diff --git a/src/flight/nest-cli.json b/src/flight/nest-cli.json index 2e1000f..cca62fd 100644 --- a/src/flight/nest-cli.json +++ b/src/flight/nest-cli.json @@ -1,7 +1,8 @@ { "collection": "@nestjs/schematics", - "sourceRoot": "src", + "sourceRoot": "flight/src", + "entryFile": "main", "compilerOptions": { "plugins": ["@nestjs/swagger/plugin"] } -} +} \ No newline at end of file diff --git a/src/flight/package.json b/src/flight/package.json index 0a7f273..5887e61 100644 --- a/src/flight/package.json +++ b/src/flight/package.json @@ -3,13 +3,13 @@ "description": "flight service", "version": "1.0.0", "main": "src/main.ts", - "author": "Meysam Hadeli", + "author": "Meysam", "license": "MIT", "scripts": { "build": "nest build", - "dev": "tsc -p tsconfig.json && nodemon src/main.ts --watch", - "format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"", - "lint": "eslint \"{src,apps,libs,test}/**/*.ts\" --fix", + "dev": "nest start --watch", + "format": "prettier --write \"**/*.{ts,js}\"", + "lint": "eslint . --fix", "typeorm": "npm run build && npx typeorm -d ./dist/data/data-source.js", "migration:generate": "npm run typeorm -- migration:generate", "migration:run": "npm run typeorm -- migration:run", @@ -17,39 +17,41 @@ "test": "jest" }, "dependencies": { - "@nestjs/cli": "10.2.1", - "@nestjs/config": "^3.1.1", - "@nestjs/core": "10.2.10", - "@nestjs/cqrs": "^10.2.6", + "@nestjs/cli": "10.4.9", + "@nestjs/config": "^3.3.0", + "@nestjs/core": "10.4.15", + "@nestjs/cqrs": "^10.2.8", "@nestjs/jwt": "^10.2.0", - "@nestjs/mapped-types": "2.0.4", - "@nestjs/microservices": "^10.2.10", - "@nestjs/passport": "^10.0.2", - "@nestjs/platform-express": "^10.2.10", - "@nestjs/schematics": "10.0.3", - "@nestjs/swagger": "^7.1.16", - "@nestjs/terminus": "^10.1.1", - "@nestjs/testing": "10.2.10", - "@nestjs/typeorm": "^10.0.1", + "@nestjs/mapped-types": "2.0.6", + "@nestjs/microservices": "^10.4.15", + "@nestjs/passport": "^10.0.3", + "@nestjs/platform-express": "^10.4.15", + "@nestjs/schematics": "10.2.3", + "@nestjs/swagger": "^8.1.0", + "@nestjs/terminus": "^10.2.3", + "@nestjs/testing": "10.4.15", + "@nestjs/typeorm": "^10.0.2", "building-blocks": "file:../building-blocks", "class-transformer": "^0.5.1", - "class-validator": "^0.14.0", - "joi": "^17.10.1", - "moment": "^2.29.4", - "nodemon": "^3.0.2", - "pg": "^8.11.3", - "testcontainers": "^10.3.2", + "class-validator": "^0.14.1", + "joi": "^17.13.3", + "moment": "^2.30.1", + "nodemon": "^3.1.9", + "pg": "^8.13.1", + "testcontainers": "^10.16.0", "ts-mapper": "^1.2.4" }, "devDependencies": { - "@faker-js/faker": "^8.3.1", - "@types/express": "^4.17.21", - "@types/jest": "29.5.10", - "@types/supertest": "2.0.16", + "@faker-js/faker": "^9.3.0", + "@types/express": "^5.0.0", + "@types/jest": "29.5.14", + "@types/supertest": "6.0.2", "jest": "29.7.0", "jest-serial-runner": "^1.2.1", - "supertest": "6.3.3", - "ts-jest": "29.1.1", - "typemoq": "^2.1.0" + "supertest": "7.0.0", + "ts-jest": "29.2.5", + "typemoq": "^2.1.0", + "prettier": "3.4.2", + "eslint": "9.17.0" } } diff --git a/src/flight/src/aircraft/aircraft.module.ts b/src/flight/src/aircraft/aircraft.module.ts index 31798e8..2cf3bf2 100644 --- a/src/flight/src/aircraft/aircraft.module.ts +++ b/src/flight/src/aircraft/aircraft.module.ts @@ -1,21 +1,24 @@ -import {Module} from '@nestjs/common'; -import {CqrsModule} from '@nestjs/cqrs'; -import {TypeOrmModule} from '@nestjs/typeorm'; -import {Aircraft} from "./entities/aircraft.entity"; -import {AircraftRepository} from "../data/repositories/aircraftRepository"; -import {CreateAircraftController, CreateAircraftHandler} from "./features/v1/create-aircraft/create-aircraft"; -import {RabbitmqModule} from "building-blocks/rabbitmq/rabbitmq.module"; +import { Module } from '@nestjs/common'; +import { CqrsModule } from '@nestjs/cqrs'; +import { TypeOrmModule } from '@nestjs/typeorm'; +import { Aircraft } from './entities/aircraft.entity'; +import { AircraftRepository } from '../data/repositories/aircraftRepository'; +import { + CreateAircraftController, + CreateAircraftHandler +} from './features/v1/create-aircraft/create-aircraft'; +import { RabbitmqModule } from 'building-blocks/rabbitmq/rabbitmq.module'; @Module({ - imports: [CqrsModule, RabbitmqModule.forRoot(), TypeOrmModule.forFeature([Aircraft])], - controllers: [CreateAircraftController], - providers: [ - CreateAircraftHandler, - { - provide: 'IAircraftRepository', - useClass: AircraftRepository, - } - ], - exports: [], + imports: [CqrsModule, RabbitmqModule.forRoot(), TypeOrmModule.forFeature([Aircraft])], + controllers: [CreateAircraftController], + providers: [ + CreateAircraftHandler, + { + provide: 'IAircraftRepository', + useClass: AircraftRepository + } + ], + exports: [] }) export class AircraftModule {} diff --git a/src/flight/src/aircraft/entities/aircraft.entity.ts b/src/flight/src/aircraft/entities/aircraft.entity.ts index c84e821..dc19b54 100644 --- a/src/flight/src/aircraft/entities/aircraft.entity.ts +++ b/src/flight/src/aircraft/entities/aircraft.entity.ts @@ -1,5 +1,5 @@ import { Entity, Column, PrimaryGeneratedColumn, OneToMany, ManyToOne } from 'typeorm'; -import {Flight} from "../../flight/entities/flight.entity"; +import { Flight } from '../../flight/entities/flight.entity'; @Entity() export class Aircraft { diff --git a/src/flight/src/aircraft/features/v1/create-aircraft/create-aircraft.ts b/src/flight/src/aircraft/features/v1/create-aircraft/create-aircraft.ts index cd40ba7..4d209a9 100644 --- a/src/flight/src/aircraft/features/v1/create-aircraft/create-aircraft.ts +++ b/src/flight/src/aircraft/features/v1/create-aircraft/create-aircraft.ts @@ -1,108 +1,117 @@ import Joi from 'joi'; -import {IAircraftRepository} from '../../../../data/repositories/aircraftRepository'; -import {ApiBearerAuth, ApiProperty, ApiResponse, ApiTags} from "@nestjs/swagger"; -import {Body, ConflictException, Controller, HttpStatus, Inject, Post, Res, UseGuards} from "@nestjs/common"; -import {AircraftDto} from "../../../dtos/aircraft.dto"; -import {CommandBus, CommandHandler, ICommandHandler} from "@nestjs/cqrs"; -import {Response} from "express"; -import {Aircraft} from "../../../entities/aircraft.entity"; -import {JwtGuard} from "building-blocks/passport/jwt.guard"; -import {IRabbitmqPublisher} from "building-blocks/rabbitmq/rabbitmq-publisher"; -import {AircraftCreated} from "building-blocks/contracts/flight.contract"; -import mapper from "../../../mappings"; +import { IAircraftRepository } from '../../../../data/repositories/aircraftRepository'; +import { ApiBearerAuth, ApiProperty, ApiResponse, ApiTags } from '@nestjs/swagger'; +import { + Body, + ConflictException, + Controller, + HttpStatus, + Inject, + Post, + Res, + UseGuards +} from '@nestjs/common'; +import { AircraftDto } from '../../../dtos/aircraft.dto'; +import { CommandBus, CommandHandler, ICommandHandler } from '@nestjs/cqrs'; +import { Response } from 'express'; +import { Aircraft } from '../../../entities/aircraft.entity'; +import { JwtGuard } from 'building-blocks/passport/jwt.guard'; +import { IRabbitmqPublisher } from 'building-blocks/rabbitmq/rabbitmq-publisher'; +import { AircraftCreated } from 'building-blocks/contracts/flight.contract'; +import mapper from '../../../mappings'; export class CreateAircraft { - model: string; - name: string; - manufacturingYear: number; + model: string; + name: string; + manufacturingYear: number; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } export class CreateAircraftRequestDto { - @ApiProperty() - model: string; + @ApiProperty() + model: string; - @ApiProperty() - name: string; + @ApiProperty() + name: string; - @ApiProperty() - manufacturingYear: number; + @ApiProperty() + manufacturingYear: number; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } const createAircraftValidations = Joi.object({ - model: Joi.string().required(), - manufacturingYear: Joi.number().required(), - name: Joi.string().required() + model: Joi.string().required(), + manufacturingYear: Joi.number().required(), + name: Joi.string().required() }); @ApiBearerAuth() @ApiTags('Aircrafts') @Controller({ - path: `/aircraft`, - version: '1', + path: `/aircraft`, + version: '1' }) export class CreateAircraftController { - - constructor(private readonly commandBus: CommandBus) { - } - - @Post('create') - @UseGuards(JwtGuard) - @ApiResponse({status: 401, description: 'UNAUTHORIZED'}) - @ApiResponse({status: 400, description: 'BAD_REQUEST'}) - @ApiResponse({status: 403, description: 'FORBIDDEN'}) - @ApiResponse({status: 201, description: 'CREATED'}) - public async createAircraft(@Body() request: CreateAircraftRequestDto, @Res() res: Response): Promise { - const result = await this.commandBus.execute( - new CreateAircraft({ - model: request.model, - name: request.name, - manufacturingYear: request.manufacturingYear - }) - ); - - res.status(HttpStatus.CREATED).send(result); - - return result; - } + constructor(private readonly commandBus: CommandBus) {} + + @Post('create') + @UseGuards(JwtGuard) + @ApiResponse({ status: 401, description: 'UNAUTHORIZED' }) + @ApiResponse({ status: 400, description: 'BAD_REQUEST' }) + @ApiResponse({ status: 403, description: 'FORBIDDEN' }) + @ApiResponse({ status: 201, description: 'CREATED' }) + public async createAircraft( + @Body() request: CreateAircraftRequestDto, + @Res() res: Response + ): Promise { + const result = await this.commandBus.execute( + new CreateAircraft({ + model: request.model, + name: request.name, + manufacturingYear: request.manufacturingYear + }) + ); + + res.status(HttpStatus.CREATED).send(result); + + return result; + } } @CommandHandler(CreateAircraft) export class CreateAircraftHandler implements ICommandHandler { - constructor( - @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, - @Inject('IAircraftRepository') private readonly aircraftRepository: IAircraftRepository, - ) { - } + constructor( + @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, + @Inject('IAircraftRepository') private readonly aircraftRepository: IAircraftRepository + ) {} - async execute(command: CreateAircraft): Promise { - await createAircraftValidations.validateAsync(command); + async execute(command: CreateAircraft): Promise { + await createAircraftValidations.validateAsync(command); - const existAircraft = await this.aircraftRepository.findAircraftByName(command.name); + const existAircraft = await this.aircraftRepository.findAircraftByName(command.name); - if (existAircraft) { - throw new ConflictException('Aircraft already taken'); - } + if (existAircraft) { + throw new ConflictException('Aircraft already taken'); + } - const aircraftEntity = await this.aircraftRepository.createAircraft( - new Aircraft({ - name: command.name, - manufacturingYear: command.manufacturingYear, - model: command.model - }) - ); + const aircraftEntity = await this.aircraftRepository.createAircraft( + new Aircraft({ + name: command.name, + manufacturingYear: command.manufacturingYear, + model: command.model + }) + ); - await this.rabbitmqPublisher.publishMessage(new AircraftCreated(aircraftEntity)); + await this.rabbitmqPublisher.publishMessage(new AircraftCreated(aircraftEntity)); - const result = mapper.map(aircraftEntity, new AircraftDto()); + const result = mapper.map(aircraftEntity, new AircraftDto()); - return result; - } + return result; + } } diff --git a/src/flight/src/aircraft/mappings.ts b/src/flight/src/aircraft/mappings.ts index b4d1529..3fa1d3f 100644 --- a/src/flight/src/aircraft/mappings.ts +++ b/src/flight/src/aircraft/mappings.ts @@ -1,6 +1,6 @@ import { TypeMapper } from 'ts-mapper'; -import {AircraftDto} from "./dtos/aircraft.dto"; -import {Aircraft} from "./entities/aircraft.entity"; +import { AircraftDto } from './dtos/aircraft.dto'; +import { Aircraft } from './entities/aircraft.entity'; export class Mapper extends TypeMapper { constructor() { diff --git a/src/flight/src/airport/airport.module.ts b/src/flight/src/airport/airport.module.ts index 9a23260..1728712 100644 --- a/src/flight/src/airport/airport.module.ts +++ b/src/flight/src/airport/airport.module.ts @@ -1,21 +1,24 @@ -import {Module} from '@nestjs/common'; -import {CqrsModule} from '@nestjs/cqrs'; -import {TypeOrmModule} from '@nestjs/typeorm'; -import {Airport} from "./entities/airport.entity"; -import {AirportRepository} from "../data/repositories/airportRepository"; -import {CreateAirportController, CreateAirportHandler} from "./features/v1/create-airport/create-airport"; -import {RabbitmqModule} from "building-blocks/rabbitmq/rabbitmq.module"; +import { Module } from '@nestjs/common'; +import { CqrsModule } from '@nestjs/cqrs'; +import { TypeOrmModule } from '@nestjs/typeorm'; +import { Airport } from './entities/airport.entity'; +import { AirportRepository } from '../data/repositories/airportRepository'; +import { + CreateAirportController, + CreateAirportHandler +} from './features/v1/create-airport/create-airport'; +import { RabbitmqModule } from 'building-blocks/rabbitmq/rabbitmq.module'; @Module({ - imports: [CqrsModule, RabbitmqModule.forRoot(), TypeOrmModule.forFeature([Airport])], - controllers: [CreateAirportController], - providers: [ - CreateAirportHandler, - { - provide: 'IAirportRepository', - useClass: AirportRepository, - } - ], - exports: [], + imports: [CqrsModule, RabbitmqModule.forRoot(), TypeOrmModule.forFeature([Airport])], + controllers: [CreateAirportController], + providers: [ + CreateAirportHandler, + { + provide: 'IAirportRepository', + useClass: AirportRepository + } + ], + exports: [] }) export class AirportModule {} diff --git a/src/flight/src/airport/entities/airport.entity.ts b/src/flight/src/airport/entities/airport.entity.ts index 760703e..6c97612 100644 --- a/src/flight/src/airport/entities/airport.entity.ts +++ b/src/flight/src/airport/entities/airport.entity.ts @@ -1,5 +1,5 @@ import { Entity, Column, PrimaryGeneratedColumn, OneToMany, ManyToOne } from 'typeorm'; -import {Flight} from "../../flight/entities/flight.entity"; +import { Flight } from '../../flight/entities/flight.entity'; @Entity() export class Airport { diff --git a/src/flight/src/airport/features/v1/create-airport/create-airport.ts b/src/flight/src/airport/features/v1/create-airport/create-airport.ts index 1691cd1..39b31e2 100644 --- a/src/flight/src/airport/features/v1/create-airport/create-airport.ts +++ b/src/flight/src/airport/features/v1/create-airport/create-airport.ts @@ -1,108 +1,117 @@ import Joi from 'joi'; -import {IAirportRepository} from '../../../../data/repositories/airportRepository'; -import {ApiBearerAuth, ApiProperty, ApiResponse, ApiTags} from "@nestjs/swagger"; -import {Body, ConflictException, Controller, HttpStatus, Inject, Post, Res, UseGuards} from "@nestjs/common"; -import {CommandBus, CommandHandler, ICommandHandler} from "@nestjs/cqrs"; -import {AirportDto} from "../../../dtos/airport.dto"; -import {Response} from "express"; -import {Airport} from "../../../entities/airport.entity"; -import {JwtGuard} from "building-blocks/passport/jwt.guard"; -import {IRabbitmqPublisher} from "building-blocks/rabbitmq/rabbitmq-publisher"; -import {AirportCreated} from "building-blocks/contracts/flight.contract"; -import mapper from "../../../mappings"; +import { IAirportRepository } from '../../../../data/repositories/airportRepository'; +import { ApiBearerAuth, ApiProperty, ApiResponse, ApiTags } from '@nestjs/swagger'; +import { + Body, + ConflictException, + Controller, + HttpStatus, + Inject, + Post, + Res, + UseGuards +} from '@nestjs/common'; +import { CommandBus, CommandHandler, ICommandHandler } from '@nestjs/cqrs'; +import { AirportDto } from '../../../dtos/airport.dto'; +import { Response } from 'express'; +import { Airport } from '../../../entities/airport.entity'; +import { JwtGuard } from 'building-blocks/passport/jwt.guard'; +import { IRabbitmqPublisher } from 'building-blocks/rabbitmq/rabbitmq-publisher'; +import { AirportCreated } from 'building-blocks/contracts/flight.contract'; +import mapper from '../../../mappings'; export class CreateAirport { - code: string; - name: string; - address: string; + code: string; + name: string; + address: string; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } export class CreateAirportRequestDto { - @ApiProperty() - code: string; + @ApiProperty() + code: string; - @ApiProperty() - name: string; + @ApiProperty() + name: string; - @ApiProperty() - address: string; + @ApiProperty() + address: string; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } const createAirportValidations = Joi.object({ - code: Joi.string().required(), - address: Joi.string().required(), - name: Joi.string().required() + code: Joi.string().required(), + address: Joi.string().required(), + name: Joi.string().required() }); @ApiBearerAuth() @ApiTags('Airports') @Controller({ - path: `/airport`, - version: '1', + path: `/airport`, + version: '1' }) export class CreateAirportController { - - constructor(private readonly commandBus: CommandBus) { - } - - @Post('create') - @UseGuards(JwtGuard) - @ApiResponse({status: 401, description: 'UNAUTHORIZED'}) - @ApiResponse({status: 400, description: 'BAD_REQUEST'}) - @ApiResponse({status: 403, description: 'FORBIDDEN'}) - @ApiResponse({status: 201, description: 'CREATED'}) - public async createAirport(@Body() request: CreateAirportRequestDto, @Res() res: Response): Promise { - const result = await this.commandBus.execute( - new CreateAirport({ - code: request.code, - name: request.name, - address: request.address - }) - ); - - res.status(HttpStatus.CREATED).send(result); - - return result; - } + constructor(private readonly commandBus: CommandBus) {} + + @Post('create') + @UseGuards(JwtGuard) + @ApiResponse({ status: 401, description: 'UNAUTHORIZED' }) + @ApiResponse({ status: 400, description: 'BAD_REQUEST' }) + @ApiResponse({ status: 403, description: 'FORBIDDEN' }) + @ApiResponse({ status: 201, description: 'CREATED' }) + public async createAirport( + @Body() request: CreateAirportRequestDto, + @Res() res: Response + ): Promise { + const result = await this.commandBus.execute( + new CreateAirport({ + code: request.code, + name: request.name, + address: request.address + }) + ); + + res.status(HttpStatus.CREATED).send(result); + + return result; + } } @CommandHandler(CreateAirport) export class CreateAirportHandler implements ICommandHandler { - constructor( - @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, - @Inject('IAirportRepository') private readonly airportRepository: IAirportRepository, - ) { - } + constructor( + @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, + @Inject('IAirportRepository') private readonly airportRepository: IAirportRepository + ) {} - async execute(command: CreateAirport): Promise { - await createAirportValidations.validateAsync(command); + async execute(command: CreateAirport): Promise { + await createAirportValidations.validateAsync(command); - const existAirport = await this.airportRepository.findAirportByName(command.name); + const existAirport = await this.airportRepository.findAirportByName(command.name); - if (existAirport) { - throw new ConflictException('Airport already taken'); - } + if (existAirport) { + throw new ConflictException('Airport already taken'); + } - const airportEntity = await this.airportRepository.createAirport( - new Airport({ - name: command.name, - code: command.code, - address: command.address - }) - ); + const airportEntity = await this.airportRepository.createAirport( + new Airport({ + name: command.name, + code: command.code, + address: command.address + }) + ); - await this.rabbitmqPublisher.publishMessage(new AirportCreated(airportEntity)); + await this.rabbitmqPublisher.publishMessage(new AirportCreated(airportEntity)); - const result = mapper.map(airportEntity, new AirportDto()); + const result = mapper.map(airportEntity, new AirportDto()); - return result; - } + return result; + } } diff --git a/src/flight/src/airport/mappings.ts b/src/flight/src/airport/mappings.ts index 00f02ba..03299c0 100644 --- a/src/flight/src/airport/mappings.ts +++ b/src/flight/src/airport/mappings.ts @@ -1,6 +1,6 @@ import { TypeMapper } from 'ts-mapper'; -import {AirportDto} from "./dtos/airport.dto"; -import {Airport} from "./entities/airport.entity"; +import { AirportDto } from './dtos/airport.dto'; +import { Airport } from './entities/airport.entity'; export class Mapper extends TypeMapper { constructor() { diff --git a/src/flight/src/app.module.ts b/src/flight/src/app.module.ts index 1319046..36efe26 100644 --- a/src/flight/src/app.module.ts +++ b/src/flight/src/app.module.ts @@ -1,66 +1,61 @@ -import {MiddlewareConsumer, Module, NestModule, OnApplicationBootstrap} from '@nestjs/common'; -import {RouterModule} from '@nestjs/core'; -import {TypeOrmModule} from '@nestjs/typeorm'; -import {postgresOptions} from './data/data-source'; -import {PassportModule} from "@nestjs/passport"; -import {JwtModule} from "@nestjs/jwt"; -import {FlightModule} from "./flight/flight.module"; -import {AircraftModule} from "./aircraft/aircraft.module"; -import {AirportModule} from "./airport/airport.module"; -import {SeatModule} from "./seat/seat.module"; -import {DataSeeder} from "./data/seeds/data-seeder"; -import {OpenTelemetryModule} from "building-blocks/openTelemetry/open-telemetry.module"; -import {JwtStrategy} from "building-blocks/passport/jwt.strategy"; -import configs from "building-blocks/configs/configs"; -import {HttpContextMiddleware} from "building-blocks/context/context"; +import { MiddlewareConsumer, Module, NestModule, OnApplicationBootstrap } from '@nestjs/common'; +import { RouterModule } from '@nestjs/core'; +import { TypeOrmModule } from '@nestjs/typeorm'; +import { postgresOptions } from './data/data-source'; +import { PassportModule } from '@nestjs/passport'; +import { JwtModule } from '@nestjs/jwt'; +import { FlightModule } from './flight/flight.module'; +import { AircraftModule } from './aircraft/aircraft.module'; +import { AirportModule } from './airport/airport.module'; +import { SeatModule } from './seat/seat.module'; +import { DataSeeder } from './data/seeds/data-seeder'; +import { OpenTelemetryModule } from 'building-blocks/openTelemetry/open-telemetry.module'; +import { JwtStrategy } from 'building-blocks/passport/jwt.strategy'; +import configs from 'building-blocks/configs/configs'; +import { HttpContextMiddleware } from 'building-blocks/context/context'; @Module({ - imports: [ - PassportModule, - JwtModule.register({ - secret: configs.jwt.secret, - signOptions: {expiresIn: configs.jwt.refreshExpirationDays}, - }), - OpenTelemetryModule.forRoot(), - TypeOrmModule.forRoot(postgresOptions), - FlightModule, - AircraftModule, - AirportModule, - SeatModule, - RouterModule.register([ - { - path: '/', - module: FlightModule, - }, - { - path: '/', - module: AircraftModule, - }, - { - path: '/', - module: AirportModule, - }, - { - path: '/', - module: SeatModule, - }, - ]), - ], - providers: [JwtStrategy, DataSeeder], + imports: [ + PassportModule, + JwtModule.register({ + secret: configs.jwt.secret, + signOptions: { expiresIn: configs.jwt.refreshExpirationDays } + }), + OpenTelemetryModule.forRoot(), + TypeOrmModule.forRoot(postgresOptions), + FlightModule, + AircraftModule, + AirportModule, + SeatModule, + RouterModule.register([ + { + path: '/', + module: FlightModule + }, + { + path: '/', + module: AircraftModule + }, + { + path: '/', + module: AirportModule + }, + { + path: '/', + module: SeatModule + } + ]) + ], + providers: [JwtStrategy, DataSeeder] }) export class AppModule implements OnApplicationBootstrap, NestModule { - constructor( - private readonly dataSeeder: DataSeeder, - ) { - } + constructor(private readonly dataSeeder: DataSeeder) {} - configure(consumer: MiddlewareConsumer) { - consumer - .apply(HttpContextMiddleware) - .forRoutes('*'); - } + configure(consumer: MiddlewareConsumer) { + consumer.apply(HttpContextMiddleware).forRoutes('*'); + } - async onApplicationBootstrap(): Promise { - await this.dataSeeder.seedAsync(); - } -} \ No newline at end of file + async onApplicationBootstrap(): Promise { + await this.dataSeeder.seedAsync(); + } +} diff --git a/src/flight/src/data/data-source.ts b/src/flight/src/data/data-source.ts index a947efd..9c1b125 100644 --- a/src/flight/src/data/data-source.ts +++ b/src/flight/src/data/data-source.ts @@ -1,19 +1,19 @@ import { DataSource, DataSourceOptions } from 'typeorm'; -import configs from "building-blocks/configs/configs"; +import configs from 'building-blocks/configs/configs'; // use this file for running migration export const postgresOptions: DataSourceOptions = { - type: 'postgres', - host: configs.postgres.host, - port: configs.postgres.port, - username: configs.postgres.username, - password: configs.postgres.password, - database: configs.postgres.database, - synchronize: configs.postgres.synchronize, - entities: [__dirname + configs.postgres.entities], - migrations: [__dirname + configs.postgres.migrations], - logging: configs.postgres.logging, - migrationsRun: configs.postgres.migrationsRun + type: 'postgres', + host: configs.postgres.host, + port: configs.postgres.port, + username: configs.postgres.username, + password: configs.postgres.password, + database: configs.postgres.database, + synchronize: configs.postgres.synchronize, + entities: [__dirname + configs.postgres.entities], + migrations: [__dirname + configs.postgres.migrations], + logging: configs.postgres.logging, + migrationsRun: configs.postgres.migrationsRun }; const dataSource = new DataSource(postgresOptions); diff --git a/src/flight/src/data/migrations/1702506607390-create-flight-table.ts b/src/flight/src/data/migrations/1702506607390-create-flight-table.ts index 70fa1fe..82a50a8 100644 --- a/src/flight/src/data/migrations/1702506607390-create-flight-table.ts +++ b/src/flight/src/data/migrations/1702506607390-create-flight-table.ts @@ -1,34 +1,61 @@ -import { MigrationInterface, QueryRunner } from "typeorm"; +import { MigrationInterface, QueryRunner } from 'typeorm'; export class CreateFlightTable1702506607390 implements MigrationInterface { - name = 'CreateFlightTable1702506607390' + name = 'CreateFlightTable1702506607390'; - public async up(queryRunner: QueryRunner): Promise { - await queryRunner.query(`CREATE TABLE "aircraft" ("id" SERIAL NOT NULL, "name" character varying NOT NULL, "model" character varying NOT NULL, "manufacturingYear" integer NOT NULL, "createdAt" TIMESTAMP NOT NULL, "updatedAt" TIMESTAMP, CONSTRAINT "PK_46f8c680e9ff88a752b7834bba4" PRIMARY KEY ("id"))`); - await queryRunner.query(`CREATE TABLE "airport" ("id" SERIAL NOT NULL, "name" character varying NOT NULL, "address" character varying NOT NULL, "code" character varying NOT NULL, "createdAt" TIMESTAMP NOT NULL, "updatedAt" TIMESTAMP, CONSTRAINT "PK_ea1ecba8dec9bee0cb60194e788" PRIMARY KEY ("id"))`); - await queryRunner.query(`CREATE TYPE "public"."seat_seatclass_enum" AS ENUM('0', '1', '2', '3')`); - await queryRunner.query(`CREATE TYPE "public"."seat_seattype_enum" AS ENUM('0', '1', '2', '3')`); - await queryRunner.query(`CREATE TABLE "seat" ("id" SERIAL NOT NULL, "seatNumber" character varying NOT NULL, "seatClass" "public"."seat_seatclass_enum" NOT NULL DEFAULT '0', "seatType" "public"."seat_seattype_enum" NOT NULL DEFAULT '0', "flightId" integer NOT NULL, "isReserved" boolean NOT NULL DEFAULT false, "createdAt" TIMESTAMP NOT NULL, "updatedAt" TIMESTAMP, CONSTRAINT "PK_4e72ae40c3fbd7711ccb380ac17" PRIMARY KEY ("id"))`); - await queryRunner.query(`CREATE TYPE "public"."flight_flightstatus_enum" AS ENUM('0', '1', '2', '3', '4')`); - await queryRunner.query(`CREATE TABLE "flight" ("id" SERIAL NOT NULL, "flightNumber" character varying NOT NULL, "price" integer NOT NULL, "flightStatus" "public"."flight_flightstatus_enum" NOT NULL DEFAULT '0', "flightDate" TIMESTAMP NOT NULL, "departureDate" TIMESTAMP NOT NULL, "departureAirportId" integer NOT NULL, "aircraftId" integer NOT NULL, "arriveDate" TIMESTAMP NOT NULL, "arriveAirportId" integer NOT NULL, "durationMinutes" integer NOT NULL, "createdAt" TIMESTAMP NOT NULL, "updatedAt" TIMESTAMP, CONSTRAINT "PK_bf571ce6731cf071fc51b94df03" PRIMARY KEY ("id"))`); - await queryRunner.query(`ALTER TABLE "seat" ADD CONSTRAINT "FK_5298809d13db3c04e6bf460e207" FOREIGN KEY ("flightId") REFERENCES "flight"("id") ON DELETE NO ACTION ON UPDATE NO ACTION`); - await queryRunner.query(`ALTER TABLE "flight" ADD CONSTRAINT "FK_df523f694abea3ed793a8aef725" FOREIGN KEY ("aircraftId") REFERENCES "aircraft"("id") ON DELETE NO ACTION ON UPDATE NO ACTION`); - await queryRunner.query(`ALTER TABLE "flight" ADD CONSTRAINT "FK_3a0c5e1517f31f39132ab8ed209" FOREIGN KEY ("departureAirportId") REFERENCES "airport"("id") ON DELETE NO ACTION ON UPDATE NO ACTION`); - await queryRunner.query(`ALTER TABLE "flight" ADD CONSTRAINT "FK_e4908c3ca75113e71befdfe36a1" FOREIGN KEY ("arriveAirportId") REFERENCES "airport"("id") ON DELETE NO ACTION ON UPDATE NO ACTION`); - } - - public async down(queryRunner: QueryRunner): Promise { - await queryRunner.query(`ALTER TABLE "flight" DROP CONSTRAINT "FK_e4908c3ca75113e71befdfe36a1"`); - await queryRunner.query(`ALTER TABLE "flight" DROP CONSTRAINT "FK_3a0c5e1517f31f39132ab8ed209"`); - await queryRunner.query(`ALTER TABLE "flight" DROP CONSTRAINT "FK_df523f694abea3ed793a8aef725"`); - await queryRunner.query(`ALTER TABLE "seat" DROP CONSTRAINT "FK_5298809d13db3c04e6bf460e207"`); - await queryRunner.query(`DROP TABLE "flight"`); - await queryRunner.query(`DROP TYPE "public"."flight_flightstatus_enum"`); - await queryRunner.query(`DROP TABLE "seat"`); - await queryRunner.query(`DROP TYPE "public"."seat_seattype_enum"`); - await queryRunner.query(`DROP TYPE "public"."seat_seatclass_enum"`); - await queryRunner.query(`DROP TABLE "airport"`); - await queryRunner.query(`DROP TABLE "aircraft"`); - } + public async up(queryRunner: QueryRunner): Promise { + await queryRunner.query( + `CREATE TABLE "aircraft" ("id" SERIAL NOT NULL, "name" character varying NOT NULL, "model" character varying NOT NULL, "manufacturingYear" integer NOT NULL, "createdAt" TIMESTAMP NOT NULL, "updatedAt" TIMESTAMP, CONSTRAINT "PK_46f8c680e9ff88a752b7834bba4" PRIMARY KEY ("id"))` + ); + await queryRunner.query( + `CREATE TABLE "airport" ("id" SERIAL NOT NULL, "name" character varying NOT NULL, "address" character varying NOT NULL, "code" character varying NOT NULL, "createdAt" TIMESTAMP NOT NULL, "updatedAt" TIMESTAMP, CONSTRAINT "PK_ea1ecba8dec9bee0cb60194e788" PRIMARY KEY ("id"))` + ); + await queryRunner.query( + `CREATE TYPE "public"."seat_seatclass_enum" AS ENUM('0', '1', '2', '3')` + ); + await queryRunner.query( + `CREATE TYPE "public"."seat_seattype_enum" AS ENUM('0', '1', '2', '3')` + ); + await queryRunner.query( + `CREATE TABLE "seat" ("id" SERIAL NOT NULL, "seatNumber" character varying NOT NULL, "seatClass" "public"."seat_seatclass_enum" NOT NULL DEFAULT '0', "seatType" "public"."seat_seattype_enum" NOT NULL DEFAULT '0', "flightId" integer NOT NULL, "isReserved" boolean NOT NULL DEFAULT false, "createdAt" TIMESTAMP NOT NULL, "updatedAt" TIMESTAMP, CONSTRAINT "PK_4e72ae40c3fbd7711ccb380ac17" PRIMARY KEY ("id"))` + ); + await queryRunner.query( + `CREATE TYPE "public"."flight_flightstatus_enum" AS ENUM('0', '1', '2', '3', '4')` + ); + await queryRunner.query( + `CREATE TABLE "flight" ("id" SERIAL NOT NULL, "flightNumber" character varying NOT NULL, "price" integer NOT NULL, "flightStatus" "public"."flight_flightstatus_enum" NOT NULL DEFAULT '0', "flightDate" TIMESTAMP NOT NULL, "departureDate" TIMESTAMP NOT NULL, "departureAirportId" integer NOT NULL, "aircraftId" integer NOT NULL, "arriveDate" TIMESTAMP NOT NULL, "arriveAirportId" integer NOT NULL, "durationMinutes" integer NOT NULL, "createdAt" TIMESTAMP NOT NULL, "updatedAt" TIMESTAMP, CONSTRAINT "PK_bf571ce6731cf071fc51b94df03" PRIMARY KEY ("id"))` + ); + await queryRunner.query( + `ALTER TABLE "seat" ADD CONSTRAINT "FK_5298809d13db3c04e6bf460e207" FOREIGN KEY ("flightId") REFERENCES "flight"("id") ON DELETE NO ACTION ON UPDATE NO ACTION` + ); + await queryRunner.query( + `ALTER TABLE "flight" ADD CONSTRAINT "FK_df523f694abea3ed793a8aef725" FOREIGN KEY ("aircraftId") REFERENCES "aircraft"("id") ON DELETE NO ACTION ON UPDATE NO ACTION` + ); + await queryRunner.query( + `ALTER TABLE "flight" ADD CONSTRAINT "FK_3a0c5e1517f31f39132ab8ed209" FOREIGN KEY ("departureAirportId") REFERENCES "airport"("id") ON DELETE NO ACTION ON UPDATE NO ACTION` + ); + await queryRunner.query( + `ALTER TABLE "flight" ADD CONSTRAINT "FK_e4908c3ca75113e71befdfe36a1" FOREIGN KEY ("arriveAirportId") REFERENCES "airport"("id") ON DELETE NO ACTION ON UPDATE NO ACTION` + ); + } + public async down(queryRunner: QueryRunner): Promise { + await queryRunner.query( + `ALTER TABLE "flight" DROP CONSTRAINT "FK_e4908c3ca75113e71befdfe36a1"` + ); + await queryRunner.query( + `ALTER TABLE "flight" DROP CONSTRAINT "FK_3a0c5e1517f31f39132ab8ed209"` + ); + await queryRunner.query( + `ALTER TABLE "flight" DROP CONSTRAINT "FK_df523f694abea3ed793a8aef725"` + ); + await queryRunner.query(`ALTER TABLE "seat" DROP CONSTRAINT "FK_5298809d13db3c04e6bf460e207"`); + await queryRunner.query(`DROP TABLE "flight"`); + await queryRunner.query(`DROP TYPE "public"."flight_flightstatus_enum"`); + await queryRunner.query(`DROP TABLE "seat"`); + await queryRunner.query(`DROP TYPE "public"."seat_seattype_enum"`); + await queryRunner.query(`DROP TYPE "public"."seat_seatclass_enum"`); + await queryRunner.query(`DROP TABLE "airport"`); + await queryRunner.query(`DROP TABLE "aircraft"`); + } } diff --git a/src/flight/src/data/repositories/aircraftRepository.ts b/src/flight/src/data/repositories/aircraftRepository.ts index ac3f621..8daf6a4 100644 --- a/src/flight/src/data/repositories/aircraftRepository.ts +++ b/src/flight/src/data/repositories/aircraftRepository.ts @@ -1,6 +1,6 @@ import { Repository } from 'typeorm'; -import {Aircraft} from "../../aircraft/entities/aircraft.entity"; -import {InjectRepository} from "@nestjs/typeorm"; +import { Aircraft } from '../../aircraft/entities/aircraft.entity'; +import { InjectRepository } from '@nestjs/typeorm'; export interface IAircraftRepository { createAircraft(aircraft: Aircraft): Promise; @@ -11,9 +11,10 @@ export interface IAircraftRepository { } export class AircraftRepository implements IAircraftRepository { - constructor(@InjectRepository(Aircraft) - private readonly aircraftRepository: Repository) { - } + constructor( + @InjectRepository(Aircraft) + private readonly aircraftRepository: Repository + ) {} async createAircraft(aircraft: Aircraft): Promise { return await this.aircraftRepository.save(aircraft); diff --git a/src/flight/src/data/repositories/airportRepository.ts b/src/flight/src/data/repositories/airportRepository.ts index 2ddf104..88fc481 100644 --- a/src/flight/src/data/repositories/airportRepository.ts +++ b/src/flight/src/data/repositories/airportRepository.ts @@ -1,6 +1,6 @@ import { Repository } from 'typeorm'; -import {InjectRepository} from "@nestjs/typeorm"; -import {Airport} from "../../airport/entities/airport.entity"; +import { InjectRepository } from '@nestjs/typeorm'; +import { Airport } from '../../airport/entities/airport.entity'; export interface IAirportRepository { createAirport(airport: Airport): Promise; @@ -9,9 +9,10 @@ export interface IAirportRepository { } export class AirportRepository implements IAirportRepository { - constructor(@InjectRepository(Airport) - private readonly airportRepository: Repository) { - } + constructor( + @InjectRepository(Airport) + private readonly airportRepository: Repository + ) {} async createAirport(airport: Airport): Promise { return await this.airportRepository.save(airport); diff --git a/src/flight/src/data/repositories/flightRepository.ts b/src/flight/src/data/repositories/flightRepository.ts index 11c4f16..103e764 100644 --- a/src/flight/src/data/repositories/flightRepository.ts +++ b/src/flight/src/data/repositories/flightRepository.ts @@ -1,6 +1,6 @@ import { Repository } from 'typeorm'; -import {InjectRepository} from "@nestjs/typeorm"; -import {Flight} from "../../flight/entities/flight.entity"; +import { InjectRepository } from '@nestjs/typeorm'; +import { Flight } from '../../flight/entities/flight.entity'; export interface IFlightRepository { createFlight(flight: Flight): Promise; @@ -10,9 +10,10 @@ export interface IFlightRepository { } export class FlightRepository implements IFlightRepository { - constructor(@InjectRepository(Flight) - private readonly flightRepository: Repository) { - } + constructor( + @InjectRepository(Flight) + private readonly flightRepository: Repository + ) {} async createFlight(flight: Flight): Promise { return await this.flightRepository.save(flight); diff --git a/src/flight/src/data/repositories/seatRepository.ts b/src/flight/src/data/repositories/seatRepository.ts index 3e85580..0ea3a9c 100644 --- a/src/flight/src/data/repositories/seatRepository.ts +++ b/src/flight/src/data/repositories/seatRepository.ts @@ -1,6 +1,6 @@ import { Repository } from 'typeorm'; -import {InjectRepository} from "@nestjs/typeorm"; -import {Seat} from "../../seat/entities/seat.entity"; +import { InjectRepository } from '@nestjs/typeorm'; +import { Seat } from '../../seat/entities/seat.entity'; export interface ISeatRepository { createSeat(seat: Seat): Promise; @@ -15,16 +15,17 @@ export interface ISeatRepository { } export class SeatRepository implements ISeatRepository { - constructor(@InjectRepository(Seat) - private readonly seatRepository: Repository) { - } + constructor( + @InjectRepository(Seat) + private readonly seatRepository: Repository + ) {} async createSeat(seat: Seat): Promise { return await this.seatRepository.save(seat); } async reserveSeat(seat: Seat): Promise { - await this.seatRepository.update(seat.id, seat); + await this.seatRepository.update(seat.id, seat); } async getAll(): Promise { diff --git a/src/flight/src/data/seeds/data-seeder.ts b/src/flight/src/data/seeds/data-seeder.ts index 3978cb7..82b7ed5 100644 --- a/src/flight/src/data/seeds/data-seeder.ts +++ b/src/flight/src/data/seeds/data-seeder.ts @@ -1,116 +1,109 @@ import { Injectable } from '@nestjs/common'; -import {EntityManager} from "typeorm"; -import {Aircraft} from "../../aircraft/entities/aircraft.entity"; -import {Airport} from "../../airport/entities/airport.entity"; -import {Flight} from "../../flight/entities/flight.entity"; -import {FlightStatus} from "../../flight/enums/flight-status.enum"; -import {Seat} from "../../seat/entities/seat.entity"; -import {SeatClass} from "../../seat/enums/seat-class.enum"; -import {SeatType} from "../../seat/enums/seat-type.enum"; +import { EntityManager } from 'typeorm'; +import { Aircraft } from '../../aircraft/entities/aircraft.entity'; +import { Airport } from '../../airport/entities/airport.entity'; +import { Flight } from '../../flight/entities/flight.entity'; +import { FlightStatus } from '../../flight/enums/flight-status.enum'; +import { Seat } from '../../seat/entities/seat.entity'; +import { SeatClass } from '../../seat/enums/seat-class.enum'; +import { SeatType } from '../../seat/enums/seat-type.enum'; @Injectable() export class DataSeeder { - constructor(private readonly entityManager: EntityManager - ) { - } - - async seedAsync(): Promise { - await this.seedAircraft(); - await this.seedAirport(); - await this.seedFlight(); - await this.seedSeats(); - } + constructor(private readonly entityManager: EntityManager) {} - private async seedAircraft(): Promise { + async seedAsync(): Promise { + await this.seedAircraft(); + await this.seedAirport(); + await this.seedFlight(); + await this.seedSeats(); + } - const aircraftRepository = this.entityManager.getRepository(Aircraft); - if ((await aircraftRepository.find())?.length == 0) { - await aircraftRepository.save([ - new Aircraft({ - id: 1, - name: 'airbus', - manufacturingYear: 2008, - model: '3300' - }), - new Aircraft({ - id: 2, - name: 'fokker', - manufacturingYear: 2002, - model: '2200' - }), - ] - ); - } + private async seedAircraft(): Promise { + const aircraftRepository = this.entityManager.getRepository(Aircraft); + if ((await aircraftRepository.find())?.length == 0) { + await aircraftRepository.save([ + new Aircraft({ + id: 1, + name: 'airbus', + manufacturingYear: 2008, + model: '3300' + }), + new Aircraft({ + id: 2, + name: 'fokker', + manufacturingYear: 2002, + model: '2200' + }) + ]); } + } - private async seedAirport(): Promise { - const airportRepository = this.entityManager.getRepository(Airport); + private async seedAirport(): Promise { + const airportRepository = this.entityManager.getRepository(Airport); - if ((await airportRepository.find())?.length == 0) { - await airportRepository.save([ - new Airport({ - id: 1, - name: 'mehrabad', - code: '1422', - address: 'tehran' - }), - new Airport({ - id: 2, - name: 'kish airport', - code: '1222', - address: 'kish' - }) - ] - ); - } + if ((await airportRepository.find())?.length == 0) { + await airportRepository.save([ + new Airport({ + id: 1, + name: 'mehrabad', + code: '1422', + address: 'tehran' + }), + new Airport({ + id: 2, + name: 'kish airport', + code: '1222', + address: 'kish' + }) + ]); } + } - private async seedFlight(): Promise { + private async seedFlight(): Promise { + const flightRepository = this.entityManager.getRepository(Flight); - const flightRepository = this.entityManager.getRepository(Flight); - - if ((await flightRepository.find())?.length == 0) { - await flightRepository.save( - new Flight({ - id: 1, - flightDate: new Date('2023-09-30'), - flightStatus: FlightStatus.COMPLETED, - flightNumber: '1299', - aircraftId: 1, - price: 800, - departureAirportId: 1, - departureDate: new Date('2023-09-31'), - arriveAirportId: 1, - arriveDate: new Date('2023-09-31'), - durationMinutes: 1000 - }) - ); - } + if ((await flightRepository.find())?.length == 0) { + await flightRepository.save( + new Flight({ + id: 1, + flightDate: new Date('2023-09-30'), + flightStatus: FlightStatus.COMPLETED, + flightNumber: '1299', + aircraftId: 1, + price: 800, + departureAirportId: 1, + departureDate: new Date('2023-09-31'), + arriveAirportId: 1, + arriveDate: new Date('2023-09-31'), + durationMinutes: 1000 + }) + ); } + } - private async seedSeats(): Promise { - - const seatRepository = this.entityManager.getRepository(Seat); + private async seedSeats(): Promise { + const seatRepository = this.entityManager.getRepository(Seat); - if ((await seatRepository.find())?.length == 0) { - const seats: Seat[] = [ - new Seat({ - flightId: 1, - seatNumber: '11A', - seatClass: SeatClass.FIRST_CLASS, - seatType: SeatType.WINDOW - }), - new Seat({ - flightId: 1, - seatNumber: '12B', - seatClass: SeatClass.ECONOMY, - seatType: SeatType.MIDDLE - }) - ]; + if ((await seatRepository.find())?.length == 0) { + const seats: Seat[] = [ + new Seat({ + flightId: 1, + seatNumber: '11A', + seatClass: SeatClass.FIRST_CLASS, + seatType: SeatType.WINDOW + }), + new Seat({ + flightId: 1, + seatNumber: '12B', + seatClass: SeatClass.ECONOMY, + seatType: SeatType.MIDDLE + }) + ]; - for (const seat of seats) { - await seatRepository.save(seat); - } - } + for (const seat of seats) { + await seatRepository.save(seat); + } } + } } diff --git a/src/flight/src/flight/dtos/flight.dto.ts b/src/flight/src/flight/dtos/flight.dto.ts index 0e00f7f..270d018 100644 --- a/src/flight/src/flight/dtos/flight.dto.ts +++ b/src/flight/src/flight/dtos/flight.dto.ts @@ -1,4 +1,4 @@ -import {FlightStatus} from "../enums/flight-status.enum"; +import { FlightStatus } from '../enums/flight-status.enum'; export class FlightDto { id: number; diff --git a/src/flight/src/flight/entities/flight.entity.ts b/src/flight/src/flight/entities/flight.entity.ts index ca10a15..d25e1ea 100644 --- a/src/flight/src/flight/entities/flight.entity.ts +++ b/src/flight/src/flight/entities/flight.entity.ts @@ -1,8 +1,8 @@ import { Entity, Column, PrimaryGeneratedColumn, OneToMany, ManyToOne, JoinColumn } from 'typeorm'; -import {FlightStatus} from "../enums/flight-status.enum"; -import {Aircraft} from "../../aircraft/entities/aircraft.entity"; -import {Airport} from "../../airport/entities/airport.entity"; -import {Seat} from "../../seat/entities/seat.entity"; +import { FlightStatus } from '../enums/flight-status.enum'; +import { Aircraft } from '../../aircraft/entities/aircraft.entity'; +import { Airport } from '../../airport/entities/airport.entity'; +import { Seat } from '../../seat/entities/seat.entity'; @Entity() export class Flight { diff --git a/src/flight/src/flight/features/v1/create-flight/create-flight.ts b/src/flight/src/flight/features/v1/create-flight/create-flight.ts index b898acc..3a4fb75 100644 --- a/src/flight/src/flight/features/v1/create-flight/create-flight.ts +++ b/src/flight/src/flight/features/v1/create-flight/create-flight.ts @@ -1,165 +1,174 @@ import Joi from 'joi'; -import {FlightDto} from '../../../dtos/flight.dto'; -import {IFlightRepository} from '../../../../data/repositories/flightRepository'; -import {ApiBearerAuth, ApiProperty, ApiResponse, ApiTags} from "@nestjs/swagger"; -import {FlightStatus} from "../../../enums/flight-status.enum"; -import {Body, ConflictException, Controller, HttpStatus, Inject, Post, Res, UseGuards} from "@nestjs/common"; -import {CommandBus, CommandHandler, ICommandHandler} from "@nestjs/cqrs"; -import {Response} from "express"; -import {Flight} from "../../../entities/flight.entity"; -import {JwtGuard} from "building-blocks/passport/jwt.guard"; -import {IRabbitmqPublisher} from "building-blocks/rabbitmq/rabbitmq-publisher"; -import {FlightCreated} from "building-blocks/contracts/flight.contract"; -import mapper from "../../../mappings"; +import { FlightDto } from '../../../dtos/flight.dto'; +import { IFlightRepository } from '../../../../data/repositories/flightRepository'; +import { ApiBearerAuth, ApiProperty, ApiResponse, ApiTags } from '@nestjs/swagger'; +import { FlightStatus } from '../../../enums/flight-status.enum'; +import { + Body, + ConflictException, + Controller, + HttpStatus, + Inject, + Post, + Res, + UseGuards +} from '@nestjs/common'; +import { CommandBus, CommandHandler, ICommandHandler } from '@nestjs/cqrs'; +import { Response } from 'express'; +import { Flight } from '../../../entities/flight.entity'; +import { JwtGuard } from 'building-blocks/passport/jwt.guard'; +import { IRabbitmqPublisher } from 'building-blocks/rabbitmq/rabbitmq-publisher'; +import { FlightCreated } from 'building-blocks/contracts/flight.contract'; +import mapper from '../../../mappings'; export class CreateFlight { - flightNumber: string; - price: number; - flightStatus: FlightStatus; - flightDate: Date; - departureDate: Date; - departureAirportId: number; - aircraftId: number; - arriveDate: Date; - arriveAirportId: number; - durationMinutes: number; - - constructor(request: Partial = {}) { - Object.assign(this, request); - } + flightNumber: string; + price: number; + flightStatus: FlightStatus; + flightDate: Date; + departureDate: Date; + departureAirportId: number; + aircraftId: number; + arriveDate: Date; + arriveAirportId: number; + durationMinutes: number; + + constructor(request: Partial = {}) { + Object.assign(this, request); + } } export class CreateFlightRequestDto { - @ApiProperty() - flightNumber: string; + @ApiProperty() + flightNumber: string; - @ApiProperty() - price: number; - @ApiProperty() - flightStatus: FlightStatus; + @ApiProperty() + price: number; + @ApiProperty() + flightStatus: FlightStatus; - @ApiProperty() - flightDate: Date; + @ApiProperty() + flightDate: Date; - @ApiProperty() - departureDate: Date; + @ApiProperty() + departureDate: Date; - @ApiProperty() - departureAirportId: number; + @ApiProperty() + departureAirportId: number; - @ApiProperty() - aircraftId: number; + @ApiProperty() + aircraftId: number; - @ApiProperty() - arriveDate: Date; + @ApiProperty() + arriveDate: Date; - @ApiProperty() - arriveAirportId: number; + @ApiProperty() + arriveAirportId: number; - @ApiProperty() - durationMinutes: number; + @ApiProperty() + durationMinutes: number; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } const createFlightValidations = Joi.object({ - flightNumber: Joi.string().required(), - price: Joi.number().required(), - flightStatus: Joi.string() - .required() - .valid( - FlightStatus.UNKNOWN, - FlightStatus.DELAY, - FlightStatus.CANCELED, - FlightStatus.FLYING, - FlightStatus.COMPLETED - ), - flightDate: Joi.date().required(), - departureDate: Joi.date().required(), - departureAirportId: Joi.number().required(), - aircraftId: Joi.number().required(), - arriveDate: Joi.date().required(), - arriveAirportId: Joi.number().required(), - durationMinutes: Joi.number().required() + flightNumber: Joi.string().required(), + price: Joi.number().required(), + flightStatus: Joi.string() + .required() + .valid( + FlightStatus.UNKNOWN, + FlightStatus.DELAY, + FlightStatus.CANCELED, + FlightStatus.FLYING, + FlightStatus.COMPLETED + ), + flightDate: Joi.date().required(), + departureDate: Joi.date().required(), + departureAirportId: Joi.number().required(), + aircraftId: Joi.number().required(), + arriveDate: Joi.date().required(), + arriveAirportId: Joi.number().required(), + durationMinutes: Joi.number().required() }); @ApiBearerAuth() @ApiTags('Flights') @Controller({ - path: `/flight`, - version: '1', + path: `/flight`, + version: '1' }) export class CreateFlightController { - - constructor(private readonly commandBus: CommandBus) { - } - - @Post('create') - @UseGuards(JwtGuard) - @ApiResponse({status: 401, description: 'UNAUTHORIZED'}) - @ApiResponse({status: 400, description: 'BAD_REQUEST'}) - @ApiResponse({status: 403, description: 'FORBIDDEN'}) - @ApiResponse({status: 201, description: 'CREATED'}) - public async createFlight(@Body() request: CreateFlightRequestDto, @Res() res: Response): Promise { - const result = await this.commandBus.execute( - new CreateFlight({ - flightNumber: request.flightNumber, - aircraftId: request.aircraftId, - arriveAirportId: request.arriveAirportId, - arriveDate: request.arriveDate, - price: request.price, - departureAirportId: request.departureAirportId, - departureDate: request.departureDate, - flightDate: request.flightDate, - flightStatus: request.flightStatus, - durationMinutes: request.durationMinutes - }) - ); - - res.status(HttpStatus.CREATED).send(result); - - return result; - } + constructor(private readonly commandBus: CommandBus) {} + + @Post('create') + @UseGuards(JwtGuard) + @ApiResponse({ status: 401, description: 'UNAUTHORIZED' }) + @ApiResponse({ status: 400, description: 'BAD_REQUEST' }) + @ApiResponse({ status: 403, description: 'FORBIDDEN' }) + @ApiResponse({ status: 201, description: 'CREATED' }) + public async createFlight( + @Body() request: CreateFlightRequestDto, + @Res() res: Response + ): Promise { + const result = await this.commandBus.execute( + new CreateFlight({ + flightNumber: request.flightNumber, + aircraftId: request.aircraftId, + arriveAirportId: request.arriveAirportId, + arriveDate: request.arriveDate, + price: request.price, + departureAirportId: request.departureAirportId, + departureDate: request.departureDate, + flightDate: request.flightDate, + flightStatus: request.flightStatus, + durationMinutes: request.durationMinutes + }) + ); + + res.status(HttpStatus.CREATED).send(result); + + return result; + } } @CommandHandler(CreateFlight) export class CreateFlightHandler implements ICommandHandler { - constructor( - @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, - @Inject('IFlightRepository') private readonly flightRepository: IFlightRepository, - ) { - } - - async execute(command: CreateFlight): Promise { - await createFlightValidations.validateAsync(command); - - const existFlight = await this.flightRepository.findFlightByNumber(command.flightNumber); + constructor( + @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, + @Inject('IFlightRepository') private readonly flightRepository: IFlightRepository + ) {} - if (existFlight) { - throw new ConflictException('Flight already taken'); - } + async execute(command: CreateFlight): Promise { + await createFlightValidations.validateAsync(command); - const flightEntity = await this.flightRepository.createFlight( - new Flight({ - flightNumber: command.flightNumber, - aircraftId: command.aircraftId, - arriveAirportId: command.arriveAirportId, - arriveDate: command.arriveDate, - price: command.price, - departureAirportId: command.departureAirportId, - departureDate: command.departureDate, - flightDate: command.flightDate, - flightStatus: command.flightStatus, - durationMinutes: command.durationMinutes - }) - ); + const existFlight = await this.flightRepository.findFlightByNumber(command.flightNumber); - await this.rabbitmqPublisher.publishMessage(new FlightCreated(flightEntity)); - - const result = mapper.map(flightEntity, new FlightDto()); - - return result; + if (existFlight) { + throw new ConflictException('Flight already taken'); } + + const flightEntity = await this.flightRepository.createFlight( + new Flight({ + flightNumber: command.flightNumber, + aircraftId: command.aircraftId, + arriveAirportId: command.arriveAirportId, + arriveDate: command.arriveDate, + price: command.price, + departureAirportId: command.departureAirportId, + departureDate: command.departureDate, + flightDate: command.flightDate, + flightStatus: command.flightStatus, + durationMinutes: command.durationMinutes + }) + ); + + await this.rabbitmqPublisher.publishMessage(new FlightCreated(flightEntity)); + + const result = mapper.map(flightEntity, new FlightDto()); + + return result; + } } diff --git a/src/flight/src/flight/features/v1/get-flight-by-id/get-flight-by-id.ts b/src/flight/src/flight/features/v1/get-flight-by-id/get-flight-by-id.ts index fadffc6..fffebd1 100644 --- a/src/flight/src/flight/features/v1/get-flight-by-id/get-flight-by-id.ts +++ b/src/flight/src/flight/features/v1/get-flight-by-id/get-flight-by-id.ts @@ -1,74 +1,71 @@ import Joi from 'joi'; -import {FlightDto} from '../../../dtos/flight.dto'; -import {IFlightRepository} from '../../../../data/repositories/flightRepository'; -import {ApiBearerAuth, ApiResponse, ApiTags} from "@nestjs/swagger"; -import {Controller, Get, Inject, NotFoundException, Query, UseGuards} from "@nestjs/common"; -import {IQueryHandler, QueryBus, QueryHandler} from "@nestjs/cqrs"; -import {Flight} from "../../../entities/flight.entity"; -import {JwtGuard} from "building-blocks/passport/jwt.guard"; -import {IRabbitmqPublisher} from "building-blocks/rabbitmq/rabbitmq-publisher"; -import mapper from "../../../mappings"; +import { FlightDto } from '../../../dtos/flight.dto'; +import { IFlightRepository } from '../../../../data/repositories/flightRepository'; +import { ApiBearerAuth, ApiResponse, ApiTags } from '@nestjs/swagger'; +import { Controller, Get, Inject, NotFoundException, Query, UseGuards } from '@nestjs/common'; +import { IQueryHandler, QueryBus, QueryHandler } from '@nestjs/cqrs'; +import { Flight } from '../../../entities/flight.entity'; +import { JwtGuard } from 'building-blocks/passport/jwt.guard'; +import { IRabbitmqPublisher } from 'building-blocks/rabbitmq/rabbitmq-publisher'; +import mapper from '../../../mappings'; export class GetFlightById { - id: number; + id: number; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } const getFlightByIdValidations = { - params: Joi.object().keys({ - id: Joi.number().required() - }) + params: Joi.object().keys({ + id: Joi.number().required() + }) }; @ApiBearerAuth() @ApiTags('Flights') @Controller({ - path: `/flight`, - version: '1', + path: `/flight`, + version: '1' }) export class GetFlightByIdController { + constructor(private readonly queryBus: QueryBus) {} - constructor(private readonly queryBus: QueryBus) { - } - - @Get('get-by-id') - @UseGuards(JwtGuard) - @ApiResponse({status: 401, description: 'UNAUTHORIZED'}) - @ApiResponse({status: 400, description: 'BAD_REQUEST'}) - @ApiResponse({status: 403, description: 'FORBIDDEN'}) - @ApiResponse({status: 200, description: 'OK'}) - public async getFlightById(@Query('id') id: number): Promise { - const result = await this.queryBus.execute( - new GetFlightById({ - id: id - }) - ); + @Get('get-by-id') + @UseGuards(JwtGuard) + @ApiResponse({ status: 401, description: 'UNAUTHORIZED' }) + @ApiResponse({ status: 400, description: 'BAD_REQUEST' }) + @ApiResponse({ status: 403, description: 'FORBIDDEN' }) + @ApiResponse({ status: 200, description: 'OK' }) + public async getFlightById(@Query('id') id: number): Promise { + const result = await this.queryBus.execute( + new GetFlightById({ + id: id + }) + ); - if (!result) { - throw new NotFoundException('Flight not found'); - } - return result; + if (!result) { + throw new NotFoundException('Flight not found'); } + return result; + } } @QueryHandler(GetFlightById) export class GetFlightByIdHandler implements IQueryHandler { - constructor( - @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, - @Inject('IFlightRepository') private readonly flightRepository: IFlightRepository, - ) { - } + constructor( + @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, + @Inject('IFlightRepository') private readonly flightRepository: IFlightRepository + ) {} - async execute(query: GetFlightById): Promise { - await getFlightByIdValidations.params.validateAsync(query); + async execute(query: GetFlightById): Promise { + await getFlightByIdValidations.params.validateAsync(query); - const flightEntity = await this.flightRepository.findFlightById(query.id); + const flightEntity = await this.flightRepository.findFlightById(query.id); - const result = mapper.map(flightEntity, new FlightDto()); + const result = mapper.map(flightEntity, new FlightDto()); - return result; - } + return result; + } } diff --git a/src/flight/src/flight/flight.module.ts b/src/flight/src/flight/flight.module.ts index 377b816..431656a 100644 --- a/src/flight/src/flight/flight.module.ts +++ b/src/flight/src/flight/flight.module.ts @@ -1,40 +1,51 @@ -import {Module} from '@nestjs/common'; -import {CqrsModule} from '@nestjs/cqrs'; -import {TypeOrmModule} from '@nestjs/typeorm'; -import {FlightRepository} from "../data/repositories/flightRepository"; -import {Flight} from "./entities/flight.entity"; -import {Aircraft} from "../aircraft/entities/aircraft.entity"; -import {Airport} from "../airport/entities/airport.entity"; -import {Seat} from "../seat/entities/seat.entity"; -import {AircraftRepository} from "../data/repositories/aircraftRepository"; -import {AirportRepository} from "../data/repositories/airportRepository"; -import {SeatRepository} from "../data/repositories/seatRepository"; -import {CreateFlightController, CreateFlightHandler} from "./features/v1/create-flight/create-flight"; -import {GetFlightByIdController, GetFlightByIdHandler} from "./features/v1/get-flight-by-id/get-flight-by-id"; -import {RabbitmqModule} from "building-blocks/rabbitmq/rabbitmq.module"; +import { Module } from '@nestjs/common'; +import { CqrsModule } from '@nestjs/cqrs'; +import { TypeOrmModule } from '@nestjs/typeorm'; +import { FlightRepository } from '../data/repositories/flightRepository'; +import { Flight } from './entities/flight.entity'; +import { Aircraft } from '../aircraft/entities/aircraft.entity'; +import { Airport } from '../airport/entities/airport.entity'; +import { Seat } from '../seat/entities/seat.entity'; +import { AircraftRepository } from '../data/repositories/aircraftRepository'; +import { AirportRepository } from '../data/repositories/airportRepository'; +import { SeatRepository } from '../data/repositories/seatRepository'; +import { + CreateFlightController, + CreateFlightHandler +} from './features/v1/create-flight/create-flight'; +import { + GetFlightByIdController, + GetFlightByIdHandler +} from './features/v1/get-flight-by-id/get-flight-by-id'; +import { RabbitmqModule } from 'building-blocks/rabbitmq/rabbitmq.module'; @Module({ - imports: [CqrsModule, RabbitmqModule.forRoot(), TypeOrmModule.forFeature([Flight, Aircraft, Airport, Seat])], - controllers: [CreateFlightController, GetFlightByIdController], - providers: [ - CreateFlightHandler, GetFlightByIdHandler, - { - provide: 'IFlightRepository', - useClass: FlightRepository, - }, - { - provide: 'IAircraftRepository', - useClass: AircraftRepository, - }, - { - provide: 'IAirportRepository', - useClass: AirportRepository, - }, - { - provide: 'ISeatRepository', - useClass: SeatRepository, - }, - ], - exports: [], + imports: [ + CqrsModule, + RabbitmqModule.forRoot(), + TypeOrmModule.forFeature([Flight, Aircraft, Airport, Seat]) + ], + controllers: [CreateFlightController, GetFlightByIdController], + providers: [ + CreateFlightHandler, + GetFlightByIdHandler, + { + provide: 'IFlightRepository', + useClass: FlightRepository + }, + { + provide: 'IAircraftRepository', + useClass: AircraftRepository + }, + { + provide: 'IAirportRepository', + useClass: AirportRepository + }, + { + provide: 'ISeatRepository', + useClass: SeatRepository + } + ], + exports: [] }) export class FlightModule {} diff --git a/src/flight/src/flight/mappings.ts b/src/flight/src/flight/mappings.ts index c3c8d98..3be112f 100644 --- a/src/flight/src/flight/mappings.ts +++ b/src/flight/src/flight/mappings.ts @@ -1,6 +1,6 @@ import { TypeMapper } from 'ts-mapper'; import { FlightDto } from './dtos/flight.dto'; -import {Flight} from "./entities/flight.entity"; +import { Flight } from './entities/flight.entity'; export class Mapper extends TypeMapper { constructor() { diff --git a/src/flight/src/main.ts b/src/flight/src/main.ts index 485276a..de1f31a 100644 --- a/src/flight/src/main.ts +++ b/src/flight/src/main.ts @@ -2,47 +2,47 @@ import { NestFactory } from '@nestjs/core'; import { AppModule } from './app.module'; import { Logger, ValidationPipe, VersioningType } from '@nestjs/common'; import { DocumentBuilder, SwaggerModule } from '@nestjs/swagger'; -import {PrometheusMetrics} from "building-blocks/monitoring/prometheus.metrics"; -import {ErrorHandlersFilter} from "building-blocks/filters/error-handlers.filter"; -import configs from "building-blocks/configs/configs"; -import {Request, Response} from "express"; +import { PrometheusMetrics } from 'building-blocks/monitoring/prometheus.metrics'; +import { ErrorHandlersFilter } from 'building-blocks/filters/error-handlers.filter'; +import configs from 'building-blocks/configs/configs'; +import { Request, Response } from 'express'; async function bootstrap() { - const app = await NestFactory.create(AppModule); + const app = await NestFactory.create(AppModule); - app.enableShutdownHooks(); + app.enableShutdownHooks(); - const globalPrefix = 'api'; - app.setGlobalPrefix(globalPrefix); - const port = configs.port || 3344; + const globalPrefix = 'api'; + app.setGlobalPrefix(globalPrefix); + const port = configs.port || 3344; - app.enableVersioning({ - type: VersioningType.URI, - }); + app.enableVersioning({ + type: VersioningType.URI + }); - const config = new DocumentBuilder() - .setTitle(`${configs.serviceName}`) - .setDescription(`${configs.serviceName} api description`) - .setVersion('1.0') - .addBearerAuth() - .build(); - const document = SwaggerModule.createDocument(app, config); - SwaggerModule.setup('swagger', app, document); + const config = new DocumentBuilder() + .setTitle(`${configs.serviceName}`) + .setDescription(`${configs.serviceName} api description`) + .setVersion('1.0') + .addBearerAuth() + .build(); + const document = SwaggerModule.createDocument(app, config); + SwaggerModule.setup('swagger', app, document); - app.useGlobalPipes(new ValidationPipe({ transform: true })); + app.useGlobalPipes(new ValidationPipe({ transform: true })); - app.use((req: Request, res: Response, next: any) => { - if (req.originalUrl == '/' || req.originalUrl.includes('favicon.ico')) { - return res.send(configs.serviceName); - } - return next(); - }); + app.use((req: Request, res: Response, next: any) => { + if (req.originalUrl == '/' || req.originalUrl.includes('favicon.ico')) { + return res.send(configs.serviceName); + } + return next(); + }); - PrometheusMetrics.registerMetricsEndpoint(app); + PrometheusMetrics.registerMetricsEndpoint(app); - app.useGlobalFilters(new ErrorHandlersFilter()); + app.useGlobalFilters(new ErrorHandlersFilter()); - await app.listen(port); - Logger.log(`🚀 Application is running on: http://localhost:${port}`); + await app.listen(port); + Logger.log(`🚀 Application is running on: http://localhost:${port}`); } bootstrap(); diff --git a/src/flight/src/seat/dtos/seat.dto.ts b/src/flight/src/seat/dtos/seat.dto.ts index 0c781fb..be47f2c 100644 --- a/src/flight/src/seat/dtos/seat.dto.ts +++ b/src/flight/src/seat/dtos/seat.dto.ts @@ -1,5 +1,5 @@ -import {SeatClass} from "../enums/seat-class.enum"; -import {SeatType} from "../enums/seat-type.enum"; +import { SeatClass } from '../enums/seat-class.enum'; +import { SeatType } from '../enums/seat-type.enum'; export class SeatDto { id: number; diff --git a/src/flight/src/seat/entities/seat.entity.ts b/src/flight/src/seat/entities/seat.entity.ts index 3d4875e..066afa1 100644 --- a/src/flight/src/seat/entities/seat.entity.ts +++ b/src/flight/src/seat/entities/seat.entity.ts @@ -1,7 +1,7 @@ import { Entity, Column, PrimaryGeneratedColumn, OneToMany, ManyToOne, JoinColumn } from 'typeorm'; -import {SeatClass} from "../enums/seat-class.enum"; -import {SeatType} from "../enums/seat-type.enum"; -import {Flight} from "../../flight/entities/flight.entity"; +import { SeatClass } from '../enums/seat-class.enum'; +import { SeatType } from '../enums/seat-type.enum'; +import { Flight } from '../../flight/entities/flight.entity'; @Entity() export class Seat { diff --git a/src/flight/src/seat/features/v1/create-seat/create-seat.ts b/src/flight/src/seat/features/v1/create-seat/create-seat.ts index 80d97bf..71531a8 100644 --- a/src/flight/src/seat/features/v1/create-seat/create-seat.ts +++ b/src/flight/src/seat/features/v1/create-seat/create-seat.ts @@ -1,123 +1,132 @@ import Joi from 'joi'; -import {ISeatRepository} from '../../../../data/repositories/seatRepository'; -import {IFlightRepository} from '../../../../data/repositories/flightRepository'; -import {ApiBearerAuth, ApiProperty, ApiResponse, ApiTags} from "@nestjs/swagger"; -import {SeatClass} from "../../../enums/seat-class.enum"; -import {SeatType} from "../../../enums/seat-type.enum"; -import {Body, Controller, HttpStatus, Inject, NotFoundException, Post, Res, UseGuards} from "@nestjs/common"; -import {SeatDto} from "../../../dtos/seat.dto"; -import {CommandBus, CommandHandler, ICommandHandler} from "@nestjs/cqrs"; -import {Response} from "express"; -import {Seat} from "../../../entities/seat.entity"; -import {JwtGuard} from "building-blocks/passport/jwt.guard"; -import {IRabbitmqPublisher} from "building-blocks/rabbitmq/rabbitmq-publisher"; -import {SeatCreated} from "building-blocks/contracts/flight.contract"; -import mapper from "../../../mappings"; +import { ISeatRepository } from '../../../../data/repositories/seatRepository'; +import { IFlightRepository } from '../../../../data/repositories/flightRepository'; +import { ApiBearerAuth, ApiProperty, ApiResponse, ApiTags } from '@nestjs/swagger'; +import { SeatClass } from '../../../enums/seat-class.enum'; +import { SeatType } from '../../../enums/seat-type.enum'; +import { + Body, + Controller, + HttpStatus, + Inject, + NotFoundException, + Post, + Res, + UseGuards +} from '@nestjs/common'; +import { SeatDto } from '../../../dtos/seat.dto'; +import { CommandBus, CommandHandler, ICommandHandler } from '@nestjs/cqrs'; +import { Response } from 'express'; +import { Seat } from '../../../entities/seat.entity'; +import { JwtGuard } from 'building-blocks/passport/jwt.guard'; +import { IRabbitmqPublisher } from 'building-blocks/rabbitmq/rabbitmq-publisher'; +import { SeatCreated } from 'building-blocks/contracts/flight.contract'; +import mapper from '../../../mappings'; export class CreateSeat { - seatNumber: string; - seatClass: SeatClass; - seatType: SeatType; - flightId: number; - - constructor(request: Partial = {}) { - Object.assign(this, request); - } + seatNumber: string; + seatClass: SeatClass; + seatType: SeatType; + flightId: number; + + constructor(request: Partial = {}) { + Object.assign(this, request); + } } export class CreateSeatRequestDto { - @ApiProperty() - seatNumber: string; + @ApiProperty() + seatNumber: string; - @ApiProperty() - seatClass: SeatClass; + @ApiProperty() + seatClass: SeatClass; - @ApiProperty() - seatType: SeatType; + @ApiProperty() + seatType: SeatType; - @ApiProperty() - flightId: number; + @ApiProperty() + flightId: number; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } const createSeatValidations = Joi.object({ - seatNumber: Joi.string().required(), - flightId: Joi.number().required(), - seatClass: Joi.string() - .required() - .valid(SeatClass.UNKNOWN, SeatClass.FIRST_CLASS, SeatClass.BUSINESS, SeatClass.ECONOMY), - seatType: Joi.string() - .required() - .valid(SeatType.UNKNOWN, SeatType.AISLE, SeatType.MIDDLE, SeatType.WINDOW) + seatNumber: Joi.string().required(), + flightId: Joi.number().required(), + seatClass: Joi.string() + .required() + .valid(SeatClass.UNKNOWN, SeatClass.FIRST_CLASS, SeatClass.BUSINESS, SeatClass.ECONOMY), + seatType: Joi.string() + .required() + .valid(SeatType.UNKNOWN, SeatType.AISLE, SeatType.MIDDLE, SeatType.WINDOW) }); @ApiBearerAuth() @ApiTags('Seats') @Controller({ - path: `/seat`, - version: '1', + path: `/seat`, + version: '1' }) export class CreateSeatController { - - constructor(private readonly commandBus: CommandBus) { - } - - @Post('create') - @UseGuards(JwtGuard) - @ApiResponse({status: 401, description: 'UNAUTHORIZED'}) - @ApiResponse({status: 400, description: 'BAD_REQUEST'}) - @ApiResponse({status: 403, description: 'FORBIDDEN'}) - @ApiResponse({status: 201, description: 'CREATED'}) - public async createSeat(@Body() request: CreateSeatRequestDto, @Res() res: Response): Promise { - const result = await this.commandBus.execute( - new CreateSeat({ - flightId: request.flightId, - seatNumber: request.seatNumber, - seatClass: request.seatClass, - seatType: request.seatType - }) - ); - - res.status(HttpStatus.CREATED).send(result); - return result; - } + constructor(private readonly commandBus: CommandBus) {} + + @Post('create') + @UseGuards(JwtGuard) + @ApiResponse({ status: 401, description: 'UNAUTHORIZED' }) + @ApiResponse({ status: 400, description: 'BAD_REQUEST' }) + @ApiResponse({ status: 403, description: 'FORBIDDEN' }) + @ApiResponse({ status: 201, description: 'CREATED' }) + public async createSeat( + @Body() request: CreateSeatRequestDto, + @Res() res: Response + ): Promise { + const result = await this.commandBus.execute( + new CreateSeat({ + flightId: request.flightId, + seatNumber: request.seatNumber, + seatClass: request.seatClass, + seatType: request.seatType + }) + ); + + res.status(HttpStatus.CREATED).send(result); + return result; + } } @CommandHandler(CreateSeat) export class CreateSeatHandler implements ICommandHandler { - constructor( - @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, - @Inject('ISeatRepository') private readonly seatRepository: ISeatRepository, - @Inject('IFlightRepository') private readonly flightRepository: IFlightRepository, - ) { - } + constructor( + @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, + @Inject('ISeatRepository') private readonly seatRepository: ISeatRepository, + @Inject('IFlightRepository') private readonly flightRepository: IFlightRepository + ) {} - async execute(command: CreateSeat): Promise { - await createSeatValidations.validateAsync(command); + async execute(command: CreateSeat): Promise { + await createSeatValidations.validateAsync(command); - const existFlight = await this.flightRepository.findFlightById(command.flightId); + const existFlight = await this.flightRepository.findFlightById(command.flightId); - if (existFlight == null) { - throw new NotFoundException('Flight not found!'); - } + if (existFlight == null) { + throw new NotFoundException('Flight not found!'); + } - const seatEntity = await this.seatRepository.createSeat( - new Seat({ - flightId: command.flightId, - seatNumber: command.seatNumber, - seatClass: command.seatClass, - seatType: command.seatType, - isReserved: false - }) - ); + const seatEntity = await this.seatRepository.createSeat( + new Seat({ + flightId: command.flightId, + seatNumber: command.seatNumber, + seatClass: command.seatClass, + seatType: command.seatType, + isReserved: false + }) + ); - await this.rabbitmqPublisher.publishMessage(new SeatCreated(seatEntity)); + await this.rabbitmqPublisher.publishMessage(new SeatCreated(seatEntity)); - const result = mapper.map(seatEntity, new SeatDto()); + const result = mapper.map(seatEntity, new SeatDto()); - return result; - } + return result; + } } diff --git a/src/flight/src/seat/features/v1/get-available-seats/get-available-seats.ts b/src/flight/src/seat/features/v1/get-available-seats/get-available-seats.ts index eaff9c1..fe9ad6a 100644 --- a/src/flight/src/seat/features/v1/get-available-seats/get-available-seats.ts +++ b/src/flight/src/seat/features/v1/get-available-seats/get-available-seats.ts @@ -1,13 +1,13 @@ import Joi from 'joi'; import { ISeatRepository } from '../../../../data/repositories/seatRepository'; -import {ApiBearerAuth, ApiResponse, ApiTags} from "@nestjs/swagger"; -import {Controller, Get, Inject, Post, Query, UseGuards} from "@nestjs/common"; -import {IQueryHandler, QueryBus, QueryHandler} from "@nestjs/cqrs"; -import {SeatDto} from "../../../dtos/seat.dto"; -import {Seat} from "../../../entities/seat.entity"; -import {JwtGuard} from "building-blocks/passport/jwt.guard"; -import {IRabbitmqPublisher} from "building-blocks/rabbitmq/rabbitmq-publisher"; -import mapper from "../../../mappings"; +import { ApiBearerAuth, ApiResponse, ApiTags } from '@nestjs/swagger'; +import { Controller, Get, Inject, Post, Query, UseGuards } from '@nestjs/common'; +import { IQueryHandler, QueryBus, QueryHandler } from '@nestjs/cqrs'; +import { SeatDto } from '../../../dtos/seat.dto'; +import { Seat } from '../../../entities/seat.entity'; +import { JwtGuard } from 'building-blocks/passport/jwt.guard'; +import { IRabbitmqPublisher } from 'building-blocks/rabbitmq/rabbitmq-publisher'; +import mapper from '../../../mappings'; export class GetAvailableSeats { flightId: number; @@ -26,20 +26,18 @@ const getAvailableSeatsValidations = { @ApiBearerAuth() @ApiTags('Seats') @Controller({ - path: `/seat`, - version: '1', + path: `/seat`, + version: '1' }) export class GetAvailableSeatsController { - - constructor(private readonly queryBus: QueryBus) { - } + constructor(private readonly queryBus: QueryBus) {} @Get('get-available-seats') @Post('create') @UseGuards(JwtGuard) - @ApiResponse({status: 401, description: 'UNAUTHORIZED'}) - @ApiResponse({status: 400, description: 'BAD_REQUEST'}) - @ApiResponse({status: 403, description: 'FORBIDDEN'}) - @ApiResponse({status: 200, description: 'OK'}) + @ApiResponse({ status: 401, description: 'UNAUTHORIZED' }) + @ApiResponse({ status: 400, description: 'BAD_REQUEST' }) + @ApiResponse({ status: 403, description: 'FORBIDDEN' }) + @ApiResponse({ status: 200, description: 'OK' }) public async getAvailableSeats(@Query('flightId') flightId: number): Promise { const result = await this.queryBus.execute( new GetAvailableSeats({ @@ -53,13 +51,12 @@ export class GetAvailableSeatsController { @QueryHandler(GetAvailableSeats) export class GetAvailableSeatsHandler implements IQueryHandler { - constructor( - @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, - @Inject('ISeatRepository') private readonly seatRepository: ISeatRepository, - ) { - } + constructor( + @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, + @Inject('ISeatRepository') private readonly seatRepository: ISeatRepository + ) {} - async execute(query: GetAvailableSeats): Promise { + async execute(query: GetAvailableSeats): Promise { await getAvailableSeatsValidations.params.validateAsync(query); const seatsEntity = await this.seatRepository.getSeatsByFlightId(query.flightId); diff --git a/src/flight/src/seat/features/v1/reserve-seat/reserve-seat.ts b/src/flight/src/seat/features/v1/reserve-seat/reserve-seat.ts index eeb7aa8..5ab8d87 100644 --- a/src/flight/src/seat/features/v1/reserve-seat/reserve-seat.ts +++ b/src/flight/src/seat/features/v1/reserve-seat/reserve-seat.ts @@ -1,107 +1,116 @@ import Joi from 'joi'; -import {ISeatRepository} from '../../../../data/repositories/seatRepository'; -import {IFlightRepository} from '../../../../data/repositories/flightRepository'; -import {ApiBearerAuth, ApiProperty, ApiResponse, ApiTags} from "@nestjs/swagger"; -import {Body, Controller, HttpStatus, Inject, NotFoundException, Post, Res, UseGuards} from "@nestjs/common"; -import {Response} from "express"; -import {CommandBus, CommandHandler, ICommandHandler} from "@nestjs/cqrs"; -import {Seat} from "../../../entities/seat.entity"; -import {JwtGuard} from "building-blocks/passport/jwt.guard"; -import {IRabbitmqPublisher} from "building-blocks/rabbitmq/rabbitmq-publisher"; -import {SeatReserved} from "building-blocks/contracts/flight.contract"; +import { ISeatRepository } from '../../../../data/repositories/seatRepository'; +import { IFlightRepository } from '../../../../data/repositories/flightRepository'; +import { ApiBearerAuth, ApiProperty, ApiResponse, ApiTags } from '@nestjs/swagger'; +import { + Body, + Controller, + HttpStatus, + Inject, + NotFoundException, + Post, + Res, + UseGuards +} from '@nestjs/common'; +import { Response } from 'express'; +import { CommandBus, CommandHandler, ICommandHandler } from '@nestjs/cqrs'; +import { Seat } from '../../../entities/seat.entity'; +import { JwtGuard } from 'building-blocks/passport/jwt.guard'; +import { IRabbitmqPublisher } from 'building-blocks/rabbitmq/rabbitmq-publisher'; +import { SeatReserved } from 'building-blocks/contracts/flight.contract'; export class ReserveSeat { - seatNumber: string; - flightId: number; + seatNumber: string; + flightId: number; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } export class ReserveSeatRequestDto { - @ApiProperty() - seatNumber: string; + @ApiProperty() + seatNumber: string; - @ApiProperty() - flightId: number; + @ApiProperty() + flightId: number; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } const reserveSeatValidations = Joi.object({ - seatNumber: Joi.string().required(), - flightId: Joi.number().required() + seatNumber: Joi.string().required(), + flightId: Joi.number().required() }); @ApiBearerAuth() @ApiTags('Seats') @Controller({ - path: `/seat`, - version: '1', + path: `/seat`, + version: '1' }) export class ReserveSeatController { - - constructor(private readonly commandBus: CommandBus) { - } - - @Post('reserve') - @UseGuards(JwtGuard) - @ApiResponse({status: 401, description: 'UNAUTHORIZED'}) - @ApiResponse({status: 400, description: 'BAD_REQUEST'}) - @ApiResponse({status: 403, description: 'FORBIDDEN'}) - @ApiResponse({status: 204, description: 'NO_CONTENT'}) - public async reserveSeat(@Body() request: ReserveSeatRequestDto, @Res() res: Response): Promise { - await this.commandBus.execute( - new ReserveSeat({ - flightId: request.flightId, - seatNumber: request.seatNumber - }) - ); - - res.status(HttpStatus.NO_CONTENT).send(null); - } + constructor(private readonly commandBus: CommandBus) {} + + @Post('reserve') + @UseGuards(JwtGuard) + @ApiResponse({ status: 401, description: 'UNAUTHORIZED' }) + @ApiResponse({ status: 400, description: 'BAD_REQUEST' }) + @ApiResponse({ status: 403, description: 'FORBIDDEN' }) + @ApiResponse({ status: 204, description: 'NO_CONTENT' }) + public async reserveSeat( + @Body() request: ReserveSeatRequestDto, + @Res() res: Response + ): Promise { + await this.commandBus.execute( + new ReserveSeat({ + flightId: request.flightId, + seatNumber: request.seatNumber + }) + ); + + res.status(HttpStatus.NO_CONTENT).send(null); + } } @CommandHandler(ReserveSeat) export class ReserveSeatHandler implements ICommandHandler { - constructor( - @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, - @Inject('IFlightRepository') private readonly flightRepository: IFlightRepository, - @Inject('ISeatRepository') private readonly seatRepository: ISeatRepository, - ) { - } - - async execute(command: ReserveSeat): Promise { - await reserveSeatValidations.validateAsync(command); - - const existFlight = await this.flightRepository.findFlightById(command.flightId); + constructor( + @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, + @Inject('IFlightRepository') private readonly flightRepository: IFlightRepository, + @Inject('ISeatRepository') private readonly seatRepository: ISeatRepository + ) {} - if (existFlight == null) { - throw new NotFoundException('Flight not found!'); - } + async execute(command: ReserveSeat): Promise { + await reserveSeatValidations.validateAsync(command); - const seat = await this.seatRepository.getAvailableSeat(command.flightId, command.seatNumber); + const existFlight = await this.flightRepository.findFlightById(command.flightId); - if (seat == null) { - throw new NotFoundException('Seat not found!'); - } - - const seatEntity = new Seat({ - id: seat.id, - flightId: command.flightId, - seatNumber: command.seatNumber, - seatClass: seat.seatClass, - seatType: seat.seatType, - isReserved: true, - createdAt: seat.createdAt, - updatedAt: new Date() - }); + if (existFlight == null) { + throw new NotFoundException('Flight not found!'); + } - await this.seatRepository.reserveSeat(seatEntity); + const seat = await this.seatRepository.getAvailableSeat(command.flightId, command.seatNumber); - await this.rabbitmqPublisher.publishMessage(new SeatReserved(seatEntity)); + if (seat == null) { + throw new NotFoundException('Seat not found!'); } + + const seatEntity = new Seat({ + id: seat.id, + flightId: command.flightId, + seatNumber: command.seatNumber, + seatClass: seat.seatClass, + seatType: seat.seatType, + isReserved: true, + createdAt: seat.createdAt, + updatedAt: new Date() + }); + + await this.seatRepository.reserveSeat(seatEntity); + + await this.rabbitmqPublisher.publishMessage(new SeatReserved(seatEntity)); + } } diff --git a/src/flight/src/seat/mappings.ts b/src/flight/src/seat/mappings.ts index 3e1c00e..2974432 100644 --- a/src/flight/src/seat/mappings.ts +++ b/src/flight/src/seat/mappings.ts @@ -1,6 +1,6 @@ import { TypeMapper } from 'ts-mapper'; -import {SeatDto} from "./dtos/seat.dto"; -import {Seat} from "./entities/seat.entity"; +import { SeatDto } from './dtos/seat.dto'; +import { Seat } from './entities/seat.entity'; export class Mapper extends TypeMapper { constructor() { diff --git a/src/flight/src/seat/seat.module.ts b/src/flight/src/seat/seat.module.ts index e4b9217..86ebaf3 100644 --- a/src/flight/src/seat/seat.module.ts +++ b/src/flight/src/seat/seat.module.ts @@ -1,33 +1,34 @@ -import {Module} from '@nestjs/common'; -import {CqrsModule} from '@nestjs/cqrs'; -import {TypeOrmModule} from '@nestjs/typeorm'; -import {SeatRepository} from "../data/repositories/seatRepository"; -import {Seat} from "./entities/seat.entity"; -import {Flight} from "../flight/entities/flight.entity"; -import {FlightRepository} from "../data/repositories/flightRepository"; -import {CreateSeatController, CreateSeatHandler} from "./features/v1/create-seat/create-seat"; +import { Module } from '@nestjs/common'; +import { CqrsModule } from '@nestjs/cqrs'; +import { TypeOrmModule } from '@nestjs/typeorm'; +import { SeatRepository } from '../data/repositories/seatRepository'; +import { Seat } from './entities/seat.entity'; +import { Flight } from '../flight/entities/flight.entity'; +import { FlightRepository } from '../data/repositories/flightRepository'; +import { CreateSeatController, CreateSeatHandler } from './features/v1/create-seat/create-seat'; import { - GetAvailableSeatsController, - GetAvailableSeatsHandler -} from "./features/v1/get-available-seats/get-available-seats"; -import {ReserveSeatController, ReserveSeatHandler} from "./features/v1/reserve-seat/reserve-seat"; -import {RabbitmqModule} from "building-blocks/rabbitmq/rabbitmq.module"; + GetAvailableSeatsController, + GetAvailableSeatsHandler +} from './features/v1/get-available-seats/get-available-seats'; +import { ReserveSeatController, ReserveSeatHandler } from './features/v1/reserve-seat/reserve-seat'; +import { RabbitmqModule } from 'building-blocks/rabbitmq/rabbitmq.module'; @Module({ - imports: [CqrsModule, RabbitmqModule.forRoot(), TypeOrmModule.forFeature([Seat, Flight])], - controllers: [CreateSeatController, GetAvailableSeatsController, ReserveSeatController], - providers: [ - CreateSeatHandler, GetAvailableSeatsHandler, ReserveSeatHandler, - { - provide: 'ISeatRepository', - useClass: SeatRepository, - }, - { - provide: 'IFlightRepository', - useClass: FlightRepository, - } - ], - exports: [], + imports: [CqrsModule, RabbitmqModule.forRoot(), TypeOrmModule.forFeature([Seat, Flight])], + controllers: [CreateSeatController, GetAvailableSeatsController, ReserveSeatController], + providers: [ + CreateSeatHandler, + GetAvailableSeatsHandler, + ReserveSeatHandler, + { + provide: 'ISeatRepository', + useClass: SeatRepository + }, + { + provide: 'IFlightRepository', + useClass: FlightRepository + } + ], + exports: [] }) -export class SeatModule { -} +export class SeatModule {} diff --git a/src/flight/tsconfig.json b/src/flight/tsconfig.json index a9f66b1..cff40bc 100644 --- a/src/flight/tsconfig.json +++ b/src/flight/tsconfig.json @@ -1,16 +1,32 @@ { "compilerOptions": { - "module": "commonjs", - "declaration": true, - "removeComments": true, - "emitDecoratorMetadata": true, - "experimentalDecorators": true, - "allowSyntheticDefaultImports": true, - "target": "es2017", - "sourceMap": true, - "outDir": "./dist", - "baseUrl": "./", - "incremental": true, - "esModuleInterop": true + // Language and Environment + "target": "es2022", // Modern JavaScript features + "module": "commonjs", // Module system for Node.js + "lib": ["es2022"], // Include all ES2022 features + + // Modules and Output + "moduleResolution": "node", // Use Node.js module resolution + "baseUrl": "./", // Base directory for paths + "outDir": "./dist", // Output directory + "removeComments": true, // Remove comments in output + + // Decorators (needed for NestJS) + "experimentalDecorators": true, // Enable decorators + "emitDecoratorMetadata": true, // Emit decorator metadata + + // Type Checking + "strict": false, // Enable all strict type checking + "skipLibCheck": true, // Skip type checking of declaration files + "forceConsistentCasingInFileNames": true, // Ensure consistent casing in imports + + // Interop Constraints + "esModuleInterop": true, // Enable ES Module interop + "allowSyntheticDefaultImports": true, // Allow default imports from modules + + // Advanced + "incremental": true, // Enable incremental compilation + "preserveConstEnums": true, // Keep const enums in output + "resolveJsonModule": true // Allow importing JSON files } -} +} \ No newline at end of file diff --git a/src/identity/.eslintrc.js b/src/identity/.eslintrc.js deleted file mode 100644 index b88d1be..0000000 --- a/src/identity/.eslintrc.js +++ /dev/null @@ -1,25 +0,0 @@ -module.exports = { - parser: '@typescript-eslint/parser', - parserOptions: { - project: 'tsconfig.json', - sourceType: 'module', - }, - plugins: ['@typescript-eslint/eslint-plugin'], - extends: [ - 'plugin:@typescript-eslint/recommended', - 'plugin:prettier/recommended', - ], - root: true, - env: { - node: true, - jest: true, - }, - ignorePatterns: ['.eslintrc.js'], - rules: { - '@typescript-eslint/interface-name-prefix': 'off', - '@typescript-eslint/explicit-function-return-type': 'off', - '@typescript-eslint/explicit-module-boundary-types': 'off', - '@typescript-eslint/no-explicit-any': 'off', - "@typescript-eslint/no-var-requires": "off" - }, -}; diff --git a/src/identity/.prettierignore b/src/identity/.prettierignore new file mode 100644 index 0000000..a7db0d7 --- /dev/null +++ b/src/identity/.prettierignore @@ -0,0 +1,3 @@ +node_modules/ +dist/ +build/ \ No newline at end of file diff --git a/src/identity/.prettierrc b/src/identity/.prettierrc index f4f39af..c6f2a11 100644 --- a/src/identity/.prettierrc +++ b/src/identity/.prettierrc @@ -1,5 +1,7 @@ { - "singleQuote": true, - "trailingComma": "all", - "tabWidth": 4 -} + "semi": true, + "tabWidth": 2, + "printWidth": 100, + "singleQuote": true, + "trailingComma": "none" +} \ No newline at end of file diff --git a/src/identity/eslint.config.js b/src/identity/eslint.config.js new file mode 100644 index 0000000..53c4d9d --- /dev/null +++ b/src/identity/eslint.config.js @@ -0,0 +1,12 @@ +// https://denar90.github.io/eslint.github.io/docs/rules/ +export default [ + { + rules: { + semi: 'error', + 'prefer-const': 'warn', + 'no-unused-vars': 'warn', + 'no-debugger': 'warn', + 'no-console': 'warn' + } + } +]; diff --git a/src/identity/nest-cli.json b/src/identity/nest-cli.json index 2e1000f..16afabf 100644 --- a/src/identity/nest-cli.json +++ b/src/identity/nest-cli.json @@ -1,7 +1,8 @@ { "collection": "@nestjs/schematics", - "sourceRoot": "src", + "sourceRoot": "identity/src", + "entryFile": "main", "compilerOptions": { "plugins": ["@nestjs/swagger/plugin"] } -} +} \ No newline at end of file diff --git a/src/identity/package.json b/src/identity/package.json index e13b93d..6b816c7 100644 --- a/src/identity/package.json +++ b/src/identity/package.json @@ -3,13 +3,13 @@ "description": "identity service", "version": "1.0.0", "main": "src/main.ts", - "author": "Meysam Hadeli", + "author": "Meysam", "license": "MIT", "scripts": { "build": "nest build", - "dev": "tsc -p tsconfig.json && nodemon src/main.ts --watch", - "format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"", - "lint": "eslint \"{src,apps,libs,test}/**/*.ts\" --fix", + "dev": "nest start --watch", + "format": "prettier --write \"**/*.{ts,js}\"", + "lint": "eslint . --fix", "typeorm": "npm run build && npx typeorm -d ./dist/identity/src/data/data-source.js", "migration:generate": "npm run typeorm -- migration:generate", "migration:run": "npm run typeorm -- migration:run", @@ -17,39 +17,41 @@ "test": "jest" }, "dependencies": { - "@nestjs/cli": "10.2.1", - "@nestjs/config": "^3.1.1", - "@nestjs/core": "10.2.10", - "@nestjs/cqrs": "^10.2.6", + "@nestjs/cli": "10.4.9", + "@nestjs/config": "^3.3.0", + "@nestjs/core": "10.4.15", + "@nestjs/cqrs": "^10.2.8", "@nestjs/jwt": "^10.2.0", - "@nestjs/mapped-types": "2.0.4", - "@nestjs/microservices": "^10.2.10", - "@nestjs/passport": "^10.0.2", - "@nestjs/platform-express": "^10.2.10", - "@nestjs/schematics": "10.0.3", - "@nestjs/swagger": "^7.1.16", - "@nestjs/terminus": "^10.1.1", - "@nestjs/testing": "10.2.10", - "@nestjs/typeorm": "^10.0.1", + "@nestjs/mapped-types": "2.0.6", + "@nestjs/microservices": "^10.4.15", + "@nestjs/passport": "^10.0.3", + "@nestjs/platform-express": "^10.4.15", + "@nestjs/schematics": "10.2.3", + "@nestjs/swagger": "^8.1.0", + "@nestjs/terminus": "^10.2.3", + "@nestjs/testing": "10.4.15", + "@nestjs/typeorm": "^10.0.2", "building-blocks": "file:../building-blocks", "class-transformer": "^0.5.1", - "class-validator": "^0.14.0", - "joi": "^17.10.1", - "moment": "^2.29.4", - "nodemon": "^3.0.2", - "pg": "^8.11.3", - "testcontainers": "^10.3.2", + "class-validator": "^0.14.1", + "joi": "^17.13.3", + "moment": "^2.30.1", + "nodemon": "^3.1.9", + "pg": "^8.13.1", + "testcontainers": "^10.16.0", "ts-mapper": "^1.2.4" }, "devDependencies": { - "@faker-js/faker": "^8.3.1", - "@types/express": "^4.17.21", - "@types/jest": "29.5.10", - "@types/supertest": "2.0.16", + "@faker-js/faker": "^9.3.0", + "@types/express": "^5.0.0", + "@types/jest": "29.5.14", + "@types/supertest": "6.0.2", "jest": "29.7.0", "jest-serial-runner": "^1.2.1", - "supertest": "6.3.3", - "ts-jest": "29.1.1", - "typemoq": "^2.1.0" + "supertest": "7.0.0", + "ts-jest": "29.2.5", + "typemoq": "^2.1.0", + "prettier": "3.4.2", + "eslint": "9.17.0" } } diff --git a/src/identity/src/app.module.ts b/src/identity/src/app.module.ts index 7f22280..243608b 100644 --- a/src/identity/src/app.module.ts +++ b/src/identity/src/app.module.ts @@ -1,54 +1,49 @@ -import {MiddlewareConsumer, Module, NestModule, OnApplicationBootstrap} from '@nestjs/common'; -import {RouterModule} from '@nestjs/core'; -import {TypeOrmModule} from '@nestjs/typeorm'; -import { UserModule } from "./user/user.module"; -import {AuthModule} from "./auth/auth.module"; -import {PassportModule, Type} from "@nestjs/passport"; -import {JwtModule} from "@nestjs/jwt"; -import {OpenTelemetryModule} from "building-blocks/openTelemetry/open-telemetry.module"; -import {JwtStrategy} from "building-blocks/passport/jwt.strategy"; -import configs from "building-blocks/configs/configs"; -import {DataSeeder} from "./data/seeds/data-seeder"; -import {HttpContextMiddleware} from "building-blocks/context/context"; -import {postgresOptions} from "./data/data-source"; +import { MiddlewareConsumer, Module, NestModule, OnApplicationBootstrap } from '@nestjs/common'; +import { RouterModule } from '@nestjs/core'; +import { TypeOrmModule } from '@nestjs/typeorm'; +import { UserModule } from './user/user.module'; +import { AuthModule } from './auth/auth.module'; +import { PassportModule, Type } from '@nestjs/passport'; +import { JwtModule } from '@nestjs/jwt'; +import { OpenTelemetryModule } from 'building-blocks/openTelemetry/open-telemetry.module'; +import { JwtStrategy } from 'building-blocks/passport/jwt.strategy'; +import configs from 'building-blocks/configs/configs'; +import { DataSeeder } from './data/seeds/data-seeder'; +import { HttpContextMiddleware } from 'building-blocks/context/context'; +import { postgresOptions } from './data/data-source'; @Module({ - imports: [ - PassportModule, - JwtModule.register({ - secret: configs.jwt.secret, - signOptions: {expiresIn: configs.jwt.refreshExpirationDays}, - }), - OpenTelemetryModule.forRoot(), - TypeOrmModule.forRoot(postgresOptions), - UserModule, - AuthModule, - RouterModule.register([ - { - path: '/', - module: UserModule, - }, - { - path: '/', - module: AuthModule, - }, - ]), - ], - providers: [JwtStrategy, DataSeeder], + imports: [ + PassportModule, + JwtModule.register({ + secret: configs.jwt.secret, + signOptions: { expiresIn: configs.jwt.refreshExpirationDays } + }), + OpenTelemetryModule.forRoot(), + TypeOrmModule.forRoot(postgresOptions), + UserModule, + AuthModule, + RouterModule.register([ + { + path: '/', + module: UserModule + }, + { + path: '/', + module: AuthModule + } + ]) + ], + providers: [JwtStrategy, DataSeeder] }) export class AppModule implements OnApplicationBootstrap, NestModule { - constructor( - private readonly dataSeeder: DataSeeder - ) {} + constructor(private readonly dataSeeder: DataSeeder) {} - configure(consumer: MiddlewareConsumer) { - consumer - .apply(HttpContextMiddleware) - .forRoutes('*'); - } + configure(consumer: MiddlewareConsumer) { + consumer.apply(HttpContextMiddleware).forRoutes('*'); + } - async onApplicationBootstrap(): Promise { - await this.dataSeeder.seedAsync(); - } + async onApplicationBootstrap(): Promise { + await this.dataSeeder.seedAsync(); + } } - diff --git a/src/identity/src/auth/auth.module.ts b/src/identity/src/auth/auth.module.ts index 68bdaa0..1c49a3d 100644 --- a/src/identity/src/auth/auth.module.ts +++ b/src/identity/src/auth/auth.module.ts @@ -1,32 +1,39 @@ -import {Module} from '@nestjs/common'; -import {CqrsModule} from '@nestjs/cqrs'; -import {TypeOrmModule} from '@nestjs/typeorm'; -import {Token} from "../auth/entities/token.entity"; -import {AuthRepository} from "../data/repositories/auth.repository"; -import {LoginController, LoginHandler} from "./features/v1/login/login"; -import {LogoutController, LogoutHandler} from "./features/v1/logout/logout"; -import {RefreshTokenController, RefreshTokenHandler} from "./features/v1/refresh-token/refresh-token"; -import {GenerateTokenHandler} from "./features/v1/generate-token/generate-token"; -import {ValidateTokenHandler} from "./features/v1/validate-token/validate-token"; -import {User} from "../user/entities/user.entity"; -import {UserRepository} from "../data/repositories/user.repository"; -import {RabbitmqModule} from "building-blocks/rabbitmq/rabbitmq.module"; -import {RabbitmqOptions} from "building-blocks/rabbitmq/rabbitmq-connection"; +import { Module } from '@nestjs/common'; +import { CqrsModule } from '@nestjs/cqrs'; +import { TypeOrmModule } from '@nestjs/typeorm'; +import { Token } from '../auth/entities/token.entity'; +import { AuthRepository } from '../data/repositories/auth.repository'; +import { LoginController, LoginHandler } from './features/v1/login/login'; +import { LogoutController, LogoutHandler } from './features/v1/logout/logout'; +import { + RefreshTokenController, + RefreshTokenHandler +} from './features/v1/refresh-token/refresh-token'; +import { GenerateTokenHandler } from './features/v1/generate-token/generate-token'; +import { ValidateTokenHandler } from './features/v1/validate-token/validate-token'; +import { User } from '../user/entities/user.entity'; +import { UserRepository } from '../data/repositories/user.repository'; +import { RabbitmqModule } from 'building-blocks/rabbitmq/rabbitmq.module'; +import { RabbitmqOptions } from 'building-blocks/rabbitmq/rabbitmq-connection'; @Module({ - imports: [CqrsModule, RabbitmqModule.forRoot(), TypeOrmModule.forFeature([Token, User])], - controllers: [LoginController, LogoutController, RefreshTokenController], - providers: [LoginHandler, GenerateTokenHandler, LogoutHandler, RefreshTokenHandler, ValidateTokenHandler, - { - provide: 'IAuthRepository', - useClass: AuthRepository, - }, - { - provide: 'IUserRepository', - useClass: UserRepository, - }, - ], - exports: [], + imports: [CqrsModule, RabbitmqModule.forRoot(), TypeOrmModule.forFeature([Token, User])], + controllers: [LoginController, LogoutController, RefreshTokenController], + providers: [ + LoginHandler, + GenerateTokenHandler, + LogoutHandler, + RefreshTokenHandler, + ValidateTokenHandler, + { + provide: 'IAuthRepository', + useClass: AuthRepository + }, + { + provide: 'IUserRepository', + useClass: UserRepository + } + ], + exports: [] }) -export class AuthModule { -} +export class AuthModule {} diff --git a/src/identity/src/auth/dtos/auth.dto.ts b/src/identity/src/auth/dtos/auth.dto.ts index ad17a0f..4635787 100644 --- a/src/identity/src/auth/dtos/auth.dto.ts +++ b/src/identity/src/auth/dtos/auth.dto.ts @@ -1,4 +1,4 @@ -import { TokenDto } from "./token.dto"; +import { TokenDto } from './token.dto'; export class AuthDto { access: TokenDto; diff --git a/src/identity/src/auth/entities/token.entity.ts b/src/identity/src/auth/entities/token.entity.ts index 12dc304..2ec2628 100644 --- a/src/identity/src/auth/entities/token.entity.ts +++ b/src/identity/src/auth/entities/token.entity.ts @@ -1,38 +1,38 @@ import { Column, Entity, ManyToOne, PrimaryGeneratedColumn } from 'typeorm'; -import { TokenType } from "../enums/token-type.enum"; -import { User } from "../../user/entities/user.entity"; +import { TokenType } from '../enums/token-type.enum'; +import { User } from '../../user/entities/user.entity'; @Entity() export class Token { - @PrimaryGeneratedColumn() - id: number; + @PrimaryGeneratedColumn() + id: number; - @Column() - token: string; + @Column() + token: string; - @Column() - refreshToken: string; + @Column() + refreshToken: string; - @Column() - expires: Date; + @Column() + expires: Date; - @Column() - type: TokenType; + @Column() + type: TokenType; - @Column() - blacklisted: boolean; + @Column() + blacklisted: boolean; - @Column() - createdAt: Date; + @Column() + createdAt: Date; - @ManyToOne(() => User, (user) => user.tokens, { onDelete: 'CASCADE' }) - user?: User; + @ManyToOne(() => User, (user) => user.tokens, { onDelete: 'CASCADE' }) + user?: User; - @Column() - userId: number; + @Column() + userId: number; - constructor(partial?: Partial) { - Object.assign(this, partial); - this.createdAt = partial?.createdAt ?? new Date(); - } + constructor(partial?: Partial) { + Object.assign(this, partial); + this.createdAt = partial?.createdAt ?? new Date(); + } } diff --git a/src/identity/src/auth/enums/token-type.enum.ts b/src/identity/src/auth/enums/token-type.enum.ts index 6462c84..4630a6f 100644 --- a/src/identity/src/auth/enums/token-type.enum.ts +++ b/src/identity/src/auth/enums/token-type.enum.ts @@ -1,4 +1,4 @@ export enum TokenType { - ACCESS = 0, - REFRESH = 1, + ACCESS = 0, + REFRESH = 1 } diff --git a/src/identity/src/auth/features/v1/generate-token/generate-token.ts b/src/identity/src/auth/features/v1/generate-token/generate-token.ts index aa8922a..d003754 100644 --- a/src/identity/src/auth/features/v1/generate-token/generate-token.ts +++ b/src/identity/src/auth/features/v1/generate-token/generate-token.ts @@ -1,13 +1,13 @@ import moment from 'moment'; import Joi from 'joi'; import jwt from 'jsonwebtoken'; -import {TokenType} from "../../../enums/token-type.enum"; -import {CommandHandler, ICommandHandler} from "@nestjs/cqrs"; -import {AuthDto} from "../../../dtos/auth.dto"; -import {Inject} from "@nestjs/common"; -import {IAuthRepository} from "../../../../data/repositories/auth.repository"; -import {Token} from "../../../entities/token.entity"; -import configs from "building-blocks/configs/configs"; +import { TokenType } from '../../../enums/token-type.enum'; +import { CommandHandler, ICommandHandler } from '@nestjs/cqrs'; +import { AuthDto } from '../../../dtos/auth.dto'; +import { Inject } from '@nestjs/common'; +import { IAuthRepository } from '../../../../data/repositories/auth.repository'; +import { Token } from '../../../entities/token.entity'; +import configs from 'building-blocks/configs/configs'; export class GenerateToken { userId: number; @@ -38,16 +38,11 @@ const generateJwtToken = ( return jwt.sign(payload, secret); }; - @CommandHandler(GenerateToken) export class GenerateTokenHandler implements ICommandHandler { + constructor(@Inject('IAuthRepository') private readonly authRepository: IAuthRepository) {} - constructor( - @Inject('IAuthRepository') private readonly authRepository: IAuthRepository, - ) {} - - async execute(command: GenerateToken): Promise { - + async execute(command: GenerateToken): Promise { await generateTokenValidations.params.validateAsync(command); const accessTokenExpires = moment().add(configs.jwt.accessExpirationMinutes, 'minutes'); diff --git a/src/identity/src/auth/features/v1/login/login.ts b/src/identity/src/auth/features/v1/login/login.ts index 78e58c6..6f406d3 100644 --- a/src/identity/src/auth/features/v1/login/login.ts +++ b/src/identity/src/auth/features/v1/login/login.ts @@ -1,88 +1,81 @@ import Joi from 'joi'; -import {GenerateToken} from '../generate-token/generate-token'; -import {ApiBearerAuth, ApiProperty, ApiResponse, ApiTags} from "@nestjs/swagger"; -import {Body, Controller, Get, HttpStatus, Inject, Post, UseGuards} from "@nestjs/common"; -import {AuthDto} from "../../../dtos/auth.dto"; -import {CommandBus, CommandHandler, ICommandHandler} from "@nestjs/cqrs"; -import {IAuthRepository} from "../../../../data/repositories/auth.repository"; -import {IUserRepository} from "../../../../data/repositories/user.repository"; -import {password} from "building-blocks/utils/validation"; -import {isPasswordMatch} from "building-blocks/utils/encryption"; -import ApplicationException from "building-blocks/types/exeptions/application.exception"; +import { GenerateToken } from '../generate-token/generate-token'; +import { ApiBearerAuth, ApiProperty, ApiResponse, ApiTags } from '@nestjs/swagger'; +import { Body, Controller, Get, HttpStatus, Inject, Post, UseGuards } from '@nestjs/common'; +import { AuthDto } from '../../../dtos/auth.dto'; +import { CommandBus, CommandHandler, ICommandHandler } from '@nestjs/cqrs'; +import { IAuthRepository } from '../../../../data/repositories/auth.repository'; +import { IUserRepository } from '../../../../data/repositories/user.repository'; +import { password } from 'building-blocks/utils/validation'; +import { isPasswordMatch } from 'building-blocks/utils/encryption'; +import ApplicationException from 'building-blocks/types/exeptions/application.exception'; export class Login { - email: string; - password: string; + email: string; + password: string; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } export class LoginRequestDto { - @ApiProperty() - email: string; + @ApiProperty() + email: string; - @ApiProperty() - password: string; + @ApiProperty() + password: string; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } const loginValidations = Joi.object({ - email: Joi.string().email().required(), - password: Joi.string().required().custom(password) + email: Joi.string().email().required(), + password: Joi.string().required().custom(password) }); @ApiBearerAuth() @ApiTags('Identities') @Controller({ - path: `/identity`, - version: '1', + path: `/identity`, + version: '1' }) export class LoginController { - - constructor(private readonly commandBus: CommandBus) { - } - - @Post('login') - @ApiResponse({status: 401, description: 'UNAUTHORIZED'}) - @ApiResponse({status: 400, description: 'BAD_REQUEST'}) - @ApiResponse({status: 403, description: 'FORBIDDEN'}) - @ApiResponse({status: 200, description: 'OK'}) - public async login(@Body() request: LoginRequestDto): Promise { - - const result = await this.commandBus.execute(new Login(request)); - - return result; - } + constructor(private readonly commandBus: CommandBus) {} + + @Post('login') + @ApiResponse({ status: 401, description: 'UNAUTHORIZED' }) + @ApiResponse({ status: 400, description: 'BAD_REQUEST' }) + @ApiResponse({ status: 403, description: 'FORBIDDEN' }) + @ApiResponse({ status: 200, description: 'OK' }) + public async login(@Body() request: LoginRequestDto): Promise { + const result = await this.commandBus.execute(new Login(request)); + + return result; + } } - - @CommandHandler(Login) export class LoginHandler implements ICommandHandler { + constructor( + @Inject('IAuthRepository') private readonly authRepository: IAuthRepository, + @Inject('IUserRepository') private readonly userRepository: IUserRepository, + private readonly commandBus: CommandBus + ) {} - constructor( - @Inject('IAuthRepository') private readonly authRepository: IAuthRepository, - @Inject('IUserRepository') private readonly userRepository: IUserRepository, - private readonly commandBus: CommandBus - ) {} - - async execute(command: Login): Promise { + async execute(command: Login): Promise { + await loginValidations.validateAsync(command); - await loginValidations.validateAsync(command); + const user = await this.userRepository.findUserByEmail(command.email); - const user = await this.userRepository.findUserByEmail(command.email); - - if (!user || !(await isPasswordMatch(command.password, user.password as string))) { - throw new ApplicationException('Incorrect email or password'); - } + if (!user || !(await isPasswordMatch(command.password, user.password as string))) { + throw new ApplicationException('Incorrect email or password'); + } - const token = await this.commandBus.execute(new GenerateToken({userId: user.id})); + const token = await this.commandBus.execute(new GenerateToken({ userId: user.id })); - return token; - } + return token; + } } diff --git a/src/identity/src/auth/features/v1/logout/logout.ts b/src/identity/src/auth/features/v1/logout/logout.ts index ac4eaa1..5bc00d7 100644 --- a/src/identity/src/auth/features/v1/logout/logout.ts +++ b/src/identity/src/auth/features/v1/logout/logout.ts @@ -1,71 +1,78 @@ import Joi from 'joi'; -import {ApiBearerAuth, ApiResponse, ApiTags} from "@nestjs/swagger"; -import {Body, Controller, HttpStatus, Inject, NotFoundException, Param, Post, Query, Res} from "@nestjs/common"; -import {CommandBus, CommandHandler, ICommandHandler} from "@nestjs/cqrs"; -import {Response} from "express"; -import {IAuthRepository} from "../../../../data/repositories/auth.repository"; -import {IUserRepository} from "../../../../data/repositories/user.repository"; -import {TokenType} from "../../../enums/token-type.enum"; +import { ApiBearerAuth, ApiResponse, ApiTags } from '@nestjs/swagger'; +import { + Body, + Controller, + HttpStatus, + Inject, + NotFoundException, + Param, + Post, + Query, + Res +} from '@nestjs/common'; +import { CommandBus, CommandHandler, ICommandHandler } from '@nestjs/cqrs'; +import { Response } from 'express'; +import { IAuthRepository } from '../../../../data/repositories/auth.repository'; +import { IUserRepository } from '../../../../data/repositories/user.repository'; +import { TokenType } from '../../../enums/token-type.enum'; export class Logout { - accessToken: string; + accessToken: string; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } const logoutValidations = { - params: Joi.object().keys({ - accessToken: Joi.string().required() - }) + params: Joi.object().keys({ + accessToken: Joi.string().required() + }) }; @ApiBearerAuth() @ApiTags('Identities') @Controller({ - path: `/identity`, - version: '1', + path: `/identity`, + version: '1' }) export class LogoutController { - - constructor(private readonly commandBus: CommandBus) { - } - - @Post('logout') - @ApiResponse({status: 401, description: 'UNAUTHORIZED'}) - @ApiResponse({status: 400, description: 'BAD_REQUEST'}) - @ApiResponse({status: 403, description: 'FORBIDDEN'}) - @ApiResponse({status: 204, description: 'NO_CONTENT'}) - public async logout(@Body('accessToken') accessToken: string, @Res() res: Response): Promise { - - await this.commandBus.execute(new Logout({accessToken: accessToken})); - - res.status(HttpStatus.NO_CONTENT).send(null); - } + constructor(private readonly commandBus: CommandBus) {} + + @Post('logout') + @ApiResponse({ status: 401, description: 'UNAUTHORIZED' }) + @ApiResponse({ status: 400, description: 'BAD_REQUEST' }) + @ApiResponse({ status: 403, description: 'FORBIDDEN' }) + @ApiResponse({ status: 204, description: 'NO_CONTENT' }) + public async logout( + @Body('accessToken') accessToken: string, + @Res() res: Response + ): Promise { + await this.commandBus.execute(new Logout({ accessToken: accessToken })); + + res.status(HttpStatus.NO_CONTENT).send(null); + } } @CommandHandler(Logout) export class LogoutHandler implements ICommandHandler { + constructor( + @Inject('IAuthRepository') private readonly authRepository: IAuthRepository, + @Inject('IUserRepository') private readonly userRepository: IUserRepository + ) {} - constructor( - @Inject('IAuthRepository') private readonly authRepository: IAuthRepository, - @Inject('IUserRepository') private readonly userRepository: IUserRepository - ) { - } - - async execute(command: Logout): Promise { + async execute(command: Logout): Promise { + await logoutValidations.params.validateAsync(command); - await logoutValidations.params.validateAsync(command); + const token = await this.authRepository.findToken(command.accessToken, TokenType.ACCESS); - const token = await this.authRepository.findToken(command.accessToken, TokenType.ACCESS); - - if (!token) { - throw new NotFoundException('Access Token Not found'); - } + if (!token) { + throw new NotFoundException('Access Token Not found'); + } - const tokenEntity = await this.authRepository.removeToken(token); + const tokenEntity = await this.authRepository.removeToken(token); - return tokenEntity?.userId; - } + return tokenEntity?.userId; + } } diff --git a/src/identity/src/auth/features/v1/refresh-token/refresh-token.ts b/src/identity/src/auth/features/v1/refresh-token/refresh-token.ts index eea5673..06a8e6e 100644 --- a/src/identity/src/auth/features/v1/refresh-token/refresh-token.ts +++ b/src/identity/src/auth/features/v1/refresh-token/refresh-token.ts @@ -1,80 +1,76 @@ import Joi from 'joi'; -import {GenerateToken} from '../generate-token/generate-token'; -import {ApiBearerAuth, ApiResponse, ApiTags} from "@nestjs/swagger"; -import {Body, Controller, Inject, Post, Query, UnauthorizedException} from "@nestjs/common"; -import {CommandBus, CommandHandler, ICommandHandler} from "@nestjs/cqrs"; -import {AuthDto} from "../../../dtos/auth.dto"; -import {IAuthRepository} from "../../../../data/repositories/auth.repository"; -import {IUserRepository} from "../../../../data/repositories/user.repository"; -import {TokenType} from "../../../enums/token-type.enum"; -import {ValidateToken} from "../validate-token/validate-token"; +import { GenerateToken } from '../generate-token/generate-token'; +import { ApiBearerAuth, ApiResponse, ApiTags } from '@nestjs/swagger'; +import { Body, Controller, Inject, Post, Query, UnauthorizedException } from '@nestjs/common'; +import { CommandBus, CommandHandler, ICommandHandler } from '@nestjs/cqrs'; +import { AuthDto } from '../../../dtos/auth.dto'; +import { IAuthRepository } from '../../../../data/repositories/auth.repository'; +import { IUserRepository } from '../../../../data/repositories/user.repository'; +import { TokenType } from '../../../enums/token-type.enum'; +import { ValidateToken } from '../validate-token/validate-token'; export class RefreshToken { - refreshToken: string; + refreshToken: string; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } const refreshTokenValidations = { - params: Joi.object().keys({ - refreshToken: Joi.string().required() - }) + params: Joi.object().keys({ + refreshToken: Joi.string().required() + }) }; @ApiBearerAuth() @ApiTags('Identities') @Controller({ - path: `/identity`, - version: '1', + path: `/identity`, + version: '1' }) export class RefreshTokenController { + constructor(private readonly commandBus: CommandBus) {} - constructor(private readonly commandBus: CommandBus) { - } - - @Post('refresh-token') - @ApiResponse({status: 401, description: 'UNAUTHORIZED'}) - @ApiResponse({status: 400, description: 'BAD_REQUEST'}) - @ApiResponse({status: 403, description: 'FORBIDDEN'}) - @ApiResponse({status: 200, description: 'OK'}) - public async refreshToken(@Body('refreshToken') refreshToken: string): Promise { - const result = await this.commandBus.execute(new RefreshToken({refreshToken: refreshToken})); + @Post('refresh-token') + @ApiResponse({ status: 401, description: 'UNAUTHORIZED' }) + @ApiResponse({ status: 400, description: 'BAD_REQUEST' }) + @ApiResponse({ status: 403, description: 'FORBIDDEN' }) + @ApiResponse({ status: 200, description: 'OK' }) + public async refreshToken(@Body('refreshToken') refreshToken: string): Promise { + const result = await this.commandBus.execute(new RefreshToken({ refreshToken: refreshToken })); - return result; - } + return result; + } } @CommandHandler(RefreshToken) export class RefreshTokenHandler implements ICommandHandler { - constructor( - @Inject('IAuthRepository') private readonly authRepository: IAuthRepository, - @Inject('IUserRepository') private readonly userRepository: IUserRepository, - private readonly commandBus: CommandBus - ) { - } - - async execute(command: RefreshToken): Promise { + constructor( + @Inject('IAuthRepository') private readonly authRepository: IAuthRepository, + @Inject('IUserRepository') private readonly userRepository: IUserRepository, + private readonly commandBus: CommandBus + ) {} - await refreshTokenValidations.params.validateAsync(command); + async execute(command: RefreshToken): Promise { + await refreshTokenValidations.params.validateAsync(command); - try { - const refreshTokenData = await this.commandBus.execute( - new ValidateToken({ - token: command.refreshToken, - type: TokenType.REFRESH - }) - ); - const {userId} = refreshTokenData; + try { + const refreshTokenData = await this.commandBus.execute( + new ValidateToken({ + token: command.refreshToken, + type: TokenType.REFRESH + }) + ); + const { userId } = refreshTokenData; - await this.authRepository.removeToken(refreshTokenData); + await this.authRepository.removeToken(refreshTokenData); - const result = await this.commandBus.execute(new GenerateToken({userId: userId})); + const result = await this.commandBus.execute(new GenerateToken({ userId: userId })); - return result; - } catch (error) { - throw new UnauthorizedException('Please authenticate'); - } + return result; + } catch (error) { + throw new UnauthorizedException('Please authenticate'); } + } } diff --git a/src/identity/src/auth/features/v1/validate-token/validate-token.ts b/src/identity/src/auth/features/v1/validate-token/validate-token.ts index c835700..41365c7 100644 --- a/src/identity/src/auth/features/v1/validate-token/validate-token.ts +++ b/src/identity/src/auth/features/v1/validate-token/validate-token.ts @@ -1,12 +1,12 @@ import Joi from 'joi'; import jwt from 'jsonwebtoken'; -import {TokenType} from "../../../enums/token-type.enum"; -import {CommandHandler, ICommandHandler} from "@nestjs/cqrs"; -import {Inject, NotFoundException} from "@nestjs/common"; -import {IAuthRepository} from "../../../../data/repositories/auth.repository"; -import {IUserRepository} from "../../../../data/repositories/user.repository"; -import {Token} from "../../../entities/token.entity"; -import configs from "building-blocks/configs/configs"; +import { TokenType } from '../../../enums/token-type.enum'; +import { CommandHandler, ICommandHandler } from '@nestjs/cqrs'; +import { Inject, NotFoundException } from '@nestjs/common'; +import { IAuthRepository } from '../../../../data/repositories/auth.repository'; +import { IUserRepository } from '../../../../data/repositories/user.repository'; +import { Token } from '../../../entities/token.entity'; +import configs from 'building-blocks/configs/configs'; export class ValidateToken { token: string; @@ -24,14 +24,12 @@ const validateTokenValidations = Joi.object({ @CommandHandler(ValidateToken) export class ValidateTokenHandler implements ICommandHandler { - constructor( - @Inject('IAuthRepository') private readonly authRepository: IAuthRepository, - @Inject('IUserRepository') private readonly userRepository: IUserRepository - ) { - } - - async execute(command: ValidateToken): Promise { + constructor( + @Inject('IAuthRepository') private readonly authRepository: IAuthRepository, + @Inject('IUserRepository') private readonly userRepository: IUserRepository + ) {} + async execute(command: ValidateToken): Promise { await validateTokenValidations.validateAsync(command); const payload = jwt.verify(command.token, configs.jwt.secret); @@ -39,18 +37,10 @@ export class ValidateTokenHandler implements ICommandHandler { let token: Token = null; - if(command.type == TokenType.REFRESH){ - token = await this.authRepository.findRefreshTokenByUserId( - command.token, - userId, - false - ); - }else { - token = await this.authRepository.findTokenByUserId( - command.token, - userId, - false - ); + if (command.type == TokenType.REFRESH) { + token = await this.authRepository.findRefreshTokenByUserId(command.token, userId, false); + } else { + token = await this.authRepository.findTokenByUserId(command.token, userId, false); } if (!token) { diff --git a/src/identity/src/auth/mappings.ts b/src/identity/src/auth/mappings.ts index d9bc864..408905f 100644 --- a/src/identity/src/auth/mappings.ts +++ b/src/identity/src/auth/mappings.ts @@ -1,7 +1,6 @@ import { TypeMapper } from 'ts-mapper'; -import { Token } from "./entities/token.entity"; -import { TokenDto } from "./dtos/token.dto"; - +import { Token } from './entities/token.entity'; +import { TokenDto } from './dtos/token.dto'; export class Mapper extends TypeMapper { constructor() { diff --git a/src/identity/src/data/data-source.ts b/src/identity/src/data/data-source.ts index 65bae2a..9c1b125 100644 --- a/src/identity/src/data/data-source.ts +++ b/src/identity/src/data/data-source.ts @@ -1,19 +1,19 @@ import { DataSource, DataSourceOptions } from 'typeorm'; -import configs from "building-blocks/configs/configs"; +import configs from 'building-blocks/configs/configs'; // use this file for running migration export const postgresOptions: DataSourceOptions = { - type: 'postgres', - host: configs.postgres.host, - port: configs.postgres.port, - username: configs.postgres.username, - password: configs.postgres.password, - database: configs.postgres.database, - synchronize: configs.postgres.synchronize, - entities: [__dirname + configs.postgres.entities], - migrations: [__dirname + configs.postgres.migrations], - logging: configs.postgres.logging, - migrationsRun: configs.postgres.migrationsRun, + type: 'postgres', + host: configs.postgres.host, + port: configs.postgres.port, + username: configs.postgres.username, + password: configs.postgres.password, + database: configs.postgres.database, + synchronize: configs.postgres.synchronize, + entities: [__dirname + configs.postgres.entities], + migrations: [__dirname + configs.postgres.migrations], + logging: configs.postgres.logging, + migrationsRun: configs.postgres.migrationsRun }; const dataSource = new DataSource(postgresOptions); diff --git a/src/identity/src/data/migrations/1702504925976-create-user-table.ts b/src/identity/src/data/migrations/1735158168560-create-user-table.ts similarity index 84% rename from src/identity/src/data/migrations/1702504925976-create-user-table.ts rename to src/identity/src/data/migrations/1735158168560-create-user-table.ts index 41c5e80..60cafea 100644 --- a/src/identity/src/data/migrations/1702504925976-create-user-table.ts +++ b/src/identity/src/data/migrations/1735158168560-create-user-table.ts @@ -1,10 +1,9 @@ import { MigrationInterface, QueryRunner } from "typeorm"; -export class CreateUserTable1702504925976 implements MigrationInterface { - name = 'CreateUserTable1702504925976' +export class CreateUserTable1735158168560 implements MigrationInterface { + name = 'CreateUserTable1735158168560' public async up(queryRunner: QueryRunner): Promise { - await queryRunner.query(`CREATE TYPE "public"."user_role_enum" AS ENUM('0', '1')`); await queryRunner.query(`CREATE TABLE "user" ("id" SERIAL NOT NULL, "email" character varying NOT NULL, "name" character varying NOT NULL, "password" character varying NOT NULL, "isEmailVerified" boolean NOT NULL, "role" "public"."user_role_enum" NOT NULL DEFAULT '0', "passportNumber" character varying NOT NULL, "createdAt" TIMESTAMP NOT NULL, "updatedAt" TIMESTAMP, CONSTRAINT "PK_cace4a159ff9f2512dd42373760" PRIMARY KEY ("id"))`); await queryRunner.query(`CREATE TABLE "token" ("id" SERIAL NOT NULL, "token" character varying NOT NULL, "refreshToken" character varying NOT NULL, "expires" TIMESTAMP NOT NULL, "type" integer NOT NULL, "blacklisted" boolean NOT NULL, "createdAt" TIMESTAMP NOT NULL, "userId" integer NOT NULL, CONSTRAINT "PK_82fae97f905930df5d62a702fc9" PRIMARY KEY ("id"))`); await queryRunner.query(`ALTER TABLE "token" ADD CONSTRAINT "FK_94f168faad896c0786646fa3d4a" FOREIGN KEY ("userId") REFERENCES "user"("id") ON DELETE CASCADE ON UPDATE NO ACTION`); @@ -14,7 +13,6 @@ export class CreateUserTable1702504925976 implements MigrationInterface { await queryRunner.query(`ALTER TABLE "token" DROP CONSTRAINT "FK_94f168faad896c0786646fa3d4a"`); await queryRunner.query(`DROP TABLE "token"`); await queryRunner.query(`DROP TABLE "user"`); - await queryRunner.query(`DROP TYPE "public"."user_role_enum"`); } } diff --git a/src/identity/src/data/repositories/auth.repository.ts b/src/identity/src/data/repositories/auth.repository.ts index e0a6b81..8c0cfda 100644 --- a/src/identity/src/data/repositories/auth.repository.ts +++ b/src/identity/src/data/repositories/auth.repository.ts @@ -1,32 +1,29 @@ -import {Repository} from 'typeorm'; -import {InjectRepository} from "@nestjs/typeorm"; -import {TokenType} from "../../auth/enums/token-type.enum"; -import {Token} from "../../auth/entities/token.entity"; +import { Repository } from 'typeorm'; +import { InjectRepository } from '@nestjs/typeorm'; +import { TokenType } from '../../auth/enums/token-type.enum'; +import { Token } from '../../auth/entities/token.entity'; export interface IAuthRepository { createToken(token: Token): Promise; findToken(token: string, tokenType: TokenType): Promise; - findTokenByUserId( - token: string, - userId: number, - blacklisted: boolean - ): Promise; + findTokenByUserId(token: string, userId: number, blacklisted: boolean): Promise; findRefreshTokenByUserId( - refreshToken: string, - userId: number, - blacklisted: boolean + refreshToken: string, + userId: number, + blacklisted: boolean ): Promise; removeToken(token: Token): Promise; } export class AuthRepository implements IAuthRepository { - constructor(@InjectRepository(Token) - private readonly tokenRepository: Repository) { - } + constructor( + @InjectRepository(Token) + private readonly tokenRepository: Repository + ) {} async createToken(token: Token): Promise { await this.tokenRepository.save(token); @@ -39,11 +36,7 @@ export class AuthRepository implements IAuthRepository { }); } - async findTokenByUserId( - token: string, - userId: number, - blacklisted: boolean - ): Promise { + async findTokenByUserId(token: string, userId: number, blacklisted: boolean): Promise { return await this.tokenRepository.findOneBy({ token: token, userId: userId, @@ -52,9 +45,9 @@ export class AuthRepository implements IAuthRepository { } async findRefreshTokenByUserId( - refreshToken: string, - userId: number, - blacklisted: boolean + refreshToken: string, + userId: number, + blacklisted: boolean ): Promise { return await this.tokenRepository.findOneBy({ refreshToken: refreshToken, diff --git a/src/identity/src/data/repositories/user.repository.ts b/src/identity/src/data/repositories/user.repository.ts index 4b84a1f..99b788d 100644 --- a/src/identity/src/data/repositories/user.repository.ts +++ b/src/identity/src/data/repositories/user.repository.ts @@ -1,7 +1,7 @@ -import { Repository, SelectQueryBuilder } from "typeorm"; -import { User } from "../../user/entities/user.entity"; -import { InjectRepository } from "@nestjs/typeorm"; -import {Injectable} from "@nestjs/common"; +import { Repository, SelectQueryBuilder } from 'typeorm'; +import { User } from '../../user/entities/user.entity'; +import { InjectRepository } from '@nestjs/typeorm'; +import { Injectable } from '@nestjs/common'; export interface IUserRepository { createUser(user: User): Promise; @@ -12,7 +12,7 @@ export interface IUserRepository { page: number, pageSize: number, orderBy: string, - order: "ASC" | "DESC", + order: 'ASC' | 'DESC', searchTerm?: string ): Promise<[User[], number]>; @@ -29,9 +29,10 @@ export interface IUserRepository { @Injectable() export class UserRepository implements IUserRepository { - constructor(@InjectRepository(User) - private readonly userRepository: Repository) { - } + constructor( + @InjectRepository(User) + private readonly userRepository: Repository + ) {} async createUser(user: User): Promise { return await this.userRepository.save(user); @@ -45,21 +46,21 @@ export class UserRepository implements IUserRepository { page: number, pageSize: number, orderBy: string, - order: "ASC" | "DESC", + order: 'ASC' | 'DESC', searchTerm?: string ): Promise<[User[], number]> { const skip = (page - 1) * pageSize; const take = pageSize; const queryBuilder: SelectQueryBuilder = this.userRepository - .createQueryBuilder("user") + .createQueryBuilder('user') .orderBy(`user.${orderBy}`, order) .skip(skip) .take(take); // Apply filter criteria to the query if (searchTerm) { - queryBuilder.andWhere("user.name LIKE :name", { name: `%${searchTerm}%` }); + queryBuilder.andWhere('user.name LIKE :name', { name: `%${searchTerm}%` }); } return await queryBuilder.getManyAndCount(); diff --git a/src/identity/src/data/seeds/data-seeder.ts b/src/identity/src/data/seeds/data-seeder.ts index f750598..fe6077e 100644 --- a/src/identity/src/data/seeds/data-seeder.ts +++ b/src/identity/src/data/seeds/data-seeder.ts @@ -1,34 +1,31 @@ -import {Injectable} from '@nestjs/common'; -import {EntityManager} from "typeorm"; -import {User} from "../../user/entities/user.entity"; -import {Role} from "../../user/enums/role.enum"; -import {encryptPassword} from "building-blocks/utils/encryption"; +import { Injectable } from '@nestjs/common'; +import { EntityManager } from 'typeorm'; +import { User } from '../../user/entities/user.entity'; +import { Role } from '../../user/enums/role.enum'; +import { encryptPassword } from 'building-blocks/utils/encryption'; @Injectable() export class DataSeeder { - constructor(private readonly entityManager: EntityManager - ) { - } - - async seedAsync(): Promise { - await this.seedUser(); - } + constructor(private readonly entityManager: EntityManager) {} - private async seedUser(): Promise { + async seedAsync(): Promise { + await this.seedUser(); + } - const userRepository = this.entityManager.getRepository(User); - if ((await userRepository.find())?.length == 0) { - await userRepository.save( - new User({ - id: 1, - name: 'developer', - email: 'dev@dev.com', - password: await encryptPassword('Admin@12345'), - role: Role.ADMIN, - passportNumber: '12345678', - isEmailVerified: true, - }) - ); - } + private async seedUser(): Promise { + const userRepository = this.entityManager.getRepository(User); + if ((await userRepository.find())?.length == 0) { + await userRepository.save( + new User({ + id: 1, + name: 'developer', + email: 'dev@dev.com', + password: await encryptPassword('Admin@12345'), + role: Role.ADMIN, + passportNumber: '12345678', + isEmailVerified: true + }) + ); } + } } diff --git a/src/identity/src/main.ts b/src/identity/src/main.ts index 448003c..0b543b7 100644 --- a/src/identity/src/main.ts +++ b/src/identity/src/main.ts @@ -1,49 +1,49 @@ -import {NestFactory} from '@nestjs/core'; -import {AppModule} from './app.module'; -import {Logger, ValidationPipe, VersioningType} from '@nestjs/common'; -import {DocumentBuilder, SwaggerModule} from '@nestjs/swagger'; -import {PrometheusMetrics} from "building-blocks/monitoring/prometheus.metrics"; -import {ErrorHandlersFilter} from "building-blocks/filters/error-handlers.filter"; -import configs from "building-blocks/configs/configs"; -import {Request, Response} from "express"; +import { NestFactory } from '@nestjs/core'; +import { AppModule } from './app.module'; +import { Logger, ValidationPipe, VersioningType } from '@nestjs/common'; +import { DocumentBuilder, SwaggerModule } from '@nestjs/swagger'; +import { PrometheusMetrics } from 'building-blocks/monitoring/prometheus.metrics'; +import { ErrorHandlersFilter } from 'building-blocks/filters/error-handlers.filter'; +import configs from 'building-blocks/configs/configs'; +import { Request, Response } from 'express'; async function bootstrap() { - const app = await NestFactory.create(AppModule); + const app = await NestFactory.create(AppModule); - app.enableShutdownHooks(); + app.enableShutdownHooks(); - const globalPrefix = 'api'; - app.setGlobalPrefix(globalPrefix); - const port = configs.port || 3333; + const globalPrefix = 'api'; + app.setGlobalPrefix(globalPrefix); + const port = configs.port || 3333; - app.enableVersioning({ - type: VersioningType.URI, - }); + app.enableVersioning({ + type: VersioningType.URI + }); - const config = new DocumentBuilder() - .setTitle(`${configs.serviceName}`) - .setDescription(`${configs.serviceName} api description`) - .setVersion('1.0') - .addBearerAuth() - .build(); - const document = SwaggerModule.createDocument(app, config); - SwaggerModule.setup('swagger', app, document); + const config = new DocumentBuilder() + .setTitle(`${configs.serviceName}`) + .setDescription(`${configs.serviceName} api description`) + .setVersion('1.0') + .addBearerAuth() + .build(); + const document = SwaggerModule.createDocument(app, config); + SwaggerModule.setup('swagger', app, document); - app.useGlobalPipes(new ValidationPipe({transform: true})); + app.useGlobalPipes(new ValidationPipe({ transform: true })); - app.use((req: Request, res: Response, next: any) => { - if (req.originalUrl == '/' || req.originalUrl.includes('favicon.ico')) { - return res.send(configs.serviceName); - } - return next(); - }); + app.use((req: Request, res: Response, next: any) => { + if (req.originalUrl == '/' || req.originalUrl.includes('favicon.ico')) { + return res.send(configs.serviceName); + } + return next(); + }); - PrometheusMetrics.registerMetricsEndpoint(app); + PrometheusMetrics.registerMetricsEndpoint(app); - app.useGlobalFilters(new ErrorHandlersFilter()); + app.useGlobalFilters(new ErrorHandlersFilter()); - await app.listen(port); - Logger.log(`🚀 Application is running on: http://localhost:${port}`); + await app.listen(port); + Logger.log(`🚀 Application is running on: http://localhost:${port}`); } bootstrap(); diff --git a/src/identity/src/user/dtos/user.dto.ts b/src/identity/src/user/dtos/user.dto.ts index e3943a4..408aee0 100644 --- a/src/identity/src/user/dtos/user.dto.ts +++ b/src/identity/src/user/dtos/user.dto.ts @@ -1,4 +1,4 @@ -import { Role } from "../enums/role.enum"; +import { Role } from '../enums/role.enum'; export class UserDto { id: number; diff --git a/src/identity/src/user/entities/user.entity.ts b/src/identity/src/user/entities/user.entity.ts index 5c35aab..0eedc05 100644 --- a/src/identity/src/user/entities/user.entity.ts +++ b/src/identity/src/user/entities/user.entity.ts @@ -4,42 +4,42 @@ import { Token } from '../../auth/entities/token.entity'; @Entity() export class User { - @PrimaryGeneratedColumn() - id: number; + @PrimaryGeneratedColumn() + id: number; - @Column() - email: string; + @Column() + email: string; - @Column() - name: string; + @Column() + name: string; - @Column() - password: string; + @Column() + password: string; - @Column() - isEmailVerified: boolean; + @Column() + isEmailVerified: boolean; - @Column({ - type: 'enum', - enum: Role, // Use the Role enum for this column - default: Role.USER, // Set a default role if needed - }) - role: Role; + @Column({ + type: 'enum', + enum: Role, // Use the Role enum for this column + default: Role.USER // Set a default role if needed + }) + role: Role; - @Column() - passportNumber: string; + @Column() + passportNumber: string; - @Column() - createdAt: Date; + @Column() + createdAt: Date; - @Column({ nullable: true }) // Making 'updatedAt' nullable - updatedAt?: Date | null; // You can use 'Date | null' to allow null values + @Column({ nullable: true }) // Making 'updatedAt' nullable + updatedAt?: Date | null; // You can use 'Date | null' to allow null values - @OneToMany(() => Token, (token) => token.user) - tokens: Token[]; + @OneToMany(() => Token, (token) => token.user) + tokens: Token[]; - constructor(partial?: Partial) { - Object.assign(this, partial); - this.createdAt = partial?.createdAt ?? new Date(); - } + constructor(partial?: Partial) { + Object.assign(this, partial); + this.createdAt = partial?.createdAt ?? new Date(); + } } diff --git a/src/identity/src/user/enums/role.enum.ts b/src/identity/src/user/enums/role.enum.ts index e7f8863..de77119 100644 --- a/src/identity/src/user/enums/role.enum.ts +++ b/src/identity/src/user/enums/role.enum.ts @@ -1,4 +1,4 @@ export enum Role { - USER = 0, - ADMIN = 1, + USER = 0, + ADMIN = 1 } diff --git a/src/identity/src/user/features/v1/create-user/create-user.ts b/src/identity/src/user/features/v1/create-user/create-user.ts index 89d01a4..900f703 100644 --- a/src/identity/src/user/features/v1/create-user/create-user.ts +++ b/src/identity/src/user/features/v1/create-user/create-user.ts @@ -1,28 +1,37 @@ -import {UserDto} from '../../../dtos/user.dto'; -import {Role} from "../../../enums/role.enum"; -import {ApiBearerAuth, ApiProperty, ApiResponse, ApiTags} from "@nestjs/swagger"; -import {Body, ConflictException, Controller, HttpStatus, Inject, Post, Res, UseGuards} from "@nestjs/common"; -import {CommandBus, CommandHandler, ICommandHandler} from "@nestjs/cqrs"; -import {User} from "../../../entities/user.entity"; -import {IUserRepository} from "../../../../data/repositories/user.repository"; -import Joi from "joi"; -import {Response} from "express"; -import {JwtGuard} from "building-blocks/passport/jwt.guard"; -import {IRabbitmqPublisher} from "building-blocks/rabbitmq/rabbitmq-publisher"; -import {password} from "building-blocks/utils/validation"; -import {UserCreated} from "building-blocks/contracts/identity.contract"; -import {encryptPassword} from "building-blocks/utils/encryption"; -import mapper from "../../../mapping"; +import { UserDto } from '../../../dtos/user.dto'; +import { Role } from '../../../enums/role.enum'; +import { ApiBearerAuth, ApiProperty, ApiResponse, ApiTags } from '@nestjs/swagger'; +import { + Body, + ConflictException, + Controller, + HttpStatus, + Inject, + Post, + Res, + UseGuards +} from '@nestjs/common'; +import { CommandBus, CommandHandler, ICommandHandler } from '@nestjs/cqrs'; +import { User } from '../../../entities/user.entity'; +import { IUserRepository } from '../../../../data/repositories/user.repository'; +import Joi from 'joi'; +import { Response } from 'express'; +import { JwtGuard } from 'building-blocks/passport/jwt.guard'; +import { IRabbitmqPublisher } from 'building-blocks/rabbitmq/rabbitmq-publisher'; +import { password } from 'building-blocks/utils/validation'; +import { UserCreated } from 'building-blocks/contracts/identity.contract'; +import { encryptPassword } from 'building-blocks/utils/encryption'; +import mapper from '../../../mapping'; export class CreateUser { - email: string; - password: string; - name: string; - role: Role; - passportNumber: string; - - constructor(request: Partial = {}) { - Object.assign(this, request); + email: string; + password: string; + name: string; + role: Role; + passportNumber: string; + + constructor(request: Partial = {}) { + Object.assign(this, request); } } @@ -47,48 +56,48 @@ export class CreateUserRequestDto { } } - @ApiBearerAuth() @ApiTags('Users') @Controller({ path: `/user`, - version: '1', + version: '1' }) export class CreateUserController { constructor(private readonly commandBus: CommandBus) {} - @Post('create') - @UseGuards(JwtGuard) - @ApiResponse({status: 401, description: 'UNAUTHORIZED'}) - @ApiResponse({status: 400, description: 'BAD_REQUEST'}) - @ApiResponse({status: 403, description: 'FORBIDDEN'}) - @ApiResponse({status: 201, description: 'CREATED'}) - public async createUser(@Body() request: CreateUserRequestDto, @Res() res: Response): Promise { - - const result = await this.commandBus.execute(new CreateUser({ - email: request.email, - password: request.password, - name: request.name, - role: request.role, - passportNumber: request.passportNumber - })); - - res.status(HttpStatus.CREATED).send(result); - - return result; - } -} + @Post('create') + @UseGuards(JwtGuard) + @ApiResponse({ status: 401, description: 'UNAUTHORIZED' }) + @ApiResponse({ status: 400, description: 'BAD_REQUEST' }) + @ApiResponse({ status: 403, description: 'FORBIDDEN' }) + @ApiResponse({ status: 201, description: 'CREATED' }) + public async createUser( + @Body() request: CreateUserRequestDto, + @Res() res: Response + ): Promise { + const result = await this.commandBus.execute( + new CreateUser({ + email: request.email, + password: request.password, + name: request.name, + role: request.role, + passportNumber: request.passportNumber + }) + ); + res.status(HttpStatus.CREATED).send(result); + + return result; + } +} @CommandHandler(CreateUser) export class CreateUserHandler implements ICommandHandler { constructor( @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, - @Inject('IUserRepository') private readonly userRepository: IUserRepository, + @Inject('IUserRepository') private readonly userRepository: IUserRepository ) {} async execute(command: CreateUser): Promise { - - const createUserValidations = Joi.object({ email: Joi.string().required().email(), password: Joi.string().required().custom(password), @@ -97,7 +106,7 @@ export class CreateUserHandler implements ICommandHandler { role: Joi.string().required().valid(Role.USER, Role.ADMIN) }); - await createUserValidations.validateAsync(command); + await createUserValidations.validateAsync(command); const existUser = await this.userRepository.findUserByEmail(command.email); diff --git a/src/identity/src/user/features/v1/delete-user-by-id/delete-user-by-id.ts b/src/identity/src/user/features/v1/delete-user-by-id/delete-user-by-id.ts index 77ff31d..16dbb85 100644 --- a/src/identity/src/user/features/v1/delete-user-by-id/delete-user-by-id.ts +++ b/src/identity/src/user/features/v1/delete-user-by-id/delete-user-by-id.ts @@ -1,82 +1,91 @@ -import {UserDto} from '../../../dtos/user.dto'; +import { UserDto } from '../../../dtos/user.dto'; import Joi from 'joi'; -import {ApiBearerAuth, ApiResponse, ApiTags} from "@nestjs/swagger"; -import {CommandBus, CommandHandler, ICommandHandler} from "@nestjs/cqrs"; -import {Controller, Delete, HttpStatus, Inject, NotFoundException, Query, Res, UseGuards} from "@nestjs/common"; +import { ApiBearerAuth, ApiResponse, ApiTags } from '@nestjs/swagger'; +import { CommandBus, CommandHandler, ICommandHandler } from '@nestjs/cqrs'; +import { + Controller, + Delete, + HttpStatus, + Inject, + NotFoundException, + Query, + Res, + UseGuards +} from '@nestjs/common'; import { Response } from 'express'; -import {IUserRepository} from "../../../../data/repositories/user.repository"; -import {User} from "../../../entities/user.entity"; -import {JwtGuard} from "building-blocks/passport/jwt.guard"; -import {IRabbitmqPublisher} from "building-blocks/rabbitmq/rabbitmq-publisher"; -import {UserDeleted} from "building-blocks/contracts/identity.contract"; -import mapper from "../../../mapping"; +import { IUserRepository } from '../../../../data/repositories/user.repository'; +import { User } from '../../../entities/user.entity'; +import { JwtGuard } from 'building-blocks/passport/jwt.guard'; +import { IRabbitmqPublisher } from 'building-blocks/rabbitmq/rabbitmq-publisher'; +import { UserDeleted } from 'building-blocks/contracts/identity.contract'; +import mapper from '../../../mapping'; export class DeleteUserById { - id: number; + id: number; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } const deleteUserValidations = { - params: Joi.object().keys({ - id: Joi.number().integer().required() - }) + params: Joi.object().keys({ + id: Joi.number().integer().required() + }) }; @ApiBearerAuth() @ApiTags('Users') @Controller({ - path: `/user`, - version: '1', + path: `/user`, + version: '1' }) export class DeleteUserByIdController { - constructor(private readonly commandBus: CommandBus) { + constructor(private readonly commandBus: CommandBus) {} + + @Delete('delete') + @UseGuards(JwtGuard) + @ApiResponse({ status: 200, description: 'OK' }) + @ApiResponse({ status: 401, description: 'UNAUTHORIZED' }) + @ApiResponse({ status: 400, description: 'BAD_REQUEST' }) + @ApiResponse({ status: 403, description: 'FORBIDDEN' }) + public async deleteUserById(@Query('id') id: number, @Res() res: Response): Promise { + const user = await this.commandBus.execute( + new DeleteUserById({ + id: id + }) + ); + + if (!user) { + throw new NotFoundException('User not found'); } - @Delete('delete') - @UseGuards(JwtGuard) - @ApiResponse({ status: 200, description: 'OK' }) - @ApiResponse({status: 401, description: 'UNAUTHORIZED'}) - @ApiResponse({status: 400, description: 'BAD_REQUEST'}) - @ApiResponse({status: 403, description: 'FORBIDDEN'}) - public async deleteUserById(@Query('id') id: number, @Res() res: Response): Promise { - - const user = await this.commandBus.execute( new DeleteUserById({ - id: id - })); - - if (!user) { - throw new NotFoundException('User not found'); - } - - return user; - } + return user; + } } @CommandHandler(DeleteUserById) export class DeleteUserByIdHandler implements ICommandHandler { - constructor( - @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, - @Inject('IUserRepository') private readonly userRepository: IUserRepository, - ) {} + constructor( + @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, + @Inject('IUserRepository') private readonly userRepository: IUserRepository + ) {} - async execute(command: DeleteUserById): Promise { - await deleteUserValidations.params.validateAsync(command); + async execute(command: DeleteUserById): Promise { + await deleteUserValidations.params.validateAsync(command); - const user = await this.userRepository.findUserById(command.id); + const user = await this.userRepository.findUserById(command.id); - if (!user) { - throw new NotFoundException('User not found'); - } + if (!user) { + throw new NotFoundException('User not found'); + } - const userEntity = await this.userRepository.removeUser(user); + const userEntity = await this.userRepository.removeUser(user); - await this.rabbitmqPublisher.publishMessage(new UserDeleted(userEntity)); + await this.rabbitmqPublisher.publishMessage(new UserDeleted(userEntity)); - const result = mapper.map(userEntity, new UserDto()); + const result = mapper.map(userEntity, new UserDto()); - return result; - } + return result; + } } diff --git a/src/identity/src/user/features/v1/get-user-by-id/get-user-by-id.ts b/src/identity/src/user/features/v1/get-user-by-id/get-user-by-id.ts index d9c93c2..936c9fc 100644 --- a/src/identity/src/user/features/v1/get-user-by-id/get-user-by-id.ts +++ b/src/identity/src/user/features/v1/get-user-by-id/get-user-by-id.ts @@ -1,70 +1,76 @@ -import {UserDto} from '../../../dtos/user.dto'; +import { UserDto } from '../../../dtos/user.dto'; import Joi from 'joi'; -import {ApiBearerAuth, ApiResponse, ApiTags} from "@nestjs/swagger"; -import {Controller, Get, Inject, NotFoundException, Param, Query, UseGuards} from "@nestjs/common"; -import {IQueryHandler, QueryBus, QueryHandler} from "@nestjs/cqrs"; -import {IUserRepository} from "../../../../data/repositories/user.repository"; -import {User} from "../../../entities/user.entity"; -import {JwtGuard} from "../../../../../../building-blocks/passport/jwt.guard"; -import mapper from "../../../mapping"; +import { ApiBearerAuth, ApiResponse, ApiTags } from '@nestjs/swagger'; +import { + Controller, + Get, + Inject, + NotFoundException, + Param, + Query, + UseGuards +} from '@nestjs/common'; +import { IQueryHandler, QueryBus, QueryHandler } from '@nestjs/cqrs'; +import { IUserRepository } from '../../../../data/repositories/user.repository'; +import { User } from '../../../entities/user.entity'; +import { JwtGuard } from '../../../../../../building-blocks/passport/jwt.guard'; +import mapper from '../../../mapping'; export class GetUserById { - id: number; + id: number; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } const getUserByIdValidations = { - params: Joi.object().keys({ - id: Joi.number().integer().required() - }) + params: Joi.object().keys({ + id: Joi.number().integer().required() + }) }; @ApiBearerAuth() @ApiTags('Users') @Controller({ - path: `/user`, - version: '1', + path: `/user`, + version: '1' }) export class GetUserByIdController { - constructor(private readonly queryBus: QueryBus) { - } + constructor(private readonly queryBus: QueryBus) {} - @Get('get-by-id') - @UseGuards(JwtGuard) - @ApiResponse({status: 200, description: 'OK'}) - @ApiResponse({status: 401, description: 'UNAUTHORIZED'}) - @ApiResponse({status: 400, description: 'BAD_REQUEST'}) - @ApiResponse({status: 403, description: 'FORBIDDEN'}) - public async getUserById(@Query('id') id: number): Promise { + @Get('get-by-id') + @UseGuards(JwtGuard) + @ApiResponse({ status: 200, description: 'OK' }) + @ApiResponse({ status: 401, description: 'UNAUTHORIZED' }) + @ApiResponse({ status: 400, description: 'BAD_REQUEST' }) + @ApiResponse({ status: 403, description: 'FORBIDDEN' }) + public async getUserById(@Query('id') id: number): Promise { + const result = await this.queryBus.execute( + new GetUserById({ + id: id + }) + ); - const result = await this.queryBus.execute(new GetUserById({ - id: id - })); - - return result; - } + return result; + } } @QueryHandler(GetUserById) export class GetUserByIdHandler implements IQueryHandler { - constructor( - @Inject('IUserRepository') private readonly userRepository: IUserRepository) { - } + constructor(@Inject('IUserRepository') private readonly userRepository: IUserRepository) {} - async execute(query: GetUserById): Promise { - await getUserByIdValidations.params.validateAsync(query); + async execute(query: GetUserById): Promise { + await getUserByIdValidations.params.validateAsync(query); - const usersEntity = await this.userRepository.findUserById(query.id); + const usersEntity = await this.userRepository.findUserById(query.id); - if (!usersEntity) { - throw new NotFoundException('User not found'); - } + if (!usersEntity) { + throw new NotFoundException('User not found'); + } - const result = mapper.map(usersEntity, new UserDto()); + const result = mapper.map(usersEntity, new UserDto()); - return result; - } + return result; + } } diff --git a/src/identity/src/user/features/v1/get-users/get-users.ts b/src/identity/src/user/features/v1/get-users/get-users.ts index e6bed48..b387fcd 100644 --- a/src/identity/src/user/features/v1/get-users/get-users.ts +++ b/src/identity/src/user/features/v1/get-users/get-users.ts @@ -1,13 +1,13 @@ -import {UserDto} from '../../../dtos/user.dto'; +import { UserDto } from '../../../dtos/user.dto'; import Joi from 'joi'; -import {ApiBearerAuth, ApiQuery, ApiResponse, ApiTags} from "@nestjs/swagger"; -import {Controller, Get, Inject, ParseBoolPipe, Query, UseGuards} from "@nestjs/common"; -import {IQueryHandler, QueryBus, QueryHandler} from "@nestjs/cqrs"; -import {IUserRepository} from "../../../../data/repositories/user.repository"; -import {User} from "../../../entities/user.entity"; -import {JwtGuard} from "../../../../../../building-blocks/passport/jwt.guard"; -import {PagedResult} from "building-blocks/types/pagination/paged-result"; -import mapper from "../../../mapping"; +import { ApiBearerAuth, ApiQuery, ApiResponse, ApiTags } from '@nestjs/swagger'; +import { Controller, Get, Inject, ParseBoolPipe, Query, UseGuards } from '@nestjs/common'; +import { IQueryHandler, QueryBus, QueryHandler } from '@nestjs/cqrs'; +import { IUserRepository } from '../../../../data/repositories/user.repository'; +import { User } from '../../../entities/user.entity'; +import { JwtGuard } from '../../../../../../building-blocks/passport/jwt.guard'; +import { PagedResult } from 'building-blocks/types/pagination/paged-result'; +import mapper from '../../../mapping'; export class GetUsers { page = 1; @@ -33,60 +33,56 @@ const getUsersValidations = Joi.object({ @ApiTags('Users') @Controller({ path: `/user`, - version: '1', + version: '1' }) export class GetUsersController { - - constructor(private readonly queryBus: QueryBus) { - } + constructor(private readonly queryBus: QueryBus) {} @Get('get') @UseGuards(JwtGuard) - @ApiResponse({status: 200, description: 'OK'}) - @ApiResponse({status: 401, description: 'UNAUTHORIZED'}) - @ApiResponse({status: 400, description: 'BAD_REQUEST'}) - @ApiResponse({status: 403, description: 'FORBIDDEN'}) + @ApiResponse({ status: 200, description: 'OK' }) + @ApiResponse({ status: 401, description: 'UNAUTHORIZED' }) + @ApiResponse({ status: 400, description: 'BAD_REQUEST' }) + @ApiResponse({ status: 403, description: 'FORBIDDEN' }) @ApiQuery({ name: 'page', required: false, type: Number, example: 1 }) @ApiQuery({ name: 'pageSize', required: false, type: Number, example: 10 }) - @ApiQuery({ name: 'order', required: false, type: 'ASC' , example: 'ASC' }) + @ApiQuery({ name: 'order', required: false, type: 'ASC', example: 'ASC' }) @ApiQuery({ name: 'orderBy', required: false, type: '', example: 'id' }) @ApiQuery({ name: 'searchTerm', required: false, type: '' }) public async getUsers( - @Query('pageSize') pageSize: number = 10, - @Query('page') page: number = 1, - @Query('order') order: 'ASC' | 'DESC' = 'ASC', - @Query('orderBy') orderBy: string = 'id', - @Query('searchTerm') searchTerm?: string + @Query('pageSize') pageSize: number = 10, + @Query('page') page: number = 1, + @Query('order') order: 'ASC' | 'DESC' = 'ASC', + @Query('orderBy') orderBy: string = 'id', + @Query('searchTerm') searchTerm?: string ): Promise> { - - const result = await this.queryBus.execute(new GetUsers({ - page: page, - pageSize: pageSize, - searchTerm: searchTerm, - order: order, - orderBy: orderBy - })); + const result = await this.queryBus.execute( + new GetUsers({ + page: page, + pageSize: pageSize, + searchTerm: searchTerm, + order: order, + orderBy: orderBy + }) + ); return result; } } - @QueryHandler(GetUsers) export class GetUsersHandler implements IQueryHandler { - constructor( - @Inject('IUserRepository') private readonly userRepository: IUserRepository) { - } + constructor(@Inject('IUserRepository') private readonly userRepository: IUserRepository) {} async execute(command: GetUsers): Promise> { await getUsersValidations.validateAsync(command); const [usersEntity, total] = await this.userRepository.findUsers( - command.page, - command.pageSize, - command.orderBy, - command.order, - command.searchTerm + command.page, + command.pageSize, + command.orderBy, + command.order, + command.searchTerm ); if (usersEntity?.length == 0) return new PagedResult(null, total); diff --git a/src/identity/src/user/features/v1/update-user/update-user.ts b/src/identity/src/user/features/v1/update-user/update-user.ts index 0c3f9cf..d68d586 100644 --- a/src/identity/src/user/features/v1/update-user/update-user.ts +++ b/src/identity/src/user/features/v1/update-user/update-user.ts @@ -1,138 +1,136 @@ import Joi from 'joi'; -import {Role} from "../../../enums/role.enum"; -import {ApiBearerAuth, ApiProperty, ApiResponse, ApiTags} from "@nestjs/swagger"; +import { Role } from '../../../enums/role.enum'; +import { ApiBearerAuth, ApiProperty, ApiResponse, ApiTags } from '@nestjs/swagger'; import { - Body, - Controller, - HttpStatus, - Inject, - NotFoundException, - Param, - Put, - Res, - UseGuards -} from "@nestjs/common"; -import {CommandBus, CommandHandler, ICommandHandler} from "@nestjs/cqrs"; -import { Response} from "express"; -import {IUserRepository} from "../../../../data/repositories/user.repository"; -import {User} from "../../../entities/user.entity"; -import {password} from "building-blocks/utils/validation"; -import {JwtGuard} from "building-blocks/passport/jwt.guard"; -import {IRabbitmqPublisher} from "building-blocks/rabbitmq/rabbitmq-publisher"; -import {encryptPassword} from "building-blocks/utils/encryption"; -import {UserUpdated} from "building-blocks/contracts/identity.contract"; + Body, + Controller, + HttpStatus, + Inject, + NotFoundException, + Param, + Put, + Res, + UseGuards +} from '@nestjs/common'; +import { CommandBus, CommandHandler, ICommandHandler } from '@nestjs/cqrs'; +import { Response } from 'express'; +import { IUserRepository } from '../../../../data/repositories/user.repository'; +import { User } from '../../../entities/user.entity'; +import { password } from 'building-blocks/utils/validation'; +import { JwtGuard } from 'building-blocks/passport/jwt.guard'; +import { IRabbitmqPublisher } from 'building-blocks/rabbitmq/rabbitmq-publisher'; +import { encryptPassword } from 'building-blocks/utils/encryption'; +import { UserUpdated } from 'building-blocks/contracts/identity.contract'; export class UpdateUser { - id: number; - email: string; - password: string; - name: string; - role: Role; - passportNumber: string; - - constructor(request: Partial = {}) { - Object.assign(this, request); - } + id: number; + email: string; + password: string; + name: string; + role: Role; + passportNumber: string; + + constructor(request: Partial = {}) { + Object.assign(this, request); + } } export class UpdateUserRequestDto { - @ApiProperty() - email: string; + @ApiProperty() + email: string; - @ApiProperty() - password: string; + @ApiProperty() + password: string; - @ApiProperty() - name: string; + @ApiProperty() + name: string; - @ApiProperty() - role: Role; + @ApiProperty() + role: Role; - @ApiProperty() - passportNumber: string; + @ApiProperty() + passportNumber: string; - constructor(request: Partial = {}) { - Object.assign(this, request); - } + constructor(request: Partial = {}) { + Object.assign(this, request); + } } const updateUserValidations = Joi.object({ - id: Joi.number().required(), - email: Joi.string().required().email(), - password: Joi.string().required().custom(password), - name: Joi.string().required(), - passportNumber: Joi.string().required(), - role: Joi.string().required().valid(Role.USER, Role.ADMIN) + id: Joi.number().required(), + email: Joi.string().required().email(), + password: Joi.string().required().custom(password), + name: Joi.string().required(), + passportNumber: Joi.string().required(), + role: Joi.string().required().valid(Role.USER, Role.ADMIN) }); @ApiBearerAuth() @ApiTags('Users') @Controller({ - path: `/user`, - version: '1', + path: `/user`, + version: '1' }) export class UpdateUserController { - - constructor(private readonly commandBus: CommandBus,) { - } - - @Put('update/:id') - @UseGuards(JwtGuard) - @ApiResponse({status: 204, description: 'NO_CONTENT'}) - @ApiResponse({status: 401, description: 'UNAUTHORIZED'}) - @ApiResponse({status: 400, description: 'BAD_REQUEST'}) - @ApiResponse({status: 403, description: 'FORBIDDEN'}) - public async updateUser( - @Param('id') id: number, - @Body() request: UpdateUserRequestDto, - @Res() res: Response - ): Promise { - - await this.commandBus.execute(new UpdateUser({ - id: id, - email: request.email, - password: request.password, - name: request.name, - role: request.role, - passportNumber: request.passportNumber - })); - - res.status(HttpStatus.NO_CONTENT).send(null); - } + constructor(private readonly commandBus: CommandBus) {} + + @Put('update/:id') + @UseGuards(JwtGuard) + @ApiResponse({ status: 204, description: 'NO_CONTENT' }) + @ApiResponse({ status: 401, description: 'UNAUTHORIZED' }) + @ApiResponse({ status: 400, description: 'BAD_REQUEST' }) + @ApiResponse({ status: 403, description: 'FORBIDDEN' }) + public async updateUser( + @Param('id') id: number, + @Body() request: UpdateUserRequestDto, + @Res() res: Response + ): Promise { + await this.commandBus.execute( + new UpdateUser({ + id: id, + email: request.email, + password: request.password, + name: request.name, + role: request.role, + passportNumber: request.passportNumber + }) + ); + + res.status(HttpStatus.NO_CONTENT).send(null); + } } @CommandHandler(UpdateUser) -export class UpdateUserHandler implements ICommandHandler { +export class UpdateUserHandler implements ICommandHandler { + constructor( + @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, + @Inject('IUserRepository') private readonly userRepository: IUserRepository + ) {} - constructor( - @Inject('IRabbitmqPublisher') private readonly rabbitmqPublisher: IRabbitmqPublisher, - @Inject('IUserRepository') private readonly userRepository: IUserRepository) {} + async execute(command: UpdateUser): Promise { + await updateUserValidations.validateAsync(command); - async execute(command: UpdateUser): Promise { + const existUser = await this.userRepository.findUserById(command.id); - await updateUserValidations.validateAsync(command); - - const existUser = await this.userRepository.findUserById(command.id); - - if (!existUser) { - throw new NotFoundException('User not found'); - } - - const updateUserEntity = new User({ - id: command.id, - email: command.email, - name: command.name, - password: await encryptPassword(command.password), - role: command.role, - passportNumber: command.passportNumber, - isEmailVerified: existUser.isEmailVerified, - tokens: existUser.tokens, - createdAt: existUser.createdAt, - updatedAt: new Date() - }); - - await this.userRepository.updateUser(updateUserEntity); - - await this.rabbitmqPublisher.publishMessage(new UserUpdated(updateUserEntity)); + if (!existUser) { + throw new NotFoundException('User not found'); } + + const updateUserEntity = new User({ + id: command.id, + email: command.email, + name: command.name, + password: await encryptPassword(command.password), + role: command.role, + passportNumber: command.passportNumber, + isEmailVerified: existUser.isEmailVerified, + tokens: existUser.tokens, + createdAt: existUser.createdAt, + updatedAt: new Date() + }); + + await this.userRepository.updateUser(updateUserEntity); + + await this.rabbitmqPublisher.publishMessage(new UserUpdated(updateUserEntity)); + } } diff --git a/src/identity/src/user/mapping.ts b/src/identity/src/user/mapping.ts index 5f45544..408e5d5 100644 --- a/src/identity/src/user/mapping.ts +++ b/src/identity/src/user/mapping.ts @@ -1,6 +1,6 @@ import { UserDto } from './dtos/user.dto'; import { TypeMapper } from 'ts-mapper'; -import { User } from "./entities/user.entity"; +import { User } from './entities/user.entity'; export class Mapper extends TypeMapper { constructor() { diff --git a/src/identity/src/user/user.module.ts b/src/identity/src/user/user.module.ts index 9534cc5..4c061de 100644 --- a/src/identity/src/user/user.module.ts +++ b/src/identity/src/user/user.module.ts @@ -1,35 +1,48 @@ -import {Module} from '@nestjs/common'; -import {CqrsModule} from '@nestjs/cqrs'; -import {TypeOrmModule} from '@nestjs/typeorm'; -import {User} from "../user/entities/user.entity"; -import {CreateUserController, CreateUserHandler} from "./features/v1/create-user/create-user"; -import {UserRepository} from "../data/repositories/user.repository"; +import { Module } from '@nestjs/common'; +import { CqrsModule } from '@nestjs/cqrs'; +import { TypeOrmModule } from '@nestjs/typeorm'; +import { User } from '../user/entities/user.entity'; +import { CreateUserController, CreateUserHandler } from './features/v1/create-user/create-user'; +import { UserRepository } from '../data/repositories/user.repository'; import { DeleteUserByIdController, DeleteUserByIdHandler -} from "./features/v1/delete-user-by-id/delete-user-by-id"; -import {UpdateUserController, UpdateUserHandler} from "./features/v1/update-user/update-user"; -import {GetUsersController, GetUsersHandler} from "./features/v1/get-users/get-users"; -import {GetUserByIdController, GetUserByIdHandler} from "./features/v1/get-user-by-id/get-user-by-id"; -import {Token} from "../auth/entities/token.entity"; -import {AuthRepository} from "../data/repositories/auth.repository"; -import {RabbitmqModule} from "building-blocks/rabbitmq/rabbitmq.module"; -import {RabbitmqOptions} from "building-blocks/rabbitmq/rabbitmq-connection"; +} from './features/v1/delete-user-by-id/delete-user-by-id'; +import { UpdateUserController, UpdateUserHandler } from './features/v1/update-user/update-user'; +import { GetUsersController, GetUsersHandler } from './features/v1/get-users/get-users'; +import { + GetUserByIdController, + GetUserByIdHandler +} from './features/v1/get-user-by-id/get-user-by-id'; +import { Token } from '../auth/entities/token.entity'; +import { AuthRepository } from '../data/repositories/auth.repository'; +import { RabbitmqModule } from 'building-blocks/rabbitmq/rabbitmq.module'; +import { RabbitmqOptions } from 'building-blocks/rabbitmq/rabbitmq-connection'; @Module({ imports: [CqrsModule, RabbitmqModule.forRoot(), TypeOrmModule.forFeature([User, Token])], - controllers: [CreateUserController, DeleteUserByIdController, UpdateUserController, GetUsersController, GetUserByIdController], - providers: [CreateUserHandler, DeleteUserByIdHandler, UpdateUserHandler, GetUsersHandler, GetUserByIdHandler, + controllers: [ + CreateUserController, + DeleteUserByIdController, + UpdateUserController, + GetUsersController, + GetUserByIdController + ], + providers: [ + CreateUserHandler, + DeleteUserByIdHandler, + UpdateUserHandler, + GetUsersHandler, + GetUserByIdHandler, { provide: 'IUserRepository', - useClass: UserRepository, + useClass: UserRepository }, { provide: 'IAuthRepository', - useClass: AuthRepository, + useClass: AuthRepository } - ], - exports: [], + ], + exports: [] }) - -export class UserModule {} \ No newline at end of file +export class UserModule {} diff --git a/src/identity/test/end-to-end-test/user/features/create-user.test.d.ts b/src/identity/test/end-to-end-test/user/features/create-user.test.d.ts new file mode 100644 index 0000000..d2c9bc6 --- /dev/null +++ b/src/identity/test/end-to-end-test/user/features/create-user.test.d.ts @@ -0,0 +1 @@ +import 'reflect-metadata'; diff --git a/src/identity/test/end-to-end-test/user/features/create-user.test.js b/src/identity/test/end-to-end-test/user/features/create-user.test.js new file mode 100644 index 0000000..ad1ae49 --- /dev/null +++ b/src/identity/test/end-to-end-test/user/features/create-user.test.js @@ -0,0 +1,23 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +require("reflect-metadata"); +const end_to_end_fixture_1 = require("../../../shared/fixtures/end-to-end.fixture"); +const fake_create_user_request_dto_1 = require("../../../shared/fakes/user/fake-create-user-request.dto"); +const request = require('supertest'); +describe('end-to-end test for create user', () => { + const endToEndFixture = new end_to_end_fixture_1.EndToEndTestFixture(); + let fixture; + beforeAll(async () => { + fixture = await endToEndFixture.initializeFixture(); + }); + afterAll(async () => { + await endToEndFixture.cleanUp(); + }); + it('should create user and retrieve 201 status code', async () => { + const createUserResponse = await request(fixture.app.getHttpServer()) + .post('/api/v1/user/create') + .send(fake_create_user_request_dto_1.FakeCreateUserRequestDto.generate()) + .expect(201); + }); +}); +//# sourceMappingURL=create-user.test.js.map \ No newline at end of file diff --git a/src/identity/test/end-to-end-test/user/features/create-user.test.js.map b/src/identity/test/end-to-end-test/user/features/create-user.test.js.map new file mode 100644 index 0000000..51c70e5 --- /dev/null +++ b/src/identity/test/end-to-end-test/user/features/create-user.test.js.map @@ -0,0 +1 @@ +{"version":3,"file":"create-user.test.js","sourceRoot":"","sources":["create-user.test.ts"],"names":[],"mappings":";;AAAA,4BAA0B;AAC1B,oFAAkF;AAElF,0GAAmG;AACnG,MAAM,OAAO,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC;AAErC,QAAQ,CAAC,iCAAiC,EAAE,GAAG,EAAE;IAC/C,MAAM,eAAe,GAAG,IAAI,wCAAmB,EAAE,CAAC;IAClD,IAAI,OAAgB,CAAC;IAErB,SAAS,CAAC,KAAK,IAAI,EAAE;QACnB,OAAO,GAAG,MAAM,eAAe,CAAC,iBAAiB,EAAE,CAAC;IACtD,CAAC,CAAC,CAAC;IAEH,QAAQ,CAAC,KAAK,IAAI,EAAE;QAClB,MAAM,eAAe,CAAC,OAAO,EAAE,CAAC;IAClC,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,iDAAiD,EAAE,KAAK,IAAI,EAAE;QAC/D,MAAM,kBAAkB,GAAG,MAAM,OAAO,CAAC,OAAO,CAAC,GAAG,CAAC,aAAa,EAAE,CAAC;aAClE,IAAI,CAAC,qBAAqB,CAAC;aAC3B,IAAI,CAAC,uDAAwB,CAAC,QAAQ,EAAE,CAAC;aACzC,MAAM,CAAC,GAAG,CAAC,CAAC;IACjB,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"} \ No newline at end of file diff --git a/src/identity/test/end-to-end-test/user/features/create-user.test.ts b/src/identity/test/end-to-end-test/user/features/create-user.test.ts index 44ccab1..f4c9f5e 100644 --- a/src/identity/test/end-to-end-test/user/features/create-user.test.ts +++ b/src/identity/test/end-to-end-test/user/features/create-user.test.ts @@ -1,7 +1,7 @@ import 'reflect-metadata'; -import {EndToEndTestFixture} from "../../../shared/fixtures/end-to-end.fixture"; -import {Fixture} from "../../../shared/fixtures/integration-test.fixture"; -import {FakeCreateUserRequestDto} from "../../../shared/fakes/user/fake-create-user-request.dto"; +import { EndToEndTestFixture } from '../../../shared/fixtures/end-to-end.fixture'; +import { Fixture } from '../../../shared/fixtures/integration-test.fixture'; +import { FakeCreateUserRequestDto } from '../../../shared/fakes/user/fake-create-user-request.dto'; const request = require('supertest'); describe('end-to-end test for create user', () => { diff --git a/src/identity/test/integration-test/user/features/create-user.test.d.ts b/src/identity/test/integration-test/user/features/create-user.test.d.ts new file mode 100644 index 0000000..d2c9bc6 --- /dev/null +++ b/src/identity/test/integration-test/user/features/create-user.test.d.ts @@ -0,0 +1 @@ +import 'reflect-metadata'; diff --git a/src/identity/test/integration-test/user/features/create-user.test.js b/src/identity/test/integration-test/user/features/create-user.test.js new file mode 100644 index 0000000..8f6dd50 --- /dev/null +++ b/src/identity/test/integration-test/user/features/create-user.test.js @@ -0,0 +1,23 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +require("reflect-metadata"); +const integration_test_fixture_1 = require("../../../shared/fixtures/integration-test.fixture"); +const fake_create_user_1 = require("../../../shared/fakes/user/fake-create-user"); +const identity_contract_1 = require("building-blocks/contracts/identity.contract"); +describe('integration test for create user', () => { + const integrationTestFixture = new integration_test_fixture_1.IntegrationTestFixture(); + let fixture; + beforeAll(async () => { + fixture = await integrationTestFixture.initializeFixture(); + }); + afterAll(async () => { + await integrationTestFixture.cleanUp(); + }); + it('should create user and retrieve a user from the database', async () => { + const result = await fixture.commandBus.execute(fake_create_user_1.FakeCreateUser.generate()); + const isPublished = await fixture.rabbitmqPublisher.isPublished(new identity_contract_1.UserCreated()); + expect(isPublished).toBe(true); + const user = fixture.userRepository.findUserById(result.id); + expect(user).not.toBeNull(); + }); +}); diff --git a/src/identity/test/integration-test/user/features/create-user.test.js.map b/src/identity/test/integration-test/user/features/create-user.test.js.map new file mode 100644 index 0000000..40ad22a --- /dev/null +++ b/src/identity/test/integration-test/user/features/create-user.test.js.map @@ -0,0 +1 @@ +{"version":3,"file":"create-user.test.js","sourceRoot":"","sources":["create-user.test.ts"],"names":[],"mappings":";;AAAA,4BAA0B;AAC1B,gGAAoG;AACpG,kFAA6E;AAC7E,mFAA0E;AAE1E,QAAQ,CAAC,kCAAkC,EAAE,GAAG,EAAE;IAChD,MAAM,sBAAsB,GAAG,IAAI,iDAAsB,EAAE,CAAC;IAC5D,IAAI,OAAgB,CAAC;IAErB,SAAS,CAAC,KAAK,IAAI,EAAE;QACnB,OAAO,GAAG,MAAM,sBAAsB,CAAC,iBAAiB,EAAE,CAAC;IAC7D,CAAC,CAAC,CAAC;IAEH,QAAQ,CAAC,KAAK,IAAI,EAAE;QAClB,MAAM,sBAAsB,CAAC,OAAO,EAAE,CAAC;IACzC,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,0DAA0D,EAAE,KAAK,IAAI,EAAE;QACxE,MAAM,MAAM,GAAG,MAAM,OAAO,CAAC,UAAU,CAAC,OAAO,CAAC,iCAAc,CAAC,QAAQ,EAAE,CAAC,CAAC;QAE3E,MAAM,WAAW,GAAG,MAAM,OAAO,CAAC,iBAAiB,CAAC,WAAW,CAAC,IAAI,+BAAW,EAAE,CAAC,CAAC;QACnF,MAAM,CAAC,WAAW,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAE/B,MAAM,IAAI,GAAG,OAAO,CAAC,cAAc,CAAC,YAAY,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC;QAC5D,MAAM,CAAC,IAAI,CAAC,CAAC,GAAG,CAAC,QAAQ,EAAE,CAAC;IAC9B,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"} \ No newline at end of file diff --git a/src/identity/test/integration-test/user/features/create-user.test.ts b/src/identity/test/integration-test/user/features/create-user.test.ts index 6b49ac0..4c3c449 100644 --- a/src/identity/test/integration-test/user/features/create-user.test.ts +++ b/src/identity/test/integration-test/user/features/create-user.test.ts @@ -1,7 +1,7 @@ import 'reflect-metadata'; -import {Fixture, IntegrationTestFixture} from "../../../shared/fixtures/integration-test.fixture"; -import {FakeCreateUser} from "../../../shared/fakes/user/fake-create-user"; -import {UserCreated} from "building-blocks/contracts/identity.contract"; +import { Fixture, IntegrationTestFixture } from '../../../shared/fixtures/integration-test.fixture'; +import { FakeCreateUser } from '../../../shared/fakes/user/fake-create-user'; +import { UserCreated } from 'building-blocks/contracts/identity.contract'; describe('integration test for create user', () => { const integrationTestFixture = new IntegrationTestFixture(); diff --git a/src/identity/test/shared/fakes/user/fake-create-user-request.dto.d.ts b/src/identity/test/shared/fakes/user/fake-create-user-request.dto.d.ts new file mode 100644 index 0000000..378630b --- /dev/null +++ b/src/identity/test/shared/fakes/user/fake-create-user-request.dto.d.ts @@ -0,0 +1,4 @@ +import { CreateUserRequestDto } from '../../../../src/user/features/v1/create-user/create-user'; +export declare class FakeCreateUserRequestDto { + static generate(): CreateUserRequestDto; +} diff --git a/src/identity/test/shared/fakes/user/fake-create-user-request.dto.js b/src/identity/test/shared/fakes/user/fake-create-user-request.dto.js new file mode 100644 index 0000000..0918384 --- /dev/null +++ b/src/identity/test/shared/fakes/user/fake-create-user-request.dto.js @@ -0,0 +1,22 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.FakeCreateUserRequestDto = void 0; +const openapi = require("@nestjs/swagger"); +const faker_1 = require("@faker-js/faker"); +const role_enum_1 = require("../../../../src/user/enums/role.enum"); +class FakeCreateUserRequestDto { + static generate() { + const createUserRequestDto = { + email: faker_1.faker.internet.email(), + password: 'Admin@1234', + name: faker_1.faker.person.fullName(), + role: role_enum_1.Role.USER, + passportNumber: faker_1.faker.string.numeric(9) + }; + return createUserRequestDto; + } + static _OPENAPI_METADATA_FACTORY() { + return {}; + } +} +exports.FakeCreateUserRequestDto = FakeCreateUserRequestDto; diff --git a/src/identity/test/shared/fakes/user/fake-create-user-request.dto.js.map b/src/identity/test/shared/fakes/user/fake-create-user-request.dto.js.map new file mode 100644 index 0000000..e688940 --- /dev/null +++ b/src/identity/test/shared/fakes/user/fake-create-user-request.dto.js.map @@ -0,0 +1 @@ +{"version":3,"file":"fake-create-user-request.dto.js","sourceRoot":"","sources":["fake-create-user-request.dto.ts"],"names":[],"mappings":";;;;AAAA,2CAAwC;AACxC,oEAA4D;AAG5D,MAAa,wBAAwB;IACnC,MAAM,CAAC,QAAQ;QACb,MAAM,oBAAoB,GAAG;YAC3B,KAAK,EAAE,aAAK,CAAC,QAAQ,CAAC,KAAK,EAAE;YAC7B,QAAQ,EAAE,YAAY;YACtB,IAAI,EAAE,aAAK,CAAC,MAAM,CAAC,QAAQ,EAAE;YAC7B,IAAI,EAAE,gBAAI,CAAC,IAAI;YACf,cAAc,EAAE,aAAK,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;SACxC,CAAC;QAEF,OAAO,oBAAoB,CAAC;IAC9B,CAAC;;;;CACF;AAZD,4DAYC"} \ No newline at end of file diff --git a/src/identity/test/shared/fakes/user/fake-create-user-request.dto.ts b/src/identity/test/shared/fakes/user/fake-create-user-request.dto.ts index dbdbc3b..78d3421 100644 --- a/src/identity/test/shared/fakes/user/fake-create-user-request.dto.ts +++ b/src/identity/test/shared/fakes/user/fake-create-user-request.dto.ts @@ -1,6 +1,6 @@ import { faker } from '@faker-js/faker'; -import {Role} from "../../../../src/user/enums/role.enum"; -import {CreateUserRequestDto} from "../../../../src/user/features/v1/create-user/create-user"; +import { Role } from '../../../../src/user/enums/role.enum'; +import { CreateUserRequestDto } from '../../../../src/user/features/v1/create-user/create-user'; export class FakeCreateUserRequestDto { static generate(): CreateUserRequestDto { diff --git a/src/identity/test/shared/fakes/user/fake-create-user.d.ts b/src/identity/test/shared/fakes/user/fake-create-user.d.ts new file mode 100644 index 0000000..dfd59fe --- /dev/null +++ b/src/identity/test/shared/fakes/user/fake-create-user.d.ts @@ -0,0 +1,5 @@ +import { User } from '../../../../src/user/entities/user.entity'; +import { CreateUser } from '../../../../src/user/features/v1/create-user/create-user'; +export declare class FakeCreateUser { + static generate(user?: User): CreateUser; +} diff --git a/src/identity/test/shared/fakes/user/fake-create-user.js b/src/identity/test/shared/fakes/user/fake-create-user.js new file mode 100644 index 0000000..4219023 --- /dev/null +++ b/src/identity/test/shared/fakes/user/fake-create-user.js @@ -0,0 +1,19 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.FakeCreateUser = void 0; +const faker_1 = require("@faker-js/faker"); +const role_enum_1 = require("../../../../src/user/enums/role.enum"); +const create_user_1 = require("../../../../src/user/features/v1/create-user/create-user"); +class FakeCreateUser { + static generate(user) { + const createUser = new create_user_1.CreateUser({ + name: user?.name ?? faker_1.faker.person.fullName(), + role: user?.role ?? role_enum_1.Role.USER, + password: user?.password ?? 'Admin@1234', + email: user?.email ?? faker_1.faker.internet.email(), + passportNumber: user?.passportNumber ?? faker_1.faker.string.numeric(9) + }); + return createUser; + } +} +exports.FakeCreateUser = FakeCreateUser; diff --git a/src/identity/test/shared/fakes/user/fake-create-user.js.map b/src/identity/test/shared/fakes/user/fake-create-user.js.map new file mode 100644 index 0000000..cd6987f --- /dev/null +++ b/src/identity/test/shared/fakes/user/fake-create-user.js.map @@ -0,0 +1 @@ +{"version":3,"file":"fake-create-user.js","sourceRoot":"","sources":["fake-create-user.ts"],"names":[],"mappings":";;;AAAA,2CAAwC;AAExC,oEAA4D;AAC5D,0FAAsF;AAEtF,MAAa,cAAc;IACzB,MAAM,CAAC,QAAQ,CAAC,IAAW;QACzB,MAAM,UAAU,GAAG,IAAI,wBAAU,CAAC;YAChC,IAAI,EAAE,IAAI,EAAE,IAAI,IAAI,aAAK,CAAC,MAAM,CAAC,QAAQ,EAAE;YAC3C,IAAI,EAAE,IAAI,EAAE,IAAI,IAAI,gBAAI,CAAC,IAAI;YAC7B,QAAQ,EAAE,IAAI,EAAE,QAAQ,IAAI,YAAY;YACxC,KAAK,EAAE,IAAI,EAAE,KAAK,IAAI,aAAK,CAAC,QAAQ,CAAC,KAAK,EAAE;YAC5C,cAAc,EAAE,IAAI,EAAE,cAAc,IAAI,aAAK,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;SAChE,CAAC,CAAC;QAEH,OAAO,UAAU,CAAC;IACpB,CAAC;CACF;AAZD,wCAYC"} \ No newline at end of file diff --git a/src/identity/test/shared/fakes/user/fake-create-user.ts b/src/identity/test/shared/fakes/user/fake-create-user.ts index afce57c..c5d51bf 100644 --- a/src/identity/test/shared/fakes/user/fake-create-user.ts +++ b/src/identity/test/shared/fakes/user/fake-create-user.ts @@ -1,7 +1,7 @@ import { faker } from '@faker-js/faker'; -import {User} from "../../../../src/user/entities/user.entity"; -import {Role} from "../../../../src/user/enums/role.enum"; -import {CreateUser} from "../../../../src/user/features/v1/create-user/create-user"; +import { User } from '../../../../src/user/entities/user.entity'; +import { Role } from '../../../../src/user/enums/role.enum'; +import { CreateUser } from '../../../../src/user/features/v1/create-user/create-user'; export class FakeCreateUser { static generate(user?: User): CreateUser { diff --git a/src/identity/test/shared/fakes/user/fake-user.entity.d.ts b/src/identity/test/shared/fakes/user/fake-user.entity.d.ts new file mode 100644 index 0000000..276784b --- /dev/null +++ b/src/identity/test/shared/fakes/user/fake-user.entity.d.ts @@ -0,0 +1,4 @@ +import { User } from '../../../../src/user/entities/user.entity'; +export declare class FakeUser { + static generate(): User; +} diff --git a/src/identity/test/shared/fakes/user/fake-user.entity.js b/src/identity/test/shared/fakes/user/fake-user.entity.js new file mode 100644 index 0000000..136548b --- /dev/null +++ b/src/identity/test/shared/fakes/user/fake-user.entity.js @@ -0,0 +1,26 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.FakeUser = void 0; +const openapi = require("@nestjs/swagger"); +const faker_1 = require("@faker-js/faker"); +const role_enum_1 = require("../../../../src/user/enums/role.enum"); +class FakeUser { + static generate() { + const user = { + id: 1, + name: faker_1.faker.person.fullName(), + role: role_enum_1.Role.USER, + password: 'Admin@1234', + email: faker_1.faker.internet.email(), + passportNumber: faker_1.faker.string.numeric(9), + isEmailVerified: false, + createdAt: faker_1.faker.date.anytime(), + tokens: [] + }; + return user; + } + static _OPENAPI_METADATA_FACTORY() { + return {}; + } +} +exports.FakeUser = FakeUser; diff --git a/src/identity/test/shared/fakes/user/fake-user.entity.js.map b/src/identity/test/shared/fakes/user/fake-user.entity.js.map new file mode 100644 index 0000000..4aa38a6 --- /dev/null +++ b/src/identity/test/shared/fakes/user/fake-user.entity.js.map @@ -0,0 +1 @@ +{"version":3,"file":"fake-user.entity.js","sourceRoot":"","sources":["fake-user.entity.ts"],"names":[],"mappings":";;;;AAAA,2CAAwC;AACxC,oEAA4D;AAG5D,MAAa,QAAQ;IACnB,MAAM,CAAC,QAAQ;QACb,MAAM,IAAI,GAAS;YACjB,EAAE,EAAE,CAAC;YACL,IAAI,EAAE,aAAK,CAAC,MAAM,CAAC,QAAQ,EAAE;YAC7B,IAAI,EAAE,gBAAI,CAAC,IAAI;YACf,QAAQ,EAAE,YAAY;YACtB,KAAK,EAAE,aAAK,CAAC,QAAQ,CAAC,KAAK,EAAE;YAC7B,cAAc,EAAE,aAAK,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;YACvC,eAAe,EAAE,KAAK;YACtB,SAAS,EAAE,aAAK,CAAC,IAAI,CAAC,OAAO,EAAE;YAC/B,MAAM,EAAE,EAAE;SACX,CAAC;QAEF,OAAO,IAAI,CAAC;IACd,CAAC;;;;CACF;AAhBD,4BAgBC"} \ No newline at end of file diff --git a/src/identity/test/shared/fakes/user/fake-user.entity.ts b/src/identity/test/shared/fakes/user/fake-user.entity.ts index fa4e1b7..d4c0c43 100644 --- a/src/identity/test/shared/fakes/user/fake-user.entity.ts +++ b/src/identity/test/shared/fakes/user/fake-user.entity.ts @@ -1,6 +1,6 @@ import { faker } from '@faker-js/faker'; -import {Role} from "../../../../src/user/enums/role.enum"; -import {User} from "../../../../src/user/entities/user.entity"; +import { Role } from '../../../../src/user/enums/role.enum'; +import { User } from '../../../../src/user/entities/user.entity'; export class FakeUser { static generate(): User { diff --git a/src/identity/test/shared/fixtures/end-to-end.fixture.d.ts b/src/identity/test/shared/fixtures/end-to-end.fixture.d.ts new file mode 100644 index 0000000..f11afa7 --- /dev/null +++ b/src/identity/test/shared/fixtures/end-to-end.fixture.d.ts @@ -0,0 +1,3 @@ +import { IntegrationTestFixture } from '/integration-test.fixture'; +export declare class EndToEndTestFixture extends IntegrationTestFixture { +} diff --git a/src/identity/test/shared/fixtures/end-to-end.fixture.js b/src/identity/test/shared/fixtures/end-to-end.fixture.js new file mode 100644 index 0000000..51ee0aa --- /dev/null +++ b/src/identity/test/shared/fixtures/end-to-end.fixture.js @@ -0,0 +1,8 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.EndToEndTestFixture = void 0; +const integration_test_fixture_1 = require("/integration-test.fixture"); +class EndToEndTestFixture extends integration_test_fixture_1.IntegrationTestFixture { +} +exports.EndToEndTestFixture = EndToEndTestFixture; +//# sourceMappingURL=end-to-end.fixture.js.map \ No newline at end of file diff --git a/src/identity/test/shared/fixtures/end-to-end.fixture.js.map b/src/identity/test/shared/fixtures/end-to-end.fixture.js.map new file mode 100644 index 0000000..e2a6d65 --- /dev/null +++ b/src/identity/test/shared/fixtures/end-to-end.fixture.js.map @@ -0,0 +1 @@ +{"version":3,"file":"end-to-end.fixture.js","sourceRoot":"","sources":["end-to-end.fixture.ts"],"names":[],"mappings":";;;AAAA,wEAAmE;AAEnE,MAAa,mBAAoB,SAAQ,iDAAsB;CAAG;AAAlE,kDAAkE"} \ No newline at end of file diff --git a/src/identity/test/shared/fixtures/end-to-end.fixture.ts b/src/identity/test/shared/fixtures/end-to-end.fixture.ts index f5aa5de..52279ed 100644 --- a/src/identity/test/shared/fixtures/end-to-end.fixture.ts +++ b/src/identity/test/shared/fixtures/end-to-end.fixture.ts @@ -1,3 +1,3 @@ -import {IntegrationTestFixture} from "./integration-test.fixture"; +import { IntegrationTestFixture } from './integration-test.fixture'; export class EndToEndTestFixture extends IntegrationTestFixture {} diff --git a/src/identity/test/shared/fixtures/integration-test.fixture.d.ts b/src/identity/test/shared/fixtures/integration-test.fixture.d.ts new file mode 100644 index 0000000..9dd02a0 --- /dev/null +++ b/src/identity/test/shared/fixtures/integration-test.fixture.d.ts @@ -0,0 +1,25 @@ +import { IUserRepository } from '../../../src/data/repositories/user.repository'; +import { INestApplication } from '@nestjs/common'; +import { IAuthRepository } from '../../../src/data/repositories/auth.repository'; +import { IRabbitmqConsumer } from 'building-blocks/rabbitmq/rabbitmq-subscriber'; +import { IRabbitmqPublisher } from 'building-blocks/rabbitmq/rabbitmq-publisher'; +import { CommandBus, QueryBus } from '@nestjs/cqrs'; +import { IRabbitmqConnection } from 'building-blocks/rabbitmq/rabbitmq-connection'; +import { StartedTestContainer } from 'testcontainers'; +export declare class Fixture { + userRepository: IUserRepository; + authRepository: IAuthRepository; + postgresContainer: StartedTestContainer; + rabbitmqContainer: StartedTestContainer; + rabbitmqConsumer: IRabbitmqConsumer; + rabbitmqConnection: IRabbitmqConnection; + rabbitmqPublisher: IRabbitmqPublisher; + commandBus: CommandBus; + queryBus: QueryBus; + app: INestApplication; +} +export declare class IntegrationTestFixture { + private fixture; + initializeFixture(): Promise; + cleanUp(): Promise; +} diff --git a/src/identity/test/shared/fixtures/integration-test.fixture.js b/src/identity/test/shared/fixtures/integration-test.fixture.js new file mode 100644 index 0000000..e0c407c --- /dev/null +++ b/src/identity/test/shared/fixtures/integration-test.fixture.js @@ -0,0 +1,95 @@ +"use strict"; +var __importDefault = (this && this.__importDefault) || function (mod) { + return (mod && mod.__esModule) ? mod : { "default": mod }; +}; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.IntegrationTestFixture = exports.Fixture = void 0; +const common_1 = require("@nestjs/common"); +const testing_1 = require("@nestjs/testing"); +const postgres_container_1 = require("building-blocks/test/container/postgres/postgres-container"); +const rabbitmq_container_1 = require("building-blocks/test/container/rabbitmq/rabbitmq-container"); +const cqrs_1 = require("@nestjs/cqrs"); +const passport_1 = require("@nestjs/passport"); +const jwt_1 = require("@nestjs/jwt"); +const configs_1 = __importDefault(require("building-blocks/configs/configs")); +const open_telemetry_module_1 = require("building-blocks/openTelemetry/open-telemetry.module"); +const typeorm_1 = require("@nestjs/typeorm"); +const user_module_1 = require("../../../src/user/user.module"); +const auth_module_1 = require("../../../src/auth/auth.module"); +const core_1 = require("@nestjs/core"); +const jwt_strategy_1 = require("building-blocks/passport/jwt.strategy"); +const jwt_guard_1 = require("building-blocks/passport/jwt.guard"); +class Fixture { + userRepository; + authRepository; + postgresContainer; + rabbitmqContainer; + rabbitmqConsumer; + rabbitmqConnection; + rabbitmqPublisher; + commandBus; + queryBus; + app; +} +exports.Fixture = Fixture; +class IntegrationTestFixture { + fixture = new Fixture(); + async initializeFixture() { + const [postgresContainer, postgresOptions] = await new postgres_container_1.PostgresContainer().start(); + this.fixture.postgresContainer = postgresContainer; + const [rabbitmqContainer, rabbitmqOptions] = await new rabbitmq_container_1.RabbitmqContainer().start(); + this.fixture.rabbitmqContainer = rabbitmqContainer; + const module = await testing_1.Test.createTestingModule({ + imports: [ + passport_1.PassportModule, + jwt_1.JwtModule.register({ + secret: configs_1.default.jwt.secret, + signOptions: { expiresIn: configs_1.default.jwt.refreshExpirationDays } + }), + open_telemetry_module_1.OpenTelemetryModule.forRoot(), + typeorm_1.TypeOrmModule.forRootAsync(postgresOptions), + user_module_1.UserModule, + auth_module_1.AuthModule, + core_1.RouterModule.register([ + { + path: '/', + module: user_module_1.UserModule + }, + { + path: '/', + module: auth_module_1.AuthModule + } + ]) + ], + providers: [jwt_strategy_1.JwtStrategy, cqrs_1.CommandBus, cqrs_1.QueryBus] + }) + .overrideGuard(jwt_guard_1.JwtGuard) + .useValue({ + canActivate: (context) => { + const req = context.switchToHttp().getRequest(); + req.user = { userId: 1, username: 'test_user' }; + return true; + } + }) + .compile(); + this.fixture.app = module.createNestApplication(); + this.fixture.app.setGlobalPrefix('api'); + this.fixture.app.enableVersioning({ + type: common_1.VersioningType.URI + }); + await this.fixture.app.init(); + this.fixture.userRepository = module.get('IUserRepository'); + this.fixture.authRepository = module.get('IAuthRepository'); + this.fixture.rabbitmqPublisher = module.get('IRabbitmqPublisher'); + this.fixture.rabbitmqConnection = module.get('IRabbitmqConnection'); + this.fixture.commandBus = module.get(cqrs_1.CommandBus); + this.fixture.queryBus = module.get(cqrs_1.QueryBus); + return this.fixture; + } + async cleanUp() { + await this.fixture.rabbitmqContainer.stop(); + await this.fixture.postgresContainer.stop(); + await this.fixture.app.close(); + } +} +exports.IntegrationTestFixture = IntegrationTestFixture; diff --git a/src/identity/test/shared/fixtures/integration-test.fixture.js.map b/src/identity/test/shared/fixtures/integration-test.fixture.js.map new file mode 100644 index 0000000..7e542fd --- /dev/null +++ b/src/identity/test/shared/fixtures/integration-test.fixture.js.map @@ -0,0 +1 @@ +{"version":3,"file":"integration-test.fixture.js","sourceRoot":"","sources":["integration-test.fixture.ts"],"names":[],"mappings":";;;;;;AACA,2CAAoF;AACpF,6CAAsD;AACtD,mGAA+F;AAC/F,mGAA+F;AAI/F,uCAAoD;AACpD,+CAAkD;AAClD,qCAAwC;AACxC,8EAAsD;AACtD,+FAA0F;AAC1F,6CAAgD;AAChD,+DAA2D;AAC3D,+DAA2D;AAC3D,uCAA4C;AAC5C,wEAAoE;AACpE,kEAA8D;AAI9D,MAAa,OAAO;IAClB,cAAc,CAAkB;IAChC,cAAc,CAAkB;IAChC,iBAAiB,CAAuB;IACxC,iBAAiB,CAAuB;IACxC,gBAAgB,CAAoB;IACpC,kBAAkB,CAAsB;IACxC,iBAAiB,CAAqB;IACtC,UAAU,CAAa;IACvB,QAAQ,CAAW;IACnB,GAAG,CAAmB;CACvB;AAXD,0BAWC;AAED,MAAa,sBAAsB;IACzB,OAAO,GAAY,IAAI,OAAO,EAAE,CAAC;IAElC,KAAK,CAAC,iBAAiB;QAC5B,MAAM,CAAC,iBAAiB,EAAE,eAAe,CAAC,GAAG,MAAM,IAAI,sCAAiB,EAAE,CAAC,KAAK,EAAE,CAAC;QACnF,IAAI,CAAC,OAAO,CAAC,iBAAiB,GAAG,iBAAiB,CAAC;QAEnD,MAAM,CAAC,iBAAiB,EAAE,eAAe,CAAC,GAAG,MAAM,IAAI,sCAAiB,EAAE,CAAC,KAAK,EAAE,CAAC;QACnF,IAAI,CAAC,OAAO,CAAC,iBAAiB,GAAG,iBAAiB,CAAC;QAEnD,MAAM,MAAM,GAAkB,MAAM,cAAI,CAAC,mBAAmB,CAAC;YAC3D,OAAO,EAAE;gBACP,yBAAc;gBACd,eAAS,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AG,CAAkB,iBAAiB,CAAC,CAAC;QAC7E,IAAI,CAAC,OAAO,CAAC,cAAc,GAAG,MAAM,CAAC,GAAG,CAAkB,iBAAiB,CAAC,CAAC;QAE7E,IAAI,CAAC,OAAO,CAAC,iBAAiB,GAAG,MAAM,CAAC,GAAG,CAAqB,oBAAoB,CAAC,CAAC;QACtF,IAAI,CAAC,OAAO,CAAC,kBAAkB,GAAG,MAAM,CAAC,GAAG,CAAsB,qBAAqB,CAAC,CAAC;QAEzF,IAAI,CAAC,OAAO,CAAC,UAAU,GAAG,MAAM,CAAC,GAAG,CAAa,iBAAU,CAAC,CAAC;QAC7D,IAAI,CAAC,OAAO,CAAC,QAAQ,GAAG,MAAM,CAAC,GAAG,CAAW,eAAQ,CAAC,CAAC;QAEvD,OAAO,IAAI,CAAC,OAAO,CAAC;IACtB,CAAC;IAEM,KAAK,CAAC,OAAO;QAClB,MAAM,IAAI,CAAC,OAAO,CAAC,iBAAiB,CAAC,IAAI,EAAE,CAAC;QAC5C,MAAM,IAAI,CAAC,OAAO,CAAC,iBAAiB,CAAC,IAAI,EAAE,CAAC;QAE5C,MAAM,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,KAAK,EAAE,CAAC;IACjC,CAAC;CACF;AAxED,wDAwEC"} \ No newline at end of file diff --git a/src/identity/test/shared/fixtures/integration-test.fixture.ts b/src/identity/test/shared/fixtures/integration-test.fixture.ts index 67cdbbc..bd92381 100644 --- a/src/identity/test/shared/fixtures/integration-test.fixture.ts +++ b/src/identity/test/shared/fixtures/integration-test.fixture.ts @@ -1,24 +1,24 @@ -import {IUserRepository} from "../../../src/data/repositories/user.repository"; -import {ExecutionContext, INestApplication, VersioningType} from "@nestjs/common"; -import {Test, TestingModule} from "@nestjs/testing"; -import {PostgresContainer} from "building-blocks/test/container/postgres/postgres-container"; -import {RabbitmqContainer} from "building-blocks/test/container/rabbitmq/rabbitmq-container"; -import {IAuthRepository} from "../../../src/data/repositories/auth.repository"; -import {IRabbitmqConsumer} from "building-blocks/rabbitmq/rabbitmq-subscriber"; -import {IRabbitmqPublisher} from "building-blocks/rabbitmq/rabbitmq-publisher"; -import {CommandBus, QueryBus} from "@nestjs/cqrs"; -import {PassportModule} from "@nestjs/passport"; -import {JwtModule} from "@nestjs/jwt"; -import configs from "building-blocks/configs/configs"; -import {OpenTelemetryModule} from "building-blocks/openTelemetry/open-telemetry.module"; -import {TypeOrmModule} from "@nestjs/typeorm"; -import {UserModule} from "../../../src/user/user.module"; -import {AuthModule} from "../../../src/auth/auth.module"; -import {RouterModule} from "@nestjs/core"; -import {JwtStrategy} from "building-blocks/passport/jwt.strategy"; -import {JwtGuard} from "building-blocks/passport/jwt.guard"; -import {IRabbitmqConnection} from "building-blocks/rabbitmq/rabbitmq-connection"; -import {StartedTestContainer} from "testcontainers"; +import { IUserRepository } from '../../../src/data/repositories/user.repository'; +import { ExecutionContext, INestApplication, VersioningType } from '@nestjs/common'; +import { Test, TestingModule } from '@nestjs/testing'; +import { PostgresContainer } from 'building-blocks/test/container/postgres/postgres-container'; +import { RabbitmqContainer } from 'building-blocks/test/container/rabbitmq/rabbitmq-container'; +import { IAuthRepository } from '../../../src/data/repositories/auth.repository'; +import { IRabbitmqConsumer } from 'building-blocks/rabbitmq/rabbitmq-subscriber'; +import { IRabbitmqPublisher } from 'building-blocks/rabbitmq/rabbitmq-publisher'; +import { CommandBus, QueryBus } from '@nestjs/cqrs'; +import { PassportModule } from '@nestjs/passport'; +import { JwtModule } from '@nestjs/jwt'; +import configs from 'building-blocks/configs/configs'; +import { OpenTelemetryModule } from 'building-blocks/openTelemetry/open-telemetry.module'; +import { TypeOrmModule } from '@nestjs/typeorm'; +import { UserModule } from '../../../src/user/user.module'; +import { AuthModule } from '../../../src/auth/auth.module'; +import { RouterModule } from '@nestjs/core'; +import { JwtStrategy } from 'building-blocks/passport/jwt.strategy'; +import { JwtGuard } from 'building-blocks/passport/jwt.guard'; +import { IRabbitmqConnection } from 'building-blocks/rabbitmq/rabbitmq-connection'; +import { StartedTestContainer } from 'testcontainers'; export class Fixture { userRepository: IUserRepository; @@ -37,7 +37,6 @@ export class IntegrationTestFixture { private fixture: Fixture = new Fixture(); public async initializeFixture(): Promise { - const [postgresContainer, postgresOptions] = await new PostgresContainer().start(); this.fixture.postgresContainer = postgresContainer; @@ -49,40 +48,41 @@ export class IntegrationTestFixture { PassportModule, JwtModule.register({ secret: configs.jwt.secret, - signOptions: {expiresIn: configs.jwt.refreshExpirationDays}, + signOptions: { expiresIn: configs.jwt.refreshExpirationDays } }), OpenTelemetryModule.forRoot(), - TypeOrmModule.forRoot(postgresOptions), + TypeOrmModule.forRootAsync(postgresOptions), UserModule, AuthModule, RouterModule.register([ { path: '/', - module: UserModule, + module: UserModule }, { path: '/', - module: AuthModule, - }, - ]), + module: AuthModule + } + ]) ], - providers: [JwtStrategy, CommandBus, QueryBus], - }).overrideGuard(JwtGuard) - .useValue({ - canActivate: (context: ExecutionContext) => { - const req = context.switchToHttp().getRequest(); - req.user = { userId: 1, username: 'test_user' }; - return true; - }, - }) - .compile() + providers: [JwtStrategy, CommandBus, QueryBus] + }) + .overrideGuard(JwtGuard) + .useValue({ + canActivate: (context: ExecutionContext) => { + const req = context.switchToHttp().getRequest(); + req.user = { userId: 1, username: 'test_user' }; + return true; + } + }) + .compile(); this.fixture.app = module.createNestApplication(); this.fixture.app.setGlobalPrefix('api'); this.fixture.app.enableVersioning({ - type: VersioningType.URI, + type: VersioningType.URI }); await this.fixture.app.init(); @@ -100,7 +100,6 @@ export class IntegrationTestFixture { } public async cleanUp() { - await this.fixture.rabbitmqContainer.stop(); await this.fixture.postgresContainer.stop(); diff --git a/src/identity/test/unit-test/user/features/create-user.test.d.ts b/src/identity/test/unit-test/user/features/create-user.test.d.ts new file mode 100644 index 0000000..cb0ff5c --- /dev/null +++ b/src/identity/test/unit-test/user/features/create-user.test.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/src/identity/test/unit-test/user/features/create-user.test.js b/src/identity/test/unit-test/user/features/create-user.test.js new file mode 100644 index 0000000..9ddc2ff --- /dev/null +++ b/src/identity/test/unit-test/user/features/create-user.test.js @@ -0,0 +1,68 @@ +"use strict"; +var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + var desc = Object.getOwnPropertyDescriptor(m, k); + if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { + desc = { enumerable: true, get: function() { return m[k]; } }; + } + Object.defineProperty(o, k2, desc); +}) : (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + o[k2] = m[k]; +})); +var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) { + Object.defineProperty(o, "default", { enumerable: true, value: v }); +}) : function(o, v) { + o["default"] = v; +}); +var __importStar = (this && this.__importStar) || (function () { + var ownKeys = function(o) { + ownKeys = Object.getOwnPropertyNames || function (o) { + var ar = []; + for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k; + return ar; + }; + return ownKeys(o); + }; + return function (mod) { + if (mod && mod.__esModule) return mod; + var result = {}; + if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]); + __setModuleDefault(result, mod); + return result; + }; +})(); +Object.defineProperty(exports, "__esModule", { value: true }); +const identity_contract_1 = require("building-blocks/contracts/identity.contract"); +const faker_1 = require("@faker-js/faker"); +const TypeMoq = __importStar(require("typemoq")); +const fake_user_entity_1 = require("../../../shared/fakes/user/fake-user.entity"); +const user_entity_1 = require("../../../../src/user/entities/user.entity"); +const fake_create_user_1 = require("../../../shared/fakes/user/fake-create-user"); +const create_user_1 = require("../../../../src/user/features/v1/create-user/create-user"); +describe('unit test for create user', () => { + let createUserHandler; + const fakeUser = fake_user_entity_1.FakeUser.generate(); + const mockUserRepository = TypeMoq.Mock.ofType(); + const mockPublisher = TypeMoq.Mock.ofType(); + beforeEach(() => { + createUserHandler = new create_user_1.CreateUserHandler(mockPublisher.object, mockUserRepository.object); + }); + it('should create a user and retrieve a valid data', async () => { + const email = faker_1.faker.internet.email(); + mockUserRepository + .setup((x) => x.findUserByEmail(TypeMoq.It.isAnyString())) + .returns(() => null); + mockUserRepository + .setup((x) => x.createUser(TypeMoq.It.isAnyObject(user_entity_1.User))) + .returns(() => Promise.resolve(fakeUser)); + mockPublisher + .setup((x) => x.publishMessage(TypeMoq.It.isAnyObject(identity_contract_1.UserCreated))) + .returns(() => Promise.resolve()); + const result = await createUserHandler.execute(fake_create_user_1.FakeCreateUser.generate(fakeUser)); + mockUserRepository.verify((x) => x.findUserByEmail(TypeMoq.It.isAnyString()), TypeMoq.Times.once()); + mockPublisher.verify((x) => x.publishMessage(TypeMoq.It.isAnyObject(identity_contract_1.UserCreated)), TypeMoq.Times.once()); + mockUserRepository.verify((x) => x.createUser(TypeMoq.It.isAnyObject(user_entity_1.User)), TypeMoq.Times.once()); + expect(result).not.toBeNull(); + }); +}); diff --git a/src/identity/test/unit-test/user/features/create-user.test.js.map b/src/identity/test/unit-test/user/features/create-user.test.js.map new file mode 100644 index 0000000..2e6f8bb --- /dev/null +++ b/src/identity/test/unit-test/user/features/create-user.test.js.map @@ -0,0 +1 @@ +{"version":3,"file":"create-user.test.js","sourceRoot":"","sources":["create-user.test.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,mFAA0E;AAC1E,2CAAwC;AACxC,iDAAmC;AACnC,kFAAuE;AACvE,2EAAiE;AAGjE,kFAA6E;AAE7E,0FAA6F;AAE7F,QAAQ,CAAC,2BAA2B,EAAE,GAAG,EAAE;IACzC,IAAI,iBAAoC,CAAC;IAEzC,MAAM,QAAQ,GAAS,2BAAQ,CAAC,QAAQ,EAAE,CAAC;IAE3C,MAAM,kBAAkB,GAAmC,OAAO,CAAC,IAAI,CAAC,MAAM,EAAmB,CAAC;IAClG,MAAM,aAAa,GACjB,OAAO,CAAC,IAAI,CAAC,MAAM,EAAsB,CAAC;IAE5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C,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,cAAc,CAAC,OAAO,CAAC,EAAE,CAAC,WAAW,CAAC,+BAAW,CAAC,CAAC,EAC5D,OAAO,CAAC,KAAK,CAAC,IAAI,EAAE,CACrB,CAAC;QAEF,kBAAkB,CAAC,MAAM,CACvB,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,UAAU,CAAC,OAAO,CAAC,EAAE,CAAC,WAAW,CAAC,kBAAI,CAAC,CAAC,EACjD,OAAO,CAAC,KAAK,CAAC,IAAI,EAAE,CACrB,CAAC;QACF,MAAM,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC,QAAQ,EAAE,CAAC;IAChC,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"} \ No newline at end of file diff --git a/src/identity/test/unit-test/user/features/create-user.test.ts b/src/identity/test/unit-test/user/features/create-user.test.ts index 9020a55..99ed140 100644 --- a/src/identity/test/unit-test/user/features/create-user.test.ts +++ b/src/identity/test/unit-test/user/features/create-user.test.ts @@ -1,13 +1,13 @@ import { UserCreated } from 'building-blocks/contracts/identity.contract'; import { faker } from '@faker-js/faker'; import * as TypeMoq from 'typemoq'; -import {FakeUser} from "../../../shared/fakes/user/fake-user.entity"; -import {User} from "../../../../src/user/entities/user.entity"; -import {IUserRepository} from "../../../../src/data/repositories/user.repository"; -import {UserDto} from "../../../../src/user/dtos/user.dto"; -import {FakeCreateUser} from "../../../shared/fakes/user/fake-create-user"; -import {IRabbitmqPublisher} from "building-blocks/rabbitmq/rabbitmq-publisher"; -import {CreateUserHandler} from "../../../../src/user/features/v1/create-user/create-user"; +import { FakeUser } from '../../../shared/fakes/user/fake-user.entity'; +import { User } from '../../../../src/user/entities/user.entity'; +import { IUserRepository } from '../../../../src/data/repositories/user.repository'; +import { UserDto } from '../../../../src/user/dtos/user.dto'; +import { FakeCreateUser } from '../../../shared/fakes/user/fake-create-user'; +import { IRabbitmqPublisher } from 'building-blocks/rabbitmq/rabbitmq-publisher'; +import { CreateUserHandler } from '../../../../src/user/features/v1/create-user/create-user'; describe('unit test for create user', () => { let createUserHandler: CreateUserHandler; @@ -15,7 +15,8 @@ describe('unit test for create user', () => { const fakeUser: User = FakeUser.generate(); const mockUserRepository: TypeMoq.IMock = TypeMoq.Mock.ofType(); - const mockPublisher: TypeMoq.IMock = TypeMoq.Mock.ofType(); + const mockPublisher: TypeMoq.IMock = + TypeMoq.Mock.ofType(); beforeEach(() => { createUserHandler = new CreateUserHandler(mockPublisher.object, mockUserRepository.object); diff --git a/src/identity/tsconfig.json b/src/identity/tsconfig.json index a9f66b1..cff40bc 100644 --- a/src/identity/tsconfig.json +++ b/src/identity/tsconfig.json @@ -1,16 +1,32 @@ { "compilerOptions": { - "module": "commonjs", - "declaration": true, - "removeComments": true, - "emitDecoratorMetadata": true, - "experimentalDecorators": true, - "allowSyntheticDefaultImports": true, - "target": "es2017", - "sourceMap": true, - "outDir": "./dist", - "baseUrl": "./", - "incremental": true, - "esModuleInterop": true + // Language and Environment + "target": "es2022", // Modern JavaScript features + "module": "commonjs", // Module system for Node.js + "lib": ["es2022"], // Include all ES2022 features + + // Modules and Output + "moduleResolution": "node", // Use Node.js module resolution + "baseUrl": "./", // Base directory for paths + "outDir": "./dist", // Output directory + "removeComments": true, // Remove comments in output + + // Decorators (needed for NestJS) + "experimentalDecorators": true, // Enable decorators + "emitDecoratorMetadata": true, // Emit decorator metadata + + // Type Checking + "strict": false, // Enable all strict type checking + "skipLibCheck": true, // Skip type checking of declaration files + "forceConsistentCasingInFileNames": true, // Ensure consistent casing in imports + + // Interop Constraints + "esModuleInterop": true, // Enable ES Module interop + "allowSyntheticDefaultImports": true, // Allow default imports from modules + + // Advanced + "incremental": true, // Enable incremental compilation + "preserveConstEnums": true, // Keep const enums in output + "resolveJsonModule": true // Allow importing JSON files } -} +} \ No newline at end of file diff --git a/src/passenger/.eslintrc.js b/src/passenger/.eslintrc.js deleted file mode 100644 index b88d1be..0000000 --- a/src/passenger/.eslintrc.js +++ /dev/null @@ -1,25 +0,0 @@ -module.exports = { - parser: '@typescript-eslint/parser', - parserOptions: { - project: 'tsconfig.json', - sourceType: 'module', - }, - plugins: ['@typescript-eslint/eslint-plugin'], - extends: [ - 'plugin:@typescript-eslint/recommended', - 'plugin:prettier/recommended', - ], - root: true, - env: { - node: true, - jest: true, - }, - ignorePatterns: ['.eslintrc.js'], - rules: { - '@typescript-eslint/interface-name-prefix': 'off', - '@typescript-eslint/explicit-function-return-type': 'off', - '@typescript-eslint/explicit-module-boundary-types': 'off', - '@typescript-eslint/no-explicit-any': 'off', - "@typescript-eslint/no-var-requires": "off" - }, -}; diff --git a/src/passenger/.prettierignore b/src/passenger/.prettierignore new file mode 100644 index 0000000..a7db0d7 --- /dev/null +++ b/src/passenger/.prettierignore @@ -0,0 +1,3 @@ +node_modules/ +dist/ +build/ \ No newline at end of file diff --git a/src/passenger/.prettierrc b/src/passenger/.prettierrc index f4f39af..c6f2a11 100644 --- a/src/passenger/.prettierrc +++ b/src/passenger/.prettierrc @@ -1,5 +1,7 @@ { - "singleQuote": true, - "trailingComma": "all", - "tabWidth": 4 -} + "semi": true, + "tabWidth": 2, + "printWidth": 100, + "singleQuote": true, + "trailingComma": "none" +} \ No newline at end of file diff --git a/src/passenger/eslint.config.js b/src/passenger/eslint.config.js new file mode 100644 index 0000000..70f0b27 --- /dev/null +++ b/src/passenger/eslint.config.js @@ -0,0 +1,12 @@ +// https://denar90.github.io/eslint.github.io/docs/rules/ +export default [ + { + rules: { + semi: "error", + "prefer-const": "warn", + "no-unused-vars": "warn", + "no-debugger": "warn", + "no-console": "warn" + } + } +]; diff --git a/src/passenger/nest-cli.json b/src/passenger/nest-cli.json index 2e1000f..ad0aa2c 100644 --- a/src/passenger/nest-cli.json +++ b/src/passenger/nest-cli.json @@ -1,7 +1,8 @@ { "collection": "@nestjs/schematics", - "sourceRoot": "src", + "sourceRoot": "passenger/src", + "entryFile": "main", "compilerOptions": { "plugins": ["@nestjs/swagger/plugin"] } -} +} \ No newline at end of file diff --git a/src/passenger/package.json b/src/passenger/package.json index 627b8ea..734f816 100644 --- a/src/passenger/package.json +++ b/src/passenger/package.json @@ -3,13 +3,13 @@ "description": "passenger service", "version": "1.0.0", "main": "src/main.ts", - "author": "Meysam Hadeli", + "author": "Meysam", "license": "MIT", "scripts": { "build": "nest build", - "dev": "tsc -p tsconfig.json && nodemon src/main.ts --watch", - "format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"", - "lint": "eslint \"{src,apps,libs,test}/**/*.ts\" --fix", + "dev": "nest start --watch", + "format": "prettier --write \"**/*.{ts,js}\"", + "lint": "eslint . --fix", "typeorm": "npm run build && npx typeorm -d ./dist/data/data-source.js", "migration:generate": "npm run typeorm -- migration:generate", "migration:run": "npm run typeorm -- migration:run", @@ -17,39 +17,41 @@ "test": "jest" }, "dependencies": { - "@nestjs/cli": "10.2.1", - "@nestjs/config": "^3.1.1", - "@nestjs/core": "10.2.10", - "@nestjs/cqrs": "^10.2.6", + "@nestjs/cli": "10.4.9", + "@nestjs/config": "^3.3.0", + "@nestjs/core": "10.4.15", + "@nestjs/cqrs": "^10.2.8", "@nestjs/jwt": "^10.2.0", - "@nestjs/mapped-types": "2.0.4", - "@nestjs/microservices": "^10.2.10", - "@nestjs/passport": "^10.0.2", - "@nestjs/platform-express": "^10.2.10", - "@nestjs/schematics": "10.0.3", - "@nestjs/swagger": "^7.1.16", - "@nestjs/terminus": "^10.1.1", - "@nestjs/testing": "10.2.10", - "@nestjs/typeorm": "^10.0.1", + "@nestjs/mapped-types": "2.0.6", + "@nestjs/microservices": "^10.4.15", + "@nestjs/passport": "^10.0.3", + "@nestjs/platform-express": "^10.4.15", + "@nestjs/schematics": "10.2.3", + "@nestjs/swagger": "^8.1.0", + "@nestjs/terminus": "^10.2.3", + "@nestjs/testing": "10.4.15", + "@nestjs/typeorm": "^10.0.2", "building-blocks": "file:../building-blocks", "class-transformer": "^0.5.1", - "class-validator": "^0.14.0", - "joi": "^17.10.1", - "moment": "^2.29.4", - "nodemon": "^3.0.2", - "pg": "^8.11.3", - "testcontainers": "^10.3.2", + "class-validator": "^0.14.1", + "joi": "^17.13.3", + "moment": "^2.30.1", + "nodemon": "^3.1.9", + "pg": "^8.13.1", + "testcontainers": "^10.16.0", "ts-mapper": "^1.2.4" }, "devDependencies": { - "@faker-js/faker": "^8.3.1", - "@types/express": "^4.17.21", - "@types/jest": "29.5.10", - "@types/supertest": "2.0.16", + "@faker-js/faker": "^9.3.0", + "@types/express": "^5.0.0", + "@types/jest": "29.5.14", + "@types/supertest": "6.0.2", "jest": "29.7.0", "jest-serial-runner": "^1.2.1", - "supertest": "6.3.3", - "ts-jest": "29.1.1", - "typemoq": "^2.1.0" + "supertest": "7.0.0", + "ts-jest": "29.2.5", + "typemoq": "^2.1.0", + "prettier": "3.4.2", + "eslint": "9.17.0" } } diff --git a/src/passenger/src/app.module.ts b/src/passenger/src/app.module.ts index a3b3384..3160c44 100644 --- a/src/passenger/src/app.module.ts +++ b/src/passenger/src/app.module.ts @@ -1,21 +1,21 @@ -import {MiddlewareConsumer, Module, NestModule} from '@nestjs/common'; import { RouterModule } from '@nestjs/core'; import { TypeOrmModule } from '@nestjs/typeorm'; import { postgresOptions } from './data/data-source'; -import {PassportModule} from "@nestjs/passport"; -import {JwtModule} from "@nestjs/jwt"; -import configs from "building-blocks/configs/configs"; -import {OpenTelemetryModule} from "building-blocks/openTelemetry/open-telemetry.module"; -import {JwtStrategy} from "building-blocks/passport/jwt.strategy"; +import { PassportModule } from '@nestjs/passport'; +import { JwtModule } from '@nestjs/jwt'; +import { OpenTelemetryModule } from 'building-blocks/openTelemetry/open-telemetry.module'; +import { JwtStrategy } from 'building-blocks/passport/jwt.strategy'; +import configs from 'building-blocks/configs/configs'; +import { MiddlewareConsumer, Module, NestModule } from '@nestjs/common'; +import { HttpContextMiddleware } from 'building-blocks/context/context'; import {PassengerModule} from "./passenger/passenger.module"; -import {HttpContextMiddleware} from "building-blocks/context/context"; @Module({ imports: [ PassportModule, JwtModule.register({ secret: configs.jwt.secret, - signOptions: {expiresIn: configs.jwt.refreshExpirationDays}, + signOptions: { expiresIn: configs.jwt.refreshExpirationDays } }), OpenTelemetryModule.forRoot(), TypeOrmModule.forRoot(postgresOptions), @@ -23,16 +23,14 @@ import {HttpContextMiddleware} from "building-blocks/context/context"; RouterModule.register([ { path: '/', - module: PassengerModule, + module: PassengerModule } - ]), + ]) ], - providers: [JwtStrategy], + providers: [JwtStrategy] }) export class AppModule implements NestModule { configure(consumer: MiddlewareConsumer) { - consumer - .apply(HttpContextMiddleware) - .forRoutes('*'); + consumer.apply(HttpContextMiddleware).forRoutes('*'); } } diff --git a/src/passenger/src/passenger/passenger.module.ts b/src/passenger/src/passenger/passenger.module.ts index 0ab9555..2f7001e 100644 --- a/src/passenger/src/passenger/passenger.module.ts +++ b/src/passenger/src/passenger/passenger.module.ts @@ -9,7 +9,6 @@ import { GetPassengerByIdHandler } from "./features/v1/get-passenger-by-id/get-passenger-by-id"; import {GetPassengersController, GetPassengersHandler} from "./features/v1/get-passengers/get-passengers"; -import {OpenTelemetryTracer} from "building-blocks/openTelemetry/open-telemetry-tracer"; import {UserCreated} from "building-blocks/contracts/identity.contract"; import {CreateUserHandler} from "../user/consumers/create-user"; import {IRabbitmqConsumer} from "building-blocks/rabbitmq/rabbitmq-subscriber"; @@ -23,7 +22,6 @@ import {IRabbitmqConsumer} from "building-blocks/rabbitmq/rabbitmq-subscriber"; provide: 'IPassengerRepository', useClass: PassengerRepository, }, - OpenTelemetryTracer ], exports: [], }) diff --git a/src/passenger/tsconfig.json b/src/passenger/tsconfig.json index a9f66b1..cff40bc 100644 --- a/src/passenger/tsconfig.json +++ b/src/passenger/tsconfig.json @@ -1,16 +1,32 @@ { "compilerOptions": { - "module": "commonjs", - "declaration": true, - "removeComments": true, - "emitDecoratorMetadata": true, - "experimentalDecorators": true, - "allowSyntheticDefaultImports": true, - "target": "es2017", - "sourceMap": true, - "outDir": "./dist", - "baseUrl": "./", - "incremental": true, - "esModuleInterop": true + // Language and Environment + "target": "es2022", // Modern JavaScript features + "module": "commonjs", // Module system for Node.js + "lib": ["es2022"], // Include all ES2022 features + + // Modules and Output + "moduleResolution": "node", // Use Node.js module resolution + "baseUrl": "./", // Base directory for paths + "outDir": "./dist", // Output directory + "removeComments": true, // Remove comments in output + + // Decorators (needed for NestJS) + "experimentalDecorators": true, // Enable decorators + "emitDecoratorMetadata": true, // Emit decorator metadata + + // Type Checking + "strict": false, // Enable all strict type checking + "skipLibCheck": true, // Skip type checking of declaration files + "forceConsistentCasingInFileNames": true, // Ensure consistent casing in imports + + // Interop Constraints + "esModuleInterop": true, // Enable ES Module interop + "allowSyntheticDefaultImports": true, // Allow default imports from modules + + // Advanced + "incremental": true, // Enable incremental compilation + "preserveConstEnums": true, // Keep const enums in output + "resolveJsonModule": true // Allow importing JSON files } -} +} \ No newline at end of file From d9584e6335bfb12fae804aaec1533673264d83f7 Mon Sep 17 00:00:00 2001 From: Meysam Hadeli <35596795+meysamhadeli@users.noreply.github.com> Date: Thu, 26 Dec 2024 00:49:55 +0330 Subject: [PATCH 2/3] feat: update ci package versions --- .github/workflows/ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8a4f3bb..a5e22a9 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,12 +14,12 @@ jobs: ci: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Set up Node.js - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: - node-version: '20.x' + node-version: '22.x' - name: build building-blocks run: | From 780b2f822718e9afafc6ab411b90568926c07c79 Mon Sep 17 00:00:00 2001 From: Meysam Hadeli <35596795+meysamhadeli@users.noreply.github.com> Date: Thu, 26 Dec 2024 03:00:41 +0330 Subject: [PATCH 3/3] fix: fixing test issue --- .../docker-compose/infrastructure.yaml | 2 +- src/building-blocks/context/context.js | 3 + src/building-blocks/context/context.js.map | 2 +- .../contracts/booking.contract.js | 12 ++ .../contracts/booking.contract.js.map | 2 +- .../contracts/flight.contract.js | 64 ++++++ .../contracts/flight.contract.js.map | 2 +- .../contracts/identity.contract.js | 24 +++ .../contracts/identity.contract.js.map | 2 +- .../contracts/passenger.contract.js | 7 + .../contracts/passenger.contract.js.map | 2 +- .../monitoring/request-counter.middleware.js | 10 +- .../request-counter.middleware.js.map | 2 +- src/building-blocks/nest-cli.json | 2 +- .../openTelemetry/open-telemetry-tracer.js | 16 +- .../open-telemetry-tracer.js.map | 2 +- src/building-blocks/passport/jwt.guard.d.ts | 2 +- src/building-blocks/passport/jwt.guard.js | 1 + .../rabbitmq/rabbitmq-connection.js | 15 +- .../rabbitmq/rabbitmq-connection.js.map | 2 +- .../rabbitmq/rabbitmq-publisher.js | 2 + .../rabbitmq/rabbitmq-publisher.js.map | 2 +- .../rabbitmq/rabbitmq-subscriber.js | 5 +- .../rabbitmq/rabbitmq-subscriber.js.map | 2 +- .../rabbitmq/rabbitmq.module.js | 1 + .../rabbitmq/rabbitmq.module.js.map | 2 +- .../postgres/postgres-container.d.ts | 2 +- .../container/postgres/postgres-container.js | 9 +- .../postgres/postgres-container.js.map | 2 +- .../container/postgres/postgres-container.ts | 15 +- .../container/rabbitmq/rabbitmq-container.js | 17 +- .../rabbitmq/rabbitmq-container.js.map | 2 +- .../container/rabbitmq/rabbitmq-container.ts | 2 +- src/building-blocks/tsconfig.json | 10 +- .../types/exeptions/application.exception.js | 2 + .../exeptions/application.exception.js.map | 2 +- .../types/exeptions/http-client.exception.js | 2 + .../exeptions/http-client.exception.js.map | 2 +- .../types/pagination/paged-result.js | 2 + .../types/pagination/paged-result.js.map | 2 +- src/building-blocks/utils/encryption.js.map | 2 +- .../user/features/create-user.test.d.ts | 1 - .../user/features/create-user.test.js | 23 -- .../user/features/create-user.test.js.map | 1 - .../user/features/create-user.test.d.ts | 1 - .../user/features/create-user.test.js | 23 -- .../user/features/create-user.test.js.map | 1 - .../user/features/create-user.test.ts | 8 +- .../shared/fixtures/end-to-end.fixture.d.ts | 3 - .../shared/fixtures/end-to-end.fixture.js | 8 - .../shared/fixtures/end-to-end.fixture.js.map | 1 - .../fixtures/integration-test.fixture.d.ts | 25 --- .../fixtures/integration-test.fixture.js | 95 -------- .../fixtures/integration-test.fixture.js.map | 1 - .../fixtures/integration-test.fixture.ts | 204 +++++++++--------- 55 files changed, 308 insertions(+), 348 deletions(-) delete mode 100644 src/identity/test/end-to-end-test/user/features/create-user.test.d.ts delete mode 100644 src/identity/test/end-to-end-test/user/features/create-user.test.js delete mode 100644 src/identity/test/end-to-end-test/user/features/create-user.test.js.map delete mode 100644 src/identity/test/integration-test/user/features/create-user.test.d.ts delete mode 100644 src/identity/test/integration-test/user/features/create-user.test.js delete mode 100644 src/identity/test/integration-test/user/features/create-user.test.js.map delete mode 100644 src/identity/test/shared/fixtures/end-to-end.fixture.d.ts delete mode 100644 src/identity/test/shared/fixtures/end-to-end.fixture.js delete mode 100644 src/identity/test/shared/fixtures/end-to-end.fixture.js.map delete mode 100644 src/identity/test/shared/fixtures/integration-test.fixture.d.ts delete mode 100644 src/identity/test/shared/fixtures/integration-test.fixture.js delete mode 100644 src/identity/test/shared/fixtures/integration-test.fixture.js.map diff --git a/deployments/docker-compose/infrastructure.yaml b/deployments/docker-compose/infrastructure.yaml index cc3eed2..bee76d4 100644 --- a/deployments/docker-compose/infrastructure.yaml +++ b/deployments/docker-compose/infrastructure.yaml @@ -5,7 +5,7 @@ services: # Rabbitmq ####################################################### rabbitmq: - image: rabbitmq:3-management + image: rabbitmq:management container_name: rabbitmq restart: unless-stopped ports: diff --git a/src/building-blocks/context/context.js b/src/building-blocks/context/context.js index 6149fd6..7cd3341 100644 --- a/src/building-blocks/context/context.js +++ b/src/building-blocks/context/context.js @@ -2,6 +2,9 @@ Object.defineProperty(exports, "__esModule", { value: true }); exports.HttpContextMiddleware = exports.HttpContext = void 0; class HttpContext { + static request; + static response; + static headers; } exports.HttpContext = HttpContext; class HttpContextMiddleware { diff --git a/src/building-blocks/context/context.js.map b/src/building-blocks/context/context.js.map index 62223e0..51a2878 100644 --- a/src/building-blocks/context/context.js.map +++ b/src/building-blocks/context/context.js.map @@ -1 +1 @@ -{"version":3,"file":"context.js","sourceRoot":"","sources":["context.ts"],"names":[],"mappings":";;;AAIA,MAAa,WAAW;CAIvB;AAJD,kCAIC;AAED,MAAa,qBAAqB;IAChC,GAAG,CAAC,GAAY,EAAE,GAAa,EAAE,IAAkB;QACjD,WAAW,CAAC,OAAO,GAAG,GAAG,CAAC;QAE1B,WAAW,CAAC,QAAQ,GAAG,GAAG,CAAC;QAE3B,WAAW,CAAC,OAAO,GAAG,GAAG,CAAC,OAAO,CAAC;QAElC,IAAI,EAAE,CAAC;IACT,CAAC;CACF;AAVD,sDAUC"} \ No newline at end of file +{"version":3,"file":"context.js","sourceRoot":"","sources":["context.ts"],"names":[],"mappings":";;;AAIA,MAAa,WAAW;IACtB,MAAM,CAAC,OAAO,CAAU;IACxB,MAAM,CAAC,QAAQ,CAAW;IAC1B,MAAM,CAAC,OAAO,CAAsB;CACrC;AAJD,kCAIC;AAED,MAAa,qBAAqB;IAChC,GAAG,CAAC,GAAY,EAAE,GAAa,EAAE,IAAkB;QACjD,WAAW,CAAC,OAAO,GAAG,GAAG,CAAC;QAE1B,WAAW,CAAC,QAAQ,GAAG,GAAG,CAAC;QAE3B,WAAW,CAAC,OAAO,GAAG,GAAG,CAAC,OAAO,CAAC;QAElC,IAAI,EAAE,CAAC;IACT,CAAC;CACF;AAVD,sDAUC"} \ No newline at end of file diff --git a/src/building-blocks/contracts/booking.contract.js b/src/building-blocks/contracts/booking.contract.js index 34e4ee5..b3fc080 100644 --- a/src/building-blocks/contracts/booking.contract.js +++ b/src/building-blocks/contracts/booking.contract.js @@ -2,6 +2,18 @@ Object.defineProperty(exports, "__esModule", { value: true }); exports.BookingCreated = void 0; class BookingCreated { + id; + flightNumber; + aircraftId; + departureAirportId; + arriveAirportId; + flightDate; + price; + description; + seatNumber; + passengerName; + createdAt; + updatedAt; constructor(partial) { Object.assign(this, partial); } diff --git a/src/building-blocks/contracts/booking.contract.js.map b/src/building-blocks/contracts/booking.contract.js.map index 516bc8a..12d7b96 100644 --- a/src/building-blocks/contracts/booking.contract.js.map +++ b/src/building-blocks/contracts/booking.contract.js.map @@ -1 +1 @@ -{"version":3,"file":"booking.contract.js","sourceRoot":"","sources":["booking.contract.ts"],"names":[],"mappings":";;;AAEA,MAAa,cAAc;IAczB,YAAY,OAAiC;QAC3C,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AAjBD,wCAiBC"} \ No newline at end of file +{"version":3,"file":"booking.contract.js","sourceRoot":"","sources":["booking.contract.ts"],"names":[],"mappings":";;;AAEA,MAAa,cAAc;IACzB,EAAE,CAAS;IACX,YAAY,CAAS;IACrB,UAAU,CAAS;IACnB,kBAAkB,CAAS;IAC3B,eAAe,CAAS;IACxB,UAAU,CAAO;IACjB,KAAK,CAAS;IACd,WAAW,CAAS;IACpB,UAAU,CAAS;IACnB,aAAa,CAAS;IACtB,SAAS,CAAO;IAChB,SAAS,CAAe;IAExB,YAAY,OAAiC;QAC3C,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AAjBD,wCAiBC"} \ No newline at end of file diff --git a/src/building-blocks/contracts/flight.contract.js b/src/building-blocks/contracts/flight.contract.js index fe9bc5d..ff79c36 100644 --- a/src/building-blocks/contracts/flight.contract.js +++ b/src/building-blocks/contracts/flight.contract.js @@ -2,48 +2,112 @@ Object.defineProperty(exports, "__esModule", { value: true }); exports.SeatType = exports.SeatClass = exports.FlightStatus = exports.ReserveSeatRequestDto = exports.SeatDto = exports.FlightDto = exports.SeatReserved = exports.SeatCreated = exports.AirportCreated = exports.AircraftCreated = exports.FlightCreated = void 0; class FlightCreated { + id; + flightNumber; + price; + flightStatus; + flightDate; + departureDate; + departureAirportId; + aircraftId; + arriveDate; + arriveAirportId; + durationMinutes; + createdAt; + updatedAt; constructor(request = {}) { Object.assign(this, request); } } exports.FlightCreated = FlightCreated; class AircraftCreated { + id; + model; + name; + manufacturingYear; + createdAt; + updatedAt; constructor(request = {}) { Object.assign(this, request); } } exports.AircraftCreated = AircraftCreated; class AirportCreated { + id; + code; + name; + address; + createdAt; + updatedAt; constructor(request = {}) { Object.assign(this, request); } } exports.AirportCreated = AirportCreated; class SeatCreated { + id; + seatNumber; + seatClass; + seatType; + flightId; + isReserved; + createdAt; + updatedAt; constructor(request = {}) { Object.assign(this, request); } } exports.SeatCreated = SeatCreated; class SeatReserved { + id; + seatNumber; + seatClass; + seatType; + flightId; + isReserved; + createdAt; + updatedAt; constructor(request = {}) { Object.assign(this, request); } } exports.SeatReserved = SeatReserved; class FlightDto { + id; + flightNumber; + price; + flightStatus; + flightDate; + departureDate; + departureAirportId; + aircraftId; + arriveDate; + arriveAirportId; + durationMinutes; + createdAt; + updatedAt; constructor(request = {}) { Object.assign(this, request); } } exports.FlightDto = FlightDto; class SeatDto { + id; + seatNumber; + seatClass; + seatType; + flightId; + isReserved; + createdAt; + updatedAt; constructor(request = {}) { Object.assign(this, request); } } exports.SeatDto = SeatDto; class ReserveSeatRequestDto { + seatNumber; + flightId; constructor(request = {}) { Object.assign(this, request); } diff --git a/src/building-blocks/contracts/flight.contract.js.map b/src/building-blocks/contracts/flight.contract.js.map index acccfbd..4df0501 100644 --- a/src/building-blocks/contracts/flight.contract.js.map +++ b/src/building-blocks/contracts/flight.contract.js.map @@ -1 +1 @@ -{"version":3,"file":"flight.contract.js","sourceRoot":"","sources":["flight.contract.ts"],"names":[],"mappings":";;;AAEA,MAAa,aAAa;IAexB,YAAY,UAAkC,EAAE;QAC9C,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AAlBD,sCAkBC;AAED,MAAa,eAAe;IAQ1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AAT,SAAS,QAKpB;AAED,IAAY,QAKX;AALD,WAAY,QAAQ;IAClB,6CAAW,CAAA;IACX,2CAAM,CAAA;IACN,2CAAM,CAAA;IACN,yCAAK,CAAA;AACP,CAAC,EALW,QAAQ,wBAAR,QAAQ,QAKnB"} \ No newline at end of file +{"version":3,"file":"flight.contract.js","sourceRoot":"","sources":["flight.contract.ts"],"names":[],"mappings":";;;AAEA,MAAa,aAAa;IACxB,EAAE,CAAS;IACX,YAAY,CAAS;IACrB,KAAK,CAAS;IACd,YAAY,CAAe;IAC3B,UAAU,CAAO;IACjB,aAAa,CAAO;IACpB,kBAAkB,CAAS;IAC3B,UAAU,CAAS;IACnB,UAAU,CAAO;IACjB,eAAe,CAAS;IACxB,eAAe,CAAS;IACxB,SAAS,CAAO;IAChB,SAAS,CAAQ;IAEjB,YAAY,UAAkC,EAAE;QAC9C,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AAlBD,sCAkBC;AAED,MAAa,eAAe;IAC1B,EAAE,CAAS;IACX,KAAK,CAAS;IACd,IAAI,CAAS;IACb,iBAAiB,CAAS;IAC1B,SAAS,CAAO;IAChB,SAAS,CAAQ;IAEjB,YAAY,UAAoC,EAAE;QAChD,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AAXD,0CAWC;AAED,MAAa,cAAc;IACzB,EAAE,CAAS;IACX,IAAI,CAAS;IACb,IAAI,CAAS;IACb,OAAO,CAAS;IAChB,SAAS,CAAO;IAChB,SAAS,CAAQ;IAEjB,YAAY,UAAmC,EAAE;QAC/C,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AAXD,wCAWC;AAED,MAAa,WAAW;IACtB,EAAE,CAAS;IACX,UAAU,CAAS;IACnB,SAAS,CAAY;IACrB,QAAQ,CAAW;IACnB,QAAQ,CAAS;IACjB,UAA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AAO,CAAC,CAAC;IAC/B,CAAC;CACF;AAPD,sDAOC;AAED,IAAY,YAMX;AAND,WAAY,YAAY;IACtB,qDAAW,CAAA;IACX,mDAAU,CAAA;IACV,iDAAS,CAAA;IACT,uDAAY,CAAA;IACZ,yDAAa,CAAA;AACf,CAAC,EANW,YAAY,4BAAZ,YAAY,QAMvB;AAED,IAAY,SAKX;AALD,WAAY,SAAS;IACnB,+CAAW,CAAA;IACX,uDAAW,CAAA;IACX,iDAAQ,CAAA;IACR,+CAAO,CAAA;AACT,CAAC,EALW,SAAS,yBAAT,SAAS,QAKpB;AAED,IAAY,QAKX;AALD,WAAY,QAAQ;IAClB,6CAAW,CAAA;IACX,2CAAM,CAAA;IACN,2CAAM,CAAA;IACN,yCAAK,CAAA;AACP,CAAC,EALW,QAAQ,wBAAR,QAAQ,QAKnB"} \ No newline at end of file diff --git a/src/building-blocks/contracts/identity.contract.js b/src/building-blocks/contracts/identity.contract.js index a605b34..0dfcb4c 100644 --- a/src/building-blocks/contracts/identity.contract.js +++ b/src/building-blocks/contracts/identity.contract.js @@ -2,18 +2,42 @@ Object.defineProperty(exports, "__esModule", { value: true }); exports.Role = exports.UserUpdated = exports.UserDeleted = exports.UserCreated = void 0; class UserCreated { + id; + email; + name; + isEmailVerified; + role; + passportNumber; + createdAt; + updatedAt; constructor(partial) { Object.assign(this, partial); } } exports.UserCreated = UserCreated; class UserDeleted { + id; + email; + name; + isEmailVerified; + role; + passportNumber; + createdAt; + updatedAt; constructor(partial) { Object.assign(this, partial); } } exports.UserDeleted = UserDeleted; class UserUpdated { + id; + email; + name; + isEmailVerified; + role; + passportNumber; + createdAt; + updatedAt; constructor(partial) { Object.assign(this, partial); } diff --git a/src/building-blocks/contracts/identity.contract.js.map b/src/building-blocks/contracts/identity.contract.js.map index c2834d3..13def8f 100644 --- a/src/building-blocks/contracts/identity.contract.js.map +++ b/src/building-blocks/contracts/identity.contract.js.map @@ -1 +1 @@ -{"version":3,"file":"identity.contract.js","sourceRoot":"","sources":["identity.contract.ts"],"names":[],"mappings":";;;AAEA,MAAa,WAAW;IAUtB,YAAY,OAA8B;QACxC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AAbD,kCAaC;AAED,MAAa,WAAW;IAUtB,YAAY,OAA8B;QACxC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AAbD,kCAaC;AAED,MAAa,WAAW;IAUtB,YAAY,OAA8B;QACxC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AAbD,kCAaC;AAED,IAAY,IAGX;AAHD,WAAY,IAAI;IACd,+BAAQ,CAAA;IACR,iCAAS,CAAA;AACX,CAAC,EAHW,IAAI,oBAAJ,IAAI,QAGf"} \ No newline at end of file +{"version":3,"file":"identity.contract.js","sourceRoot":"","sources":["identity.contract.ts"],"names":[],"mappings":";;;AAEA,MAAa,WAAW;IACtB,EAAE,CAAS;IACX,KAAK,CAAS;IACd,IAAI,CAAS;IACb,eAAe,CAAU;IACzB,IAAI,CAAO;IACX,cAAc,CAAS;IACvB,SAAS,CAAO;IAChB,SAAS,CAAQ;IAEjB,YAAY,OAA8B;QACxC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AAbD,kCAaC;AAED,MAAa,WAAW;IACtB,EAAE,CAAS;IACX,KAAK,CAAS;IACd,IAAI,CAAS;IACb,eAAe,CAAU;IACzB,IAAI,CAAO;IACX,cAAc,CAAS;IACvB,SAAS,CAAO;IAChB,SAAS,CAAQ;IAEjB,YAAY,OAA8B;QACxC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AAbD,kCAaC;AAED,MAAa,WAAW;IACtB,EAAE,CAAS;IACX,KAAK,CAAS;IACd,IAAI,CAAS;IACb,eAAe,CAAU;IACzB,IAAI,CAAO;IACX,cAAc,CAAS;IACvB,SAAS,CAAO;IAChB,SAAS,CAAQ;IAEjB,YAAY,OAA8B;QACxC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AAbD,kCAaC;AAED,IAAY,IAGX;AAHD,WAAY,IAAI;IACd,+BAAQ,CAAA;IACR,iCAAS,CAAA;AACX,CAAC,EAHW,IAAI,oBAAJ,IAAI,QAGf"} \ No newline at end of file diff --git a/src/building-blocks/contracts/passenger.contract.js b/src/building-blocks/contracts/passenger.contract.js index 2f109a4..fa3f0ca 100644 --- a/src/building-blocks/contracts/passenger.contract.js +++ b/src/building-blocks/contracts/passenger.contract.js @@ -2,6 +2,13 @@ Object.defineProperty(exports, "__esModule", { value: true }); exports.PassengerType = exports.PassengerDto = void 0; class PassengerDto { + id; + name; + age; + passportNumber; + passportType; + createdAt; + updatedAt; constructor(partial) { Object.assign(this, partial); } diff --git a/src/building-blocks/contracts/passenger.contract.js.map b/src/building-blocks/contracts/passenger.contract.js.map index 7dfe0bf..f4c0987 100644 --- a/src/building-blocks/contracts/passenger.contract.js.map +++ b/src/building-blocks/contracts/passenger.contract.js.map @@ -1 +1 @@ -{"version":3,"file":"passenger.contract.js","sourceRoot":"","sources":["passenger.contract.ts"],"names":[],"mappings":";;;AAAA,MAAa,YAAY;IASvB,YAAY,OAA+B;QACzC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AAZD,oCAYC;AAED,IAAY,aAKX;AALD,WAAY,aAAa;IACvB,uDAAW,CAAA;IACX,iDAAI,CAAA;IACJ,qDAAM,CAAA;IACN,iDAAI,CAAA;AACN,CAAC,EALW,aAAa,6BAAb,aAAa,QAKxB"} \ No newline at end of file +{"version":3,"file":"passenger.contract.js","sourceRoot":"","sources":["passenger.contract.ts"],"names":[],"mappings":";;;AAAA,MAAa,YAAY;IACvB,EAAE,CAAS;IACX,IAAI,CAAS;IACb,GAAG,CAAS;IACZ,cAAc,CAAS;IACvB,YAAY,CAAgB;IAC5B,SAAS,CAAO;IAChB,SAAS,CAAQ;IAEjB,YAAY,OAA+B;QACzC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AAZD,oCAYC;AAED,IAAY,aAKX;AALD,WAAY,aAAa;IACvB,uDAAW,CAAA;IACX,iDAAI,CAAA;IACJ,qDAAM,CAAA;IACN,iDAAI,CAAA;AACN,CAAC,EALW,aAAa,6BAAb,aAAa,QAKxB"} \ No newline at end of file diff --git a/src/building-blocks/monitoring/request-counter.middleware.js b/src/building-blocks/monitoring/request-counter.middleware.js index d4eae5c..030fd66 100644 --- a/src/building-blocks/monitoring/request-counter.middleware.js +++ b/src/building-blocks/monitoring/request-counter.middleware.js @@ -50,9 +50,15 @@ const requestCounterMiddleware = (err, req, res, next) => { requestCounter.inc(labels); res.on('finish', () => { const status = res.statusCode.toString(); - requestCounter.inc(Object.assign(Object.assign({}, labels), { status })); + requestCounter.inc({ + ...labels, + status + }); if (status.startsWith('4') || status.startsWith('5')) { - errorCounter.inc(Object.assign(Object.assign({}, labels), { status })); + errorCounter.inc({ + ...labels, + status + }); } }); next(); diff --git a/src/building-blocks/monitoring/request-counter.middleware.js.map b/src/building-blocks/monitoring/request-counter.middleware.js.map index 2763a01..fb758db 100644 --- a/src/building-blocks/monitoring/request-counter.middleware.js.map +++ b/src/building-blocks/monitoring/request-counter.middleware.js.map @@ -1 +1 @@ -{"version":3,"file":"request-counter.middleware.js","sourceRoot":"","sources":["request-counter.middleware.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wDAA0C;AAE1C,MAAM,cAAc,GAAG,IAAI,UAAU,CAAC,OAAO,CAAC;IAC5C,IAAI,EAAE,qBAAqB;IAC3B,IAAI,EAAE,+BAA+B;IACrC,UAAU,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,CAAC;CACzC,CAAC,CAAC;AAEH,MAAM,YAAY,GAAG,IAAI,UAAU,CAAC,OAAO,CAAC;IAC1C,IAAI,EAAE,mBAAmB;IACzB,IAAI,EAAE,6BAA6B;IACnC,UAAU,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,CAAC;CACzC,CAAC,CAAC;AAEI,MAAM,wBAAwB,GAAG,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,IAAI,EAAE,EAAE;IAC9D,MAAM,MAAM,GAAG,EAAE,MAAM,EAAE,GAAG,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,CAAC,IAAI,EAAE,CAAC;IAEtD,cAAc,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IAE3B,GAAG,CAAC,EAAE,CAAC,QAAQ,EAAE,GAAG,EAAE;QACpB,MAAM,MAAM,GAAG,GAAG,CAAC,UAAU,CAAC,QAAQ,EAAE,CAAC;QAEzC,cAAc,CAAC,GAAG,iCACb,MAAM,KACT,MAAM,IACN,CAAC;QAGH,IAAI,MAAM,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,MAAM,CAAC,UAAU,CAAC,GAAG,CAAC,EAAE,CAAC;YACrD,YAAY,CAAC,GAAG,iCACX,MAAM,KACT,MAAM,IACN,CAAC;QACL,CAAC;IACH,CAAC,CAAC,CAAC;IAEH,IAAI,EAAE,CAAC;AACT,CAAC,CAAC;AAvBW,QAAA,wBAAwB,4BAuBnC"} \ No newline at end of file +{"version":3,"file":"request-counter.middleware.js","sourceRoot":"","sources":["request-counter.middleware.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wDAA0C;AAE1C,MAAM,cAAc,GAAG,IAAI,UAAU,CAAC,OAAO,CAAC;IAC5C,IAAI,EAAE,qBAAqB;IAC3B,IAAI,EAAE,+BAA+B;IACrC,UAAU,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,CAAC;CACzC,CAAC,CAAC;AAEH,MAAM,YAAY,GAAG,IAAI,UAAU,CAAC,OAAO,CAAC;IAC1C,IAAI,EAAE,mBAAmB;IACzB,IAAI,EAAE,6BAA6B;IACnC,UAAU,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,CAAC;CACzC,CAAC,CAAC;AAEI,MAAM,wBAAwB,GAAG,CAAC,GAAQ,EAAE,GAAQ,EAAE,GAAQ,EAAE,IAAS,EAAE,EAAE;IAClF,MAAM,MAAM,GAAG,EAAE,MAAM,EAAE,GAAG,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,CAAC,IAAI,EAAE,CAAC;IAEtD,cAAc,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IAE3B,GAAG,CAAC,EAAE,CAAC,QAAQ,EAAE,GAAG,EAAE;QACpB,MAAM,MAAM,GAAG,GAAG,CAAC,UAAU,CAAC,QAAQ,EAAE,CAAC;QAEzC,cAAc,CAAC,GAAG,CAAC;YACjB,GAAG,MAAM;YACT,MAAM;SACP,CAAC,CAAC;QAGH,IAAI,MAAM,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,MAAM,CAAC,UAAU,CAAC,GAAG,CAAC,EAAE,CAAC;YACrD,YAAY,CAAC,GAAG,CAAC;gBACf,GAAG,MAAM;gBACT,MAAM;aACP,CAAC,CAAC;QACL,CAAC;IACH,CAAC,CAAC,CAAC;IAEH,IAAI,EAAE,CAAC;AACT,CAAC,CAAC;AAvBW,QAAA,wBAAwB,4BAuBnC"} \ No newline at end of file diff --git a/src/building-blocks/nest-cli.json b/src/building-blocks/nest-cli.json index 683d117..23d67e2 100644 --- a/src/building-blocks/nest-cli.json +++ b/src/building-blocks/nest-cli.json @@ -1,6 +1,6 @@ { + "$schema": "https://json.schemastore.org/nest-cli", "collection": "@nestjs/schematics", - "sourceRoot": "src", "compilerOptions": { } } diff --git a/src/building-blocks/openTelemetry/open-telemetry-tracer.js b/src/building-blocks/openTelemetry/open-telemetry-tracer.js index 8b60fee..b54abae 100644 --- a/src/building-blocks/openTelemetry/open-telemetry-tracer.js +++ b/src/building-blocks/openTelemetry/open-telemetry-tracer.js @@ -31,6 +31,9 @@ const api_1 = require("@opentelemetry/api"); const configs_1 = __importDefault(require("../configs/configs")); const sdk_node_1 = require("@opentelemetry/sdk-node"); class OpenTelemetryOptions { + jaegerEndpoint; + zipkinEndpoint; + serviceName; constructor(partial) { Object.assign(this, partial); } @@ -39,18 +42,17 @@ exports.OpenTelemetryOptions = OpenTelemetryOptions; let openTelemetryOptions = new OpenTelemetryOptions(); const otelSDK = initSdk(); async function initSdk() { - var _a, _b, _c, _d; const provider = new sdk_trace_node_1.NodeTracerProvider({ resource: new resources_1.Resource({ - [semantic_conventions_1.SemanticResourceAttributes.SERVICE_NAME]: (_a = openTelemetryOptions === null || openTelemetryOptions === void 0 ? void 0 : openTelemetryOptions.serviceName) !== null && _a !== void 0 ? _a : configs_1.default.serviceName + [semantic_conventions_1.SemanticResourceAttributes.SERVICE_NAME]: openTelemetryOptions?.serviceName ?? configs_1.default.serviceName }) }); const jaegerExporter = new exporter_jaeger_1.JaegerExporter({ - endpoint: (_b = openTelemetryOptions === null || openTelemetryOptions === void 0 ? void 0 : openTelemetryOptions.jaegerEndpoint) !== null && _b !== void 0 ? _b : configs_1.default.monitoring.jaegerEndpoint + endpoint: openTelemetryOptions?.jaegerEndpoint ?? configs_1.default.monitoring.jaegerEndpoint }); const zipkinExporter = new exporter_zipkin_1.ZipkinExporter({ - url: (_c = openTelemetryOptions === null || openTelemetryOptions === void 0 ? void 0 : openTelemetryOptions.zipkinEndpoint) !== null && _c !== void 0 ? _c : configs_1.default.monitoring.zipkinEndpoint, - serviceName: (_d = openTelemetryOptions === null || openTelemetryOptions === void 0 ? void 0 : openTelemetryOptions.serviceName) !== null && _d !== void 0 ? _d : configs_1.default.serviceName + url: openTelemetryOptions?.zipkinEndpoint ?? configs_1.default.monitoring.zipkinEndpoint, + serviceName: openTelemetryOptions?.serviceName ?? configs_1.default.serviceName }); provider.addSpanProcessor(new sdk_trace_base_1.SimpleSpanProcessor(jaegerExporter)); provider.addSpanProcessor(new sdk_trace_node_1.BatchSpanProcessor(zipkinExporter)); @@ -67,6 +69,7 @@ async function initSdk() { }); } let OpenTelemetryTracer = class OpenTelemetryTracer { + options; constructor(options) { this.options = options; openTelemetryOptions = this.options; @@ -75,8 +78,7 @@ let OpenTelemetryTracer = class OpenTelemetryTracer { (await otelSDK).start(); } async createTracer(options) { - var _a; - const tracer = api_1.trace.getTracer((_a = options === null || options === void 0 ? void 0 : options.serviceName) !== null && _a !== void 0 ? _a : configs_1.default.serviceName); + const tracer = api_1.trace.getTracer(options?.serviceName ?? configs_1.default.serviceName); return tracer; } }; diff --git a/src/building-blocks/openTelemetry/open-telemetry-tracer.js.map b/src/building-blocks/openTelemetry/open-telemetry-tracer.js.map index 31457be..d07d5be 100644 --- a/src/building-blocks/openTelemetry/open-telemetry-tracer.js.map +++ b/src/building-blocks/openTelemetry/open-telemetry-tracer.js.map @@ -1 +1 @@ -{"version":3,"file":"open-telemetry-tracer.js","sourceRoot":"","sources":["open-telemetry-tracer.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAAA,2CAAkE;AAClE,kEAAuF;AACvF,oEAAgE;AAChE,oFAAgF;AAChF,kEAAoE;AACpE,8EAA0E;AAC1E,oFAAgF;AAChF,4FAAiF;AACjF,wDAAoD;AACpD,8EAAiF;AACjF,oEAAgE;AAChE,4CAAmD;AACnD,iEAAyC;AACzC,sDAAkD;AAElD,MAAa,oBAAoB;IAK/B,YAAY,OAAuC;QACjD,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AARD,oDAQC;AAED,IAAI,oBAAoB,GAAyB,IAAI,oBAAoB,EAAE,CAAC;AAE5E,MAAM,OAAO,GAAG,OAAO,EAAE,CAAC;AAE1B,KAAK,UAAU,OAAO;;IACpB,MAAM,QA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AAP,OAAO,CAAsB;QACtF,oBAAoB,GAAG,IAAI,CAAC,OAAO,CAAC;IACtC,CAAC;IACD,KAAK,CAAC,YAAY;QAChB,CAAC,MAAM,OAAO,CAAC,CAAC,KAAK,EAAE,CAAC;IAC1B,CAAC;IAED,KAAK,CAAC,YAAY,CAAC,OAA6B;;QAC9C,MAAM,MAAM,GAAG,WAAK,CAAC,SAAS,CAAC,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,WAAW,mCAAI,iBAAO,CAAC,WAAW,CAAC,CAAC;QAC5E,OAAO,MAAM,CAAC;IAChB,CAAC;CACF,CAAA;AAZY,kDAAmB;8BAAnB,mBAAmB;IAD/B,IAAA,mBAAU,GAAE;IAEE,WAAA,IAAA,eAAM,EAAC,oBAAoB,CAAC,CAAA;qCAA2B,oBAAoB;GAD7E,mBAAmB,CAY/B"} \ No newline at end of file +{"version":3,"file":"open-telemetry-tracer.js","sourceRoot":"","sources":["open-telemetry-tracer.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAAA,2CAAkE;AAClE,kEAAuF;AACvF,oEAAgE;AAChE,oFAAgF;AAChF,kEAAoE;AACpE,8EAA0E;AAC1E,oFAAgF;AAChF,4FAAiF;AACjF,wDAAoD;AACpD,8EAAiF;AACjF,oEAAgE;AAChE,4CAAmD;AACnD,iEAAyC;AACzC,sDAAkD;AAElD,MAAa,oBAAoB;IAC/B,cAAc,CAAU;IACxB,cAAc,CAAU;IACxB,WAAW,CAAS;IAEpB,YAAY,OAAuC;QACjD,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,CAAC;CACF;AARD,oDAQC;AAED,IAAI,oBAAoB,GAAyB,IAAI,oBAAoB,EAAE,CAAC;AAE5E,MAAM,OAAO,GAAG,OAAO,EAAE,CAAC;AAE1B,KAAK,UAAU,OAAO;IACpB,MAAM,QAAQ,GAAG,IAAI,mCAAkB,CAAC;QACtC,QAAQ,EAAE,IAAI,oBAAQ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9C,MAAM,MAAM,GAAG,WAAK,CAAC,SAAS,CAAC,OAAO,EAAE,WAAW,IAAI,iBAAO,CAAC,WAAW,CAAC,CAAC;QAC5E,OAAO,MAAM,CAAC;IAChB,CAAC;CACF,CAAA;AAZY,kDAAmB;8BAAnB,mBAAmB;IAD/B,IAAA,mBAAU,GAAE;IAEE,WAAA,IAAA,eAAM,EAAC,oBAAoB,CAAC,CAAA;qCAA2B,oBAAoB;GAD7E,mBAAmB,CAY/B"} \ No newline at end of file diff --git a/src/building-blocks/passport/jwt.guard.d.ts b/src/building-blocks/passport/jwt.guard.d.ts index c212a10..32494ff 100644 --- a/src/building-blocks/passport/jwt.guard.d.ts +++ b/src/building-blocks/passport/jwt.guard.d.ts @@ -1,7 +1,7 @@ import { ExecutionContext } from '@nestjs/common'; declare const JwtGuard_base: import("@nestjs/passport").Type; export declare class JwtGuard extends JwtGuard_base { - canActivate(context: ExecutionContext): boolean | Promise | import("node_modules/rxjs/dist/types").Observable; + canActivate(context: ExecutionContext): boolean | Promise | import("rxjs").Observable; handleRequest(err: any, user: any, _info: any): any; } export {}; diff --git a/src/building-blocks/passport/jwt.guard.js b/src/building-blocks/passport/jwt.guard.js index 09e4f9d..60b295b 100644 --- a/src/building-blocks/passport/jwt.guard.js +++ b/src/building-blocks/passport/jwt.guard.js @@ -24,3 +24,4 @@ exports.JwtGuard = JwtGuard; exports.JwtGuard = JwtGuard = __decorate([ (0, common_1.Injectable)() ], JwtGuard); +//# sourceMappingURL=jwt.guard.js.map \ No newline at end of file diff --git a/src/building-blocks/rabbitmq/rabbitmq-connection.js b/src/building-blocks/rabbitmq/rabbitmq-connection.js index a9a1717..d52c83d 100644 --- a/src/building-blocks/rabbitmq/rabbitmq-connection.js +++ b/src/building-blocks/rabbitmq/rabbitmq-connection.js @@ -54,6 +54,10 @@ const amqp = __importStar(require("amqplib")); const configs_1 = __importDefault(require("../configs/configs")); const async_retry_1 = __importDefault(require("async-retry")); class RabbitmqOptions { + host; + port; + password; + username; constructor(partial) { Object.assign(this, partial); } @@ -62,6 +66,7 @@ exports.RabbitmqOptions = RabbitmqOptions; let connection = null; let channel = null; let RabbitmqConnection = class RabbitmqConnection { + options; constructor(options) { this.options = options; } @@ -69,16 +74,14 @@ let RabbitmqConnection = class RabbitmqConnection { await this.createConnection(this.options); } async createConnection(options) { - var _a, _b; if (!connection || !connection == undefined) { try { - const host = (_a = options === null || options === void 0 ? void 0 : options.host) !== null && _a !== void 0 ? _a : configs_1.default.rabbitmq.host; - const port = (_b = options === null || options === void 0 ? void 0 : options.port) !== null && _b !== void 0 ? _b : configs_1.default.rabbitmq.port; + const host = options?.host ?? configs_1.default.rabbitmq.host; + const port = options?.port ?? configs_1.default.rabbitmq.port; await (0, async_retry_1.default)(async () => { - var _a, _b; connection = await amqp.connect(`amqp://${host}:${port}`, { - username: (_a = options === null || options === void 0 ? void 0 : options.username) !== null && _a !== void 0 ? _a : configs_1.default.rabbitmq.username, - password: (_b = options === null || options === void 0 ? void 0 : options.password) !== null && _b !== void 0 ? _b : configs_1.default.rabbitmq.password + username: options?.username ?? configs_1.default.rabbitmq.username, + password: options?.password ?? configs_1.default.rabbitmq.password }); }, { retries: configs_1.default.retry.count, diff --git a/src/building-blocks/rabbitmq/rabbitmq-connection.js.map b/src/building-blocks/rabbitmq/rabbitmq-connection.js.map index 70b38d9..0e68295 100644 --- a/src/building-blocks/rabbitmq/rabbitmq-connection.js.map +++ b/src/building-blocks/rabbitmq/rabbitmq-connection.js.map @@ -1 +1 @@ -{"version":3,"file":"rabbitmq-connection.js","sourceRoot":"","sources":["rabbitmq-connection.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,2CAA0E;AAC1E,8CAAgC;AAChC,iEAAyC;AACzC,8DAAqC;AAErC,MAAa,eAAe;IAK1B,YAAY,OAAkC;QAC5C,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/B,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D,MAAM,IAAI,CAAC,WAAW,EAAE,CAAC;gBACzB,MAAM,IAAI,CAAC,UAAU,EAAE,CAAC;YAC1B,CAAC,CAAC,CAAC;YAEH,OAAO,OAAO,CAAC;QACjB,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,eAAM,CAAC,KAAK,CAAC,wBAAwB,CAAC,CAAC;QACzC,CAAC;IACH,CAAC;IAED,KAAK,CAAC,WAAW;QACf,IAAI,CAAC;YACH,IAAI,OAAO,EAAE,CAAC;gBACZ,MAAM,OAAO,CAAC,KAAK,EAAE,CAAC;gBACtB,eAAM,CAAC,GAAG,CAAC,6BAA6B,CAAC,CAAC;YAC5C,CAAC;QACH,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,eAAM,CAAC,KAAK,CAAC,uBAAuB,CAAC,CAAC;QACxC,CAAC;IACH,CAAC;IAED,KAAK,CAAC,eAAe;QACnB,IAAI,CAAC;YACH,IAAI,UAAU,EAAE,CAAC;gBACf,MAAM,UAAU,CAAC,KAAK,EAAE,CAAC;gBACzB,eAAM,CAAC,GAAG,CAAC,uCAAuC,CAAC,CAAC;YACtD,CAAC;QACH,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,eAAM,CAAC,KAAK,CAAC,mCAAmC,CAAC,CAAC;QACpD,CAAC;IACH,CAAC;CACF,CAAA;AA7FY,gDAAkB;6BAAlB,kBAAkB;IAD9B,IAAA,mBAAU,GAAE;IAEE,WAAA,IAAA,eAAM,EAAC,eAAe,CAAC,CAAA;qCAA4B,eAAe;GADpE,kBAAkB,CA6F9B"} \ No newline at end of file +{"version":3,"file":"rabbitmq-connection.js","sourceRoot":"","sources":["rabbitmq-connection.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,2CAA0E;AAC1E,8CAAgC;AAChC,iEAAyC;AACzC,8DAAqC;AAErC,MAAa,eAAe;IAC1B,IAAI,CAAS;IACb,IAAI,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gBACpD,MAAM,IAAI,CAAC,WAAW,EAAE,CAAC;gBACzB,MAAM,IAAI,CAAC,UAAU,EAAE,CAAC;YAC1B,CAAC,CAAC,CAAC;YAEH,OAAO,OAAO,CAAC;QACjB,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,eAAM,CAAC,KAAK,CAAC,wBAAwB,CAAC,CAAC;QACzC,CAAC;IACH,CAAC;IAED,KAAK,CAAC,WAAW;QACf,IAAI,CAAC;YACH,IAAI,OAAO,EAAE,CAAC;gBACZ,MAAM,OAAO,CAAC,KAAK,EAAE,CAAC;gBACtB,eAAM,CAAC,GAAG,CAAC,6BAA6B,CAAC,CAAC;YAC5C,CAAC;QACH,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,eAAM,CAAC,KAAK,CAAC,uBAAuB,CAAC,CAAC;QACxC,CAAC;IACH,CAAC;IAED,KAAK,CAAC,eAAe;QACnB,IAAI,CAAC;YACH,IAAI,UAAU,EAAE,CAAC;gBACf,MAAM,UAAU,CAAC,KAAK,EAAE,CAAC;gBACzB,eAAM,CAAC,GAAG,CAAC,uCAAuC,CAAC,CAAC;YACtD,CAAC;QACH,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,eAAM,CAAC,KAAK,CAAC,mCAAmC,CAAC,CAAC;QACpD,CAAC;IACH,CAAC;CACF,CAAA;AA7FY,gDAAkB;6BAAlB,kBAAkB;IAD9B,IAAA,mBAAU,GAAE;IAEE,WAAA,IAAA,eAAM,EAAC,eAAe,CAAC,CAAA;qCAA4B,eAAe;GADpE,kBAAkB,CA6F9B"} \ No newline at end of file diff --git a/src/building-blocks/rabbitmq/rabbitmq-publisher.js b/src/building-blocks/rabbitmq/rabbitmq-publisher.js index 86f5cb7..56a65bd 100644 --- a/src/building-blocks/rabbitmq/rabbitmq-publisher.js +++ b/src/building-blocks/rabbitmq/rabbitmq-publisher.js @@ -27,6 +27,8 @@ const configs_1 = __importDefault(require("../configs/configs")); const async_retry_1 = __importDefault(require("async-retry")); const publishedMessages = []; let RabbitmqPublisher = class RabbitmqPublisher { + rabbitMQConnection; + openTelemetryTracer; constructor(rabbitMQConnection, openTelemetryTracer) { this.rabbitMQConnection = rabbitMQConnection; this.openTelemetryTracer = openTelemetryTracer; diff --git a/src/building-blocks/rabbitmq/rabbitmq-publisher.js.map b/src/building-blocks/rabbitmq/rabbitmq-publisher.js.map index 756a4b6..fa2d41a 100644 --- a/src/building-blocks/rabbitmq/rabbitmq-publisher.js.map +++ b/src/building-blocks/rabbitmq/rabbitmq-publisher.js.map @@ -1 +1 @@ -{"version":3,"file":"rabbitmq-publisher.js","sourceRoot":"","sources":["rabbitmq-publisher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAAA,2CAA4D;AAC5D,+DAAgF;AAChF,wDAAwD;AACxD,oDAAkD;AAClD,mCAAmC;AACnC,+BAAoC;AACpC,uCAAuC;AAEvC,iEAAyC;AACzC,8DAAqC;AAErC,MAAM,iBAAiB,GAAa,EAAE,CAAC;AAQhC,IAAM,iBAAiB,GAAvB,MAAM,iBAAiB;IAC5B,YACmB,kBAAsC,EACN,mBAAyC;QADzE,uBAAkB,GAAlB,kBAAkB,CAAoB;QACN,wBAAmB,GAAnB,mBAAmB,CAAsB;IACzF,CAAC;IAEJ,KAAK,CAAC,cAAc,CAAI,OAAU;QAChC,IAAI,CAAC;YACH,MAAM,IAAA,qBAAU,EACd,KAAK,IAAI,EAAE;gBACT,MAAM,OAAO,GAAG,MAAM,IAAI,CAAC,kBAAkB,CAAC,UAAU,EAAE,CAAC;gBAE3D,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,mBAAmB,CAAC,YAAY,CAAC;oBACzD,WAAW,EAAE,2BAA2B;iBACzC,CAAC,CAAC;gBAEH,MAAM,YAAY,GAAG,IAAA,kBAAS,EAAC,IAAA,wBAAW,EAAC,OAAO,CAAC,CAAC,CAAC;gBACrD,MAAM,iBAAiB,GAAG,IAAA,8BAAe,EAAC,OAAO,CAAC,CA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AAW,EAAE,CAAC;QAC9C,CAAC;IACH,CAAC;IAED,KAAK,CAAC,WAAW,CAAI,OAAU;QAC7B,MAAM,YAAY,GAAG,IAAA,kBAAS,EAAC,IAAA,wBAAW,EAAC,OAAO,CAAC,CAAC,CAAC;QAErD,MAAM,WAAW,GAAG,iBAAiB,CAAC,QAAQ,CAAC,YAAY,CAAC,CAAC;QAE7D,OAAO,OAAO,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC;IACtC,CAAC;CACF,CAAA;AAjEY,8CAAiB;4BAAjB,iBAAiB;IAD7B,IAAA,mBAAU,GAAE;IAIR,WAAA,IAAA,eAAM,EAAC,sBAAsB,CAAC,CAAA;qCADM,wCAAkB;GAF9C,iBAAiB,CAiE7B"} \ No newline at end of file diff --git a/src/building-blocks/rabbitmq/rabbitmq-subscriber.js b/src/building-blocks/rabbitmq/rabbitmq-subscriber.js index 5143699..e071a97 100644 --- a/src/building-blocks/rabbitmq/rabbitmq-subscriber.js +++ b/src/building-blocks/rabbitmq/rabbitmq-subscriber.js @@ -26,6 +26,8 @@ const configs_1 = __importDefault(require("../configs/configs")); const async_retry_1 = __importDefault(require("async-retry")); const consumedMessages = []; let RabbitmqConsumer = class RabbitmqConsumer { + rabbitMQConnection; + openTelemetryTracer; constructor(rabbitMQConnection, openTelemetryTracer) { this.rabbitMQConnection = rabbitMQConnection; this.openTelemetryTracer = openTelemetryTracer; @@ -45,10 +47,9 @@ let RabbitmqConsumer = class RabbitmqConsumer { await channel.bindQueue(q.queue, exchangeName, ''); common_1.Logger.log(`Waiting for messages with exchange name "${exchangeName}". To exit, press CTRL+C`); await channel.consume(q.queue, (message) => { - var _a; if (message !== null) { const span = tracer.startSpan(`receive_message_${exchangeName}`); - const messageContent = (_a = message === null || message === void 0 ? void 0 : message.content) === null || _a === void 0 ? void 0 : _a.toString(); + const messageContent = message?.content?.toString(); const headers = message.properties.headers || {}; handler(q.queue, (0, serilization_1.deserializeObject)(messageContent)); common_1.Logger.log(`Message: ${messageContent} delivered to queue: ${q.queue} with exchange name ${exchangeName}`); diff --git a/src/building-blocks/rabbitmq/rabbitmq-subscriber.js.map b/src/building-blocks/rabbitmq/rabbitmq-subscriber.js.map index be15977..39269d3 100644 --- a/src/building-blocks/rabbitmq/rabbitmq-subscriber.js.map +++ b/src/building-blocks/rabbitmq/rabbitmq-subscriber.js.map @@ -1 +1 @@ -{"version":3,"file":"rabbitmq-subscriber.js","sourceRoot":"","sources":["rabbitmq-subscriber.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAAA,2CAA4D;AAC5D,+DAA2D;AAC3D,oDAAkD;AAClD,mCAAmC;AACnC,wDAA0D;AAE1D,wCAAsC;AACtC,iEAAyC;AACzC,8DAAqC;AAGrC,MAAM,gBAAgB,GAAa,EAAE,CAAC;AAQ/B,IAAM,gBAAgB,GAAtB,MAAM,gBAAgB;IAC3B,YACmB,kBAAsC,EACN,mBAAyC;QADzE,uBAAkB,GAAlB,kBAAkB,CAAoB;QACN,wBAAmB,GAAnB,mBAAmB,CAAsB;IACzF,CAAC;IAEJ,KAAK,CAAC,cAAc,CAAI,IAAO,EAAE,OAAuB;QACtD,IAAI,CAAC;YACH,MAAM,IAAA,qBAAU,EACd,KAAK,IAAI,EAAE;gBACT,MAAM,OAAO,GAAG,MAAM,IAAI,CAAC,kBAAkB,CAAC,UAAU,EAAE,CAAC;gBAE3D,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,mBAAmB,CAAC,YAAY,CAAC;oBACzD,WAAW,EAAE,4BAA4B;iBAC1C,CAAC,CAAC;gBAEH,MAAM,YAAY,GAAG,IAAA,kBAAS,EAAC,IAAA,wBAAW,EAAC,IAAI,CAAC,CAAC,CAAC;gBAElD,MAAM,OAAO,CAAC,cAAc,CAAC,YAAY,EAAE,QAAQ,EAAE;oBACnD,OAAO,EAAE,KAAK;iBACf,CAAC,CAAC;gBAEH,MAAM,CAAC,GAAG,MAAM,OAAO,CAAC,WAAW,CAAC,EAAE,EAAE,EAAE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AAc,EAAE,CAAC;gBACnB,OAAO,KAAK,CAAC;YACf,CAAC;YACD,IAAI,UAAU,EAAE,CAAC;gBACf,OAAO,IAAI,CAAC;YACd,CAAC;YAED,MAAM,IAAA,YAAK,EAAC,IAAI,CAAC,CAAC;YAElB,MAAM,YAAY,GAAG,IAAA,kBAAS,EAAC,IAAA,wBAAW,EAAC,OAAO,CAAC,CAAC,CAAC;YAErD,UAAU,GAAG,gBAAgB,CAAC,QAAQ,CAAC,YAAY,CAAC,CAAC;YAErD,cAAc,GAAG,IAAI,CAAC,GAAG,EAAE,GAAG,SAAS,GAAG,WAAW,CAAC;QACxD,CAAC;IACH,CAAC;CACF,CAAA;AA3FY,4CAAgB;2BAAhB,gBAAgB;IAD5B,IAAA,mBAAU,GAAE;IAIR,WAAA,IAAA,eAAM,EAAC,sBAAsB,CAAC,CAAA;qCADM,wCAAkB;GAF9C,gBAAgB,CA2F5B"} \ No newline at end of file diff --git a/src/building-blocks/rabbitmq/rabbitmq.module.js b/src/building-blocks/rabbitmq/rabbitmq.module.js index 72a5465..0ccbc3d 100644 --- a/src/building-blocks/rabbitmq/rabbitmq.module.js +++ b/src/building-blocks/rabbitmq/rabbitmq.module.js @@ -17,6 +17,7 @@ const rabbitmq_connection_1 = require("./rabbitmq-connection"); const open_telemetry_module_1 = require("../openTelemetry/open-telemetry.module"); const rabbitmq_subscriber_1 = require("./rabbitmq-subscriber"); let RabbitmqModule = RabbitmqModule_1 = class RabbitmqModule { + rabbitmqConnection; constructor(rabbitmqConnection) { this.rabbitmqConnection = rabbitmqConnection; } diff --git a/src/building-blocks/rabbitmq/rabbitmq.module.js.map b/src/building-blocks/rabbitmq/rabbitmq.module.js.map index 9c0bb10..2bdb4e6 100644 --- a/src/building-blocks/rabbitmq/rabbitmq.module.js.map +++ b/src/building-blocks/rabbitmq/rabbitmq.module.js.map @@ -1 +1 @@ -{"version":3,"file":"rabbitmq.module.js","sourceRoot":"","sources":["rabbitmq.module.ts"],"names":[],"mappings":";;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A6B,kBAAsC;QAAtC,uBAAkB,GAAlB,kBAAkB,CAAoB;IAAG,CAAC;IACvE,KAAK,CAAC,qBAAqB,CAAC,MAAe;QACzC,MAAM,IAAI,CAAC,kBAAkB,CAAC,eAAe,EAAE,CAAC;IAClD,CAAC;IAED,MAAM,CAAC,OAAO,CAAC,OAAyB;QACtC,OAAO;YACL,MAAM,EAAE,gBAAc;YACtB,SAAS,EAAE,CAAC,wCAAkB,EAAE,EAAE,OAAO,EAAE,qCAAe,EAAE,QAAQ,EAAE,OAAO,EAAE,CAAC;SACjF,CAAC;IACJ,CAAC;CACF,CAAA;AAZY,wCAAc;yBAAd,cAAc;IApB1B,IAAA,eAAM,GAAE;IACR,IAAA,eAAM,EAAC;QACN,OAAO,EAAE,CAAC,2CAAmB,CAAC,OAAO,EAAE,CAAC;QACxC,SAAS,EAAE;YACT,sCAAiB;YACjB;gBACE,OAAO,EAAE,qBAAqB;gBAC9B,QAAQ,EAAE,wCAAkB;aAC7B;YACD;gBACE,OAAO,EAAE,oBAAoB;gBAC7B,QAAQ,EAAE,sCAAiB;aAC5B;YACD;gBACE,OAAO,EAAE,mBAAmB;gBAC5B,QAAQ,EAAE,sCAAgB;aAC3B;SACF;QACD,OAAO,EAAE,CAAC,qBAAqB,EAAE,oBAAoB,EAAE,mBAAmB,CAAC;KAC5E,CAAC;qCAEiD,wCAAkB;GADxD,cAAc,CAY1B"} \ No newline at end of file diff --git a/src/building-blocks/test/container/postgres/postgres-container.d.ts b/src/building-blocks/test/container/postgres/postgres-container.d.ts index ac530f9..d002413 100644 --- a/src/building-blocks/test/container/postgres/postgres-container.d.ts +++ b/src/building-blocks/test/container/postgres/postgres-container.d.ts @@ -1,6 +1,6 @@ import 'reflect-metadata'; import { StartedTestContainer } from 'testcontainers'; -import { DataSourceOptions, EntitySchema, MixedList } from 'typeorm'; +import { DataSourceOptions, EntitySchema, MixedList } from "typeorm"; export interface PostgresContainerOptions { imageName: string; type: string; diff --git a/src/building-blocks/test/container/postgres/postgres-container.js b/src/building-blocks/test/container/postgres/postgres-container.js index 00605f3..9bf7451 100644 --- a/src/building-blocks/test/container/postgres/postgres-container.js +++ b/src/building-blocks/test/container/postgres/postgres-container.js @@ -9,16 +9,19 @@ class PostgresContainer { const defaultPostgresOptions = await this.getDefaultPostgresTestContainers(); const pgContainerStarted = await this.getContainerStarted(defaultPostgresOptions); const containerPort = pgContainerStarted.getMappedPort(defaultPostgresOptions.port); - const dataSourceOptions = Object.assign(Object.assign({}, defaultPostgresOptions), { type: 'postgres', port: containerPort }); + const dataSourceOptions = { + ...defaultPostgresOptions, + type: 'postgres', + port: containerPort + }; common_1.Logger.log(`Test postgres with port ${containerPort} established`); return [pgContainerStarted, dataSourceOptions]; } async getContainerStarted(options) { - var _a; const pgContainer = new testcontainers_1.GenericContainer(options.imageName) .withExposedPorts(options.port) .withEnvironment({ POSTGRES_USER: options.username }) - .withEnvironment({ POSTGRES_PASSWORD: (_a = options.password) === null || _a === void 0 ? void 0 : _a.toString() }) + .withEnvironment({ POSTGRES_PASSWORD: options.password?.toString() }) .withEnvironment({ POSTGRES_DB: options.database }); const pgContainerStarted = await pgContainer.start(); return pgContainerStarted; diff --git a/src/building-blocks/test/container/postgres/postgres-container.js.map b/src/building-blocks/test/container/postgres/postgres-container.js.map index 9e89f97..0b0b545 100644 --- a/src/building-blocks/test/container/postgres/postgres-container.js.map +++ b/src/building-blocks/test/container/postgres/postgres-container.js.map @@ -1 +1 @@ -{"version":3,"file":"postgres-container.js","sourceRoot":"","sources":["postgres-container.ts"],"names":[],"mappings":";;;AAAA,4BAA0B;AAC1B,mDAAwE;AACxE,2CAAwC;AAgBxC,MAAa,iBAAiB;IACrB,KAAK,CAAC,KAAK;QAChB,MAAM,sBAAsB,GAAG,MAAM,IAAI,CAAC,gCAAgC,EAAE,CAAC;QAE7E,MAAM,kBAAkB,GAAG,MAAM,IAAI,CAAC,mBAAmB,CAAC,sBAAsB,CAAC,CAAC;QAElF,MAAM,aAAa,GAAG,kB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BAAgB;YAC1B,QAAQ,EAAE,gBAAgB;YAC1B,SAAS,EAAE,iBAAiB;YAC5B,WAAW,EAAE,IAAI;YACjB,aAAa,EAAE,KAAK;YACpB,QAAQ,EAAE,CAAC,2BAA2B,CAAC;SACxC,CAAC;QAEF,OAAO,eAAe,CAAC;IACzB,CAAC;CAEF;AA/CD,8CA+CC"} \ No newline at end of file diff --git a/src/building-blocks/test/container/postgres/postgres-container.ts b/src/building-blocks/test/container/postgres/postgres-container.ts index 260ccdc..0b90839 100644 --- a/src/building-blocks/test/container/postgres/postgres-container.ts +++ b/src/building-blocks/test/container/postgres/postgres-container.ts @@ -1,7 +1,7 @@ import 'reflect-metadata'; import { GenericContainer, StartedTestContainer } from 'testcontainers'; -import { Logger } from '@nestjs/common'; -import { DataSourceOptions, EntitySchema, MixedList } from 'typeorm'; +import {Logger} from "@nestjs/common"; +import {DataSourceOptions, EntitySchema, MixedList} from "typeorm"; export interface PostgresContainerOptions { imageName: string; @@ -16,8 +16,8 @@ export interface PostgresContainerOptions { migrationsRun: boolean; } -export class PostgresContainer { - public async start(): Promise<[StartedTestContainer, DataSourceOptions]> { +export class PostgresContainer{ + public async start(): Promise<[StartedTestContainer, DataSourceOptions]>{ const defaultPostgresOptions = await this.getDefaultPostgresTestContainers(); const pgContainerStarted = await this.getContainerStarted(defaultPostgresOptions); @@ -35,9 +35,7 @@ export class PostgresContainer { return [pgContainerStarted, dataSourceOptions]; } - private async getContainerStarted( - options: PostgresContainerOptions - ): Promise { + private async getContainerStarted(options: PostgresContainerOptions): Promise{ const pgContainer = new GenericContainer(options.imageName) .withExposedPorts(options.port) .withEnvironment({ POSTGRES_USER: options.username }) @@ -48,7 +46,7 @@ export class PostgresContainer { return pgContainerStarted; } - private async getDefaultPostgresTestContainers(): Promise { + private async getDefaultPostgresTestContainers(): Promise{ const postgresOptions: PostgresContainerOptions = { type: 'postgres', database: 'test_db', @@ -64,4 +62,5 @@ export class PostgresContainer { return postgresOptions; } + } diff --git a/src/building-blocks/test/container/rabbitmq/rabbitmq-container.js b/src/building-blocks/test/container/rabbitmq/rabbitmq-container.js index 1d9704d..934c743 100644 --- a/src/building-blocks/test/container/rabbitmq/rabbitmq-container.js +++ b/src/building-blocks/test/container/rabbitmq/rabbitmq-container.js @@ -13,17 +13,24 @@ class RabbitmqContainer { const defaultRabbitmqOptions = await this.getDefaultRabbitmqTestContainers(); const rabbitmqContainerStarted = await this.getContainerStarted(defaultRabbitmqOptions); const containerPort = rabbitmqContainerStarted.getMappedPort(defaultRabbitmqOptions.port); - configs_1.default.rabbitmq = Object.assign(Object.assign({}, configs_1.default.rabbitmq), { port: containerPort, username: defaultRabbitmqOptions.username, password: defaultRabbitmqOptions.password, host: defaultRabbitmqOptions.host }); - const rabbitmqOptions = Object.assign({}, configs_1.default.rabbitmq); + configs_1.default.rabbitmq = { + ...configs_1.default.rabbitmq, + port: containerPort, + username: defaultRabbitmqOptions.username, + password: defaultRabbitmqOptions.password, + host: defaultRabbitmqOptions.host + }; + const rabbitmqOptions = { + ...configs_1.default.rabbitmq + }; common_1.Logger.log(`Test rabbitmq with port ${containerPort} established`); return [rabbitmqContainerStarted, rabbitmqOptions]; } async getContainerStarted(options) { - var _a; const rabbitmqContainer = new testcontainers_1.GenericContainer(options.imageName) .withExposedPorts(options.port) .withEnvironment({ RABBITMQ_DEFAULT_USER: options.username }) - .withEnvironment({ RABBITMQ_DEFAULT_PASS: (_a = options.password) === null || _a === void 0 ? void 0 : _a.toString() }); + .withEnvironment({ RABBITMQ_DEFAULT_PASS: options.password?.toString() }); const rabbitmqContainerStarted = await rabbitmqContainer.start(); return rabbitmqContainerStarted; } @@ -33,7 +40,7 @@ class RabbitmqContainer { host: 'localhost', username: 'guest', password: 'guest', - imageName: 'rabbitmq:3-management' + imageName: 'rabbitmq:management' }; return rabbitmqOptions; } diff --git a/src/building-blocks/test/container/rabbitmq/rabbitmq-container.js.map b/src/building-blocks/test/container/rabbitmq/rabbitmq-container.js.map index 5492f72..6e367ec 100644 --- a/src/building-blocks/test/container/rabbitmq/rabbitmq-container.js.map +++ b/src/building-blocks/test/container/rabbitmq/rabbitmq-container.js.map @@ -1 +1 @@ -{"version":3,"file":"rabbitmq-container.js","sourceRoot":"","sources":["rabbitmq-container.ts"],"names":[],"mappings":";;;;;;AAAA,4BAA0B;AAC1B,mDAAwE;AACxE,2CAAwC;AACxC,uEAA+C;AAW/C,MAAa,iBAAiB;IACrB,KAAK,CAAC,KAAK;QAChB,MAAM,sBAAsB,GAAG,MAAM,IAAI,CAAC,gCAAgC,EAAE,CAAC;QAE7E,MAAM,wBAAwB,GAAG,MAAM,IAAI,CAAC,mBAAmB,CAAC,sBAAsB,CAAC,CAAC;QAExF,MAAM,aAAa,GAAG,wBAAwB,CAAC,aAAa,CAAC,sBAAsB,CAAC,IAAI,CAAC,CAAC;QAE1F,iBAAO,CAAC,QAAQ,mCACX,iBAAO,CAAC,QAAQ,KACnB,IAAI,EAAE,aAAa,EACnB,QAAQ,EAAE,sBAAsB,CAAC,QAAQ,EACzC,QAAQ,EAAE,sBAAsB,CAAC,QAAQ,EACzC,IAAI,EAAE,sBAAsB,CAAC,IAAI,GAClC,CAAC;QAEF,MAAM,eAAe,qBAChB,iBAAO,CAAC,QAAQ,CACpB,CAAC;QAEF,eAAM,CAAC,GAAG,CAAC,2BAA2B,aAAa,cAAc,CAAC,CAAC;QAEnE,OAAO,CAAC,wBAAwB,EAAE,eAAe,CAAC,CAAC;IACrD,CAAC;IAEO,KAAK,CAAC,mBAAmB,CAC/B,OAAiC;;QAEjC,MAAM,iBAAiB,GAAG,IAAI,iCAAgB,CAAC,OAAO,CAAC,SAAS,CAAC;aAC9D,gBAAgB,CAAC,OAAO,CAAC,IAAI,CAAC;aAC9B,eAAe,CAAC,EAAE,qBAAqB,EAAE,OAAO,CAAC,QAAQ,EAAE,CAAC;aAC5D,eAAe,CAAC,EAAE,qBAAqB,EAAE,MAAA,OAAO,CAAC,QAAQ,0CAAE,QAAQ,EAAE,EAAE,CA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/B,OAAiC;QAEjC,MAAM,iBAAiB,GAAG,IAAI,iCAAgB,CAAC,OAAO,CAAC,SAAS,CAAC;aAC9D,gBAAgB,CAAC,OAAO,CAAC,IAAI,CAAC;aAC9B,eAAe,CAAC,EAAE,qBAAqB,EAAE,OAAO,CAAC,QAAQ,EAAE,CAAC;aAC5D,eAAe,CAAC,EAAE,qBAAqB,EAAE,OAAO,CAAC,QAAQ,EAAE,QAAQ,EAAE,EAAE,CAAC,CAAC;QAC5E,MAAM,wBAAwB,GAAG,MAAM,iBAAiB,CAAC,KAAK,EAAE,CAAC;QAEjE,OAAO,wBAAwB,CAAC;IAClC,CAAC;IAEO,KAAK,CAAC,gCAAgC;QAC5C,MAAM,eAAe,GAA6B;YAChD,IAAI,EAAE,IAAI;YACV,IAAI,EAAE,WAAW;YACjB,QAAQ,EAAE,OAAO;YACjB,QAAQ,EAAE,OAAO;YACjB,SAAS,EAAE,qBAAqB;SACjC,CAAC;QAEF,OAAO,eAAe,CAAC;IACzB,CAAC;CACF;AAhDD,8CAgDC"} \ No newline at end of file diff --git a/src/building-blocks/test/container/rabbitmq/rabbitmq-container.ts b/src/building-blocks/test/container/rabbitmq/rabbitmq-container.ts index bab6c22..a8f5da3 100644 --- a/src/building-blocks/test/container/rabbitmq/rabbitmq-container.ts +++ b/src/building-blocks/test/container/rabbitmq/rabbitmq-container.ts @@ -55,7 +55,7 @@ export class RabbitmqContainer { host: 'localhost', username: 'guest', password: 'guest', - imageName: 'rabbitmq:3-management' + imageName: 'rabbitmq:management' }; return rabbitmqOptions; diff --git a/src/building-blocks/tsconfig.json b/src/building-blocks/tsconfig.json index fcae4cb..a139042 100644 --- a/src/building-blocks/tsconfig.json +++ b/src/building-blocks/tsconfig.json @@ -8,14 +8,13 @@ // Modules and Output "moduleResolution": "node", // Use Node.js module resolution "baseUrl": "./", // Base directory for paths - "outDir": "./dist", // Output directory - "declaration": true, // Generate .d.ts files (mostly use in library development) - "sourceMap": true, // Generate source maps (mostly use in library development) + "declaration": true, // Generate .d.ts files + "sourceMap": true, // Generate source maps "removeComments": true, // Remove comments in output // Decorators (needed for NestJS) "experimentalDecorators": true, // Enable decorators - "emitDecoratorMetadata": true, // Emit decorator metadata + "emitDecoratorMetadata": true, // Emit decorator metadata // Type Checking "strict": false, // Enable all strict type checking @@ -29,6 +28,7 @@ // Advanced "incremental": true, // Enable incremental compilation "preserveConstEnums": true, // Keep const enums in output - "resolveJsonModule": true // Allow importing JSON files + "resolveJsonModule": true, // Allow importing JSON files + "isolatedModules": false, // Forces each file to be a module or not }, } diff --git a/src/building-blocks/types/exeptions/application.exception.js b/src/building-blocks/types/exeptions/application.exception.js index dad78ea..c85867e 100644 --- a/src/building-blocks/types/exeptions/application.exception.js +++ b/src/building-blocks/types/exeptions/application.exception.js @@ -3,6 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true }); exports.ApplicationException = void 0; const common_1 = require("@nestjs/common"); class ApplicationException extends Error { + statusCode; + isOperational; constructor(message, statusCode = common_1.HttpStatus.BAD_REQUEST, isOperational = true, stack = '') { super(message); this.statusCode = statusCode; diff --git a/src/building-blocks/types/exeptions/application.exception.js.map b/src/building-blocks/types/exeptions/application.exception.js.map index 0b6aaa1..fa64820 100644 --- a/src/building-blocks/types/exeptions/application.exception.js.map +++ b/src/building-blocks/types/exeptions/application.exception.js.map @@ -1 +1 @@ -{"version":3,"file":"application.exception.js","sourceRoot":"","sources":["application.exception.ts"],"names":[],"mappings":";;;AAAA,2CAA4C;AAE5C,MAAa,oBAAqB,SAAQ,KAAK;IAI7C,YACE,OAA2B,EAC3B,aAAqB,mBAAU,CAAC,WAAW,EAC3C,aAAa,GAAG,IAAI,EACpB,KAAK,GAAG,EAAE;QAEV,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;QAC7B,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;QACnC,IAAI,KAAK,EAAE,CAAC;YACV,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;QACrB,CAAC;aAAM,CAAC;YACN,KAAK,CAAC,iBAAiB,CAAC,IAAI,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC;QAClD,CAAC;IACH,CAAC;CACF;AAnBD,oDAmBC;AAED,kBAAe,oBAAoB,CAAC"} \ No newline at end of file +{"version":3,"file":"application.exception.js","sourceRoot":"","sources":["application.exception.ts"],"names":[],"mappings":";;;AAAA,2CAA4C;AAE5C,MAAa,oBAAqB,SAAQ,KAAK;IAC7C,UAAU,CAAS;IACnB,aAAa,CAAU;IAEvB,YACE,OAA2B,EAC3B,aAAqB,mBAAU,CAAC,WAAW,EAC3C,aAAa,GAAG,IAAI,EACpB,KAAK,GAAG,EAAE;QAEV,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;QAC7B,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;QACnC,IAAI,KAAK,EAAE,CAAC;YACV,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;QACrB,CAAC;aAAM,CAAC;YACN,KAAK,CAAC,iBAAiB,CAAC,IAAI,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC;QAClD,CAAC;IACH,CAAC;CACF;AAnBD,oDAmBC;AAED,kBAAe,oBAAoB,CAAC"} \ No newline at end of file diff --git a/src/building-blocks/types/exeptions/http-client.exception.js b/src/building-blocks/types/exeptions/http-client.exception.js index 2a1252f..b36a8da 100644 --- a/src/building-blocks/types/exeptions/http-client.exception.js +++ b/src/building-blocks/types/exeptions/http-client.exception.js @@ -3,6 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true }); exports.HttpClientException = void 0; const common_1 = require("@nestjs/common"); class HttpClientException extends Error { + statusCode; + isOperational; constructor(message, statusCode = common_1.HttpStatus.BAD_REQUEST, isOperational = true, stack = '') { super(message); this.statusCode = statusCode; diff --git a/src/building-blocks/types/exeptions/http-client.exception.js.map b/src/building-blocks/types/exeptions/http-client.exception.js.map index cb9d333..95175a6 100644 --- a/src/building-blocks/types/exeptions/http-client.exception.js.map +++ b/src/building-blocks/types/exeptions/http-client.exception.js.map @@ -1 +1 @@ -{"version":3,"file":"http-client.exception.js","sourceRoot":"","sources":["http-client.exception.ts"],"names":[],"mappings":";;;AAAA,2CAA4C;AAE5C,MAAa,mBAAoB,SAAQ,KAAK;IAI5C,YACE,OAA2B,EAC3B,aAAqB,mBAAU,CAAC,WAAW,EAC3C,aAAa,GAAG,IAAI,EACpB,KAAK,GAAG,EAAE;QAEV,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;QAC7B,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;QACnC,IAAI,KAAK,EAAE,CAAC;YACV,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;QACrB,CAAC;aAAM,CAAC;YACN,KAAK,CAAC,iBAAiB,CAAC,IAAI,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC;QAClD,CAAC;IACH,CAAC;CACF;AAnBD,kDAmBC;AAED,kBAAe,mBAAmB,CAAC"} \ No newline at end of file +{"version":3,"file":"http-client.exception.js","sourceRoot":"","sources":["http-client.exception.ts"],"names":[],"mappings":";;;AAAA,2CAA4C;AAE5C,MAAa,mBAAoB,SAAQ,KAAK;IAC5C,UAAU,CAAS;IACnB,aAAa,CAAU;IAEvB,YACE,OAA2B,EAC3B,aAAqB,mBAAU,CAAC,WAAW,EAC3C,aAAa,GAAG,IAAI,EACpB,KAAK,GAAG,EAAE;QAEV,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;QAC7B,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;QACnC,IAAI,KAAK,EAAE,CAAC;YACV,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;QACrB,CAAC;aAAM,CAAC;YACN,KAAK,CAAC,iBAAiB,CAAC,IAAI,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC;QAClD,CAAC;IACH,CAAC;CACF;AAnBD,kDAmBC;AAED,kBAAe,mBAAmB,CAAC"} \ No newline at end of file diff --git a/src/building-blocks/types/pagination/paged-result.js b/src/building-blocks/types/pagination/paged-result.js index 4707cda..f498a19 100644 --- a/src/building-blocks/types/pagination/paged-result.js +++ b/src/building-blocks/types/pagination/paged-result.js @@ -2,6 +2,8 @@ Object.defineProperty(exports, "__esModule", { value: true }); exports.PagedResult = void 0; class PagedResult { + result; + total; constructor(result, total) { this.result = result; this.total = total; diff --git a/src/building-blocks/types/pagination/paged-result.js.map b/src/building-blocks/types/pagination/paged-result.js.map index 1f6158e..318e4af 100644 --- a/src/building-blocks/types/pagination/paged-result.js.map +++ b/src/building-blocks/types/pagination/paged-result.js.map @@ -1 +1 @@ -{"version":3,"file":"paged-result.js","sourceRoot":"","sources":["paged-result.ts"],"names":[],"mappings":";;;AAAA,MAAa,WAAW;IAItB,YAAY,MAAS,EAAE,KAAa;QAClC,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;IACrB,CAAC;CACF;AARD,kCAQC"} \ No newline at end of file +{"version":3,"file":"paged-result.js","sourceRoot":"","sources":["paged-result.ts"],"names":[],"mappings":";;;AAAA,MAAa,WAAW;IACtB,MAAM,CAAI;IACV,KAAK,CAAS;IAEd,YAAY,MAAS,EAAE,KAAa;QAClC,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;IACrB,CAAC;CACF;AARD,kCAQC"} \ No newline at end of file diff --git a/src/building-blocks/utils/encryption.js.map b/src/building-blocks/utils/encryption.js.map index 9ca55bb..98103a8 100644 --- a/src/building-blocks/utils/encryption.js.map +++ b/src/building-blocks/utils/encryption.js.map @@ -1 +1 @@ -{"version":3,"file":"encryption.js","sourceRoot":"","sources":["encryption.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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AO,kBAAM,CAAC,OAAO,CAAC,QAAQ,EAAE,YAAY,CAAC,CAAC;AAChD,CAAC,CAAC;AAFW,QAAA,eAAe,mBAE1B;AAEK,MAAM,eAAe,GAAG,KAAK,IAAqB,EAAE;IACzD,MAAM,QAAQ,GAAG;QACf,MAAM,EAAE,UAAU;QAClB,MAAM,EAAE,CAAC,MAAM,EAAE,OAAO,CAAC;KAC1B,CAAC;IACF,OAAO,GAAG,CAAC,IAAI,CAAC,QAAQ,EAAE,iBAAO,CAAC,GAAG,CAAC,MAAM,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;AACrE,CAAC,CAAC;AANW,QAAA,eAAe,mBAM1B"} \ No newline at end of file diff --git a/src/identity/test/end-to-end-test/user/features/create-user.test.d.ts b/src/identity/test/end-to-end-test/user/features/create-user.test.d.ts deleted file mode 100644 index d2c9bc6..0000000 --- a/src/identity/test/end-to-end-test/user/features/create-user.test.d.ts +++ /dev/null @@ -1 +0,0 @@ -import 'reflect-metadata'; diff --git a/src/identity/test/end-to-end-test/user/features/create-user.test.js b/src/identity/test/end-to-end-test/user/features/create-user.test.js deleted file mode 100644 index ad1ae49..0000000 --- a/src/identity/test/end-to-end-test/user/features/create-user.test.js +++ /dev/null @@ -1,23 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -require("reflect-metadata"); -const end_to_end_fixture_1 = require("../../../shared/fixtures/end-to-end.fixture"); -const fake_create_user_request_dto_1 = require("../../../shared/fakes/user/fake-create-user-request.dto"); -const request = require('supertest'); -describe('end-to-end test for create user', () => { - const endToEndFixture = new end_to_end_fixture_1.EndToEndTestFixture(); - let fixture; - beforeAll(async () => { - fixture = await endToEndFixture.initializeFixture(); - }); - afterAll(async () => { - await endToEndFixture.cleanUp(); - }); - it('should create user and retrieve 201 status code', async () => { - const createUserResponse = await request(fixture.app.getHttpServer()) - .post('/api/v1/user/create') - .send(fake_create_user_request_dto_1.FakeCreateUserRequestDto.generate()) - .expect(201); - }); -}); -//# sourceMappingURL=create-user.test.js.map \ No newline at end of file diff --git a/src/identity/test/end-to-end-test/user/features/create-user.test.js.map b/src/identity/test/end-to-end-test/user/features/create-user.test.js.map deleted file mode 100644 index 51c70e5..0000000 --- a/src/identity/test/end-to-end-test/user/features/create-user.test.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"create-user.test.js","sourceRoot":"","sources":["create-user.test.ts"],"names":[],"mappings":";;AAAA,4BAA0B;AAC1B,oFAAkF;AAElF,0GAAmG;AACnG,MAAM,OAAO,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC;AAErC,QAAQ,CAAC,iCAAiC,EAAE,GAAG,EAAE;IAC/C,MAAM,eAAe,GAAG,IAAI,wCAAmB,EAAE,CAAC;IAClD,IAAI,OAAgB,CAAC;IAErB,SAAS,CAAC,KAAK,IAAI,EAAE;QACnB,OAAO,GAAG,MAAM,eAAe,CAAC,iBAAiB,EAAE,CAAC;IACtD,CAAC,CAAC,CAAC;IAEH,QAAQ,CAAC,KAAK,IAAI,EAAE;QAClB,MAAM,eAAe,CAAC,OAAO,EAAE,CAAC;IAClC,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,iDAAiD,EAAE,KAAK,IAAI,EAAE;QAC/D,MAAM,kBAAkB,GAAG,MAAM,OAAO,CAAC,OAAO,CAAC,GAAG,CAAC,aAAa,EAAE,CAAC;aAClE,IAAI,CAAC,qBAAqB,CAAC;aAC3B,IAAI,CAAC,uDAAwB,CAAC,QAAQ,EAAE,CAAC;aACzC,MAAM,CAAC,GAAG,CAAC,CAAC;IACjB,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"} \ No newline at end of file diff --git a/src/identity/test/integration-test/user/features/create-user.test.d.ts b/src/identity/test/integration-test/user/features/create-user.test.d.ts deleted file mode 100644 index d2c9bc6..0000000 --- a/src/identity/test/integration-test/user/features/create-user.test.d.ts +++ /dev/null @@ -1 +0,0 @@ -import 'reflect-metadata'; diff --git a/src/identity/test/integration-test/user/features/create-user.test.js b/src/identity/test/integration-test/user/features/create-user.test.js deleted file mode 100644 index 8f6dd50..0000000 --- a/src/identity/test/integration-test/user/features/create-user.test.js +++ /dev/null @@ -1,23 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -require("reflect-metadata"); -const integration_test_fixture_1 = require("../../../shared/fixtures/integration-test.fixture"); -const fake_create_user_1 = require("../../../shared/fakes/user/fake-create-user"); -const identity_contract_1 = require("building-blocks/contracts/identity.contract"); -describe('integration test for create user', () => { - const integrationTestFixture = new integration_test_fixture_1.IntegrationTestFixture(); - let fixture; - beforeAll(async () => { - fixture = await integrationTestFixture.initializeFixture(); - }); - afterAll(async () => { - await integrationTestFixture.cleanUp(); - }); - it('should create user and retrieve a user from the database', async () => { - const result = await fixture.commandBus.execute(fake_create_user_1.FakeCreateUser.generate()); - const isPublished = await fixture.rabbitmqPublisher.isPublished(new identity_contract_1.UserCreated()); - expect(isPublished).toBe(true); - const user = fixture.userRepository.findUserById(result.id); - expect(user).not.toBeNull(); - }); -}); diff --git a/src/identity/test/integration-test/user/features/create-user.test.js.map b/src/identity/test/integration-test/user/features/create-user.test.js.map deleted file mode 100644 index 40ad22a..0000000 --- a/src/identity/test/integration-test/user/features/create-user.test.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"create-user.test.js","sourceRoot":"","sources":["create-user.test.ts"],"names":[],"mappings":";;AAAA,4BAA0B;AAC1B,gGAAoG;AACpG,kFAA6E;AAC7E,mFAA0E;AAE1E,QAAQ,CAAC,kCAAkC,EAAE,GAAG,EAAE;IAChD,MAAM,sBAAsB,GAAG,IAAI,iDAAsB,EAAE,CAAC;IAC5D,IAAI,OAAgB,CAAC;IAErB,SAAS,CAAC,KAAK,IAAI,EAAE;QACnB,OAAO,GAAG,MAAM,sBAAsB,CAAC,iBAAiB,EAAE,CAAC;IAC7D,CAAC,CAAC,CAAC;IAEH,QAAQ,CAAC,KAAK,IAAI,EAAE;QAClB,MAAM,sBAAsB,CAAC,OAAO,EAAE,CAAC;IACzC,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,0DAA0D,EAAE,KAAK,IAAI,EAAE;QACxE,MAAM,MAAM,GAAG,MAAM,OAAO,CAAC,UAAU,CAAC,OAAO,CAAC,iCAAc,CAAC,QAAQ,EAAE,CAAC,CAAC;QAE3E,MAAM,WAAW,GAAG,MAAM,OAAO,CAAC,iBAAiB,CAAC,WAAW,CAAC,IAAI,+BAAW,EAAE,CAAC,CAAC;QACnF,MAAM,CAAC,WAAW,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAE/B,MAAM,IAAI,GAAG,OAAO,CAAC,cAAc,CAAC,YAAY,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC;QAC5D,MAAM,CAAC,IAAI,CAAC,CAAC,GAAG,CAAC,QAAQ,EAAE,CAAC;IAC9B,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"} \ No newline at end of file diff --git a/src/identity/test/integration-test/user/features/create-user.test.ts b/src/identity/test/integration-test/user/features/create-user.test.ts index 4c3c449..a17b000 100644 --- a/src/identity/test/integration-test/user/features/create-user.test.ts +++ b/src/identity/test/integration-test/user/features/create-user.test.ts @@ -1,14 +1,14 @@ import 'reflect-metadata'; -import { Fixture, IntegrationTestFixture } from '../../../shared/fixtures/integration-test.fixture'; -import { FakeCreateUser } from '../../../shared/fakes/user/fake-create-user'; -import { UserCreated } from 'building-blocks/contracts/identity.contract'; +import {Fixture, IntegrationTestFixture} from "../../../shared/fixtures/integration-test.fixture"; +import {FakeCreateUser} from "../../../shared/fakes/user/fake-create-user"; +import {UserCreated} from "building-blocks/contracts/identity.contract"; describe('integration test for create user', () => { const integrationTestFixture = new IntegrationTestFixture(); let fixture: Fixture; beforeAll(async () => { - fixture = await integrationTestFixture.initializeFixture(); + fixture = await integrationTestFixture.initializeFixture() as Fixture;; }); afterAll(async () => { diff --git a/src/identity/test/shared/fixtures/end-to-end.fixture.d.ts b/src/identity/test/shared/fixtures/end-to-end.fixture.d.ts deleted file mode 100644 index f11afa7..0000000 --- a/src/identity/test/shared/fixtures/end-to-end.fixture.d.ts +++ /dev/null @@ -1,3 +0,0 @@ -import { IntegrationTestFixture } from '/integration-test.fixture'; -export declare class EndToEndTestFixture extends IntegrationTestFixture { -} diff --git a/src/identity/test/shared/fixtures/end-to-end.fixture.js b/src/identity/test/shared/fixtures/end-to-end.fixture.js deleted file mode 100644 index 51ee0aa..0000000 --- a/src/identity/test/shared/fixtures/end-to-end.fixture.js +++ /dev/null @@ -1,8 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.EndToEndTestFixture = void 0; -const integration_test_fixture_1 = require("/integration-test.fixture"); -class EndToEndTestFixture extends integration_test_fixture_1.IntegrationTestFixture { -} -exports.EndToEndTestFixture = EndToEndTestFixture; -//# sourceMappingURL=end-to-end.fixture.js.map \ No newline at end of file diff --git a/src/identity/test/shared/fixtures/end-to-end.fixture.js.map b/src/identity/test/shared/fixtures/end-to-end.fixture.js.map deleted file mode 100644 index e2a6d65..0000000 --- a/src/identity/test/shared/fixtures/end-to-end.fixture.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"end-to-end.fixture.js","sourceRoot":"","sources":["end-to-end.fixture.ts"],"names":[],"mappings":";;;AAAA,wEAAmE;AAEnE,MAAa,mBAAoB,SAAQ,iDAAsB;CAAG;AAAlE,kDAAkE"} \ No newline at end of file diff --git a/src/identity/test/shared/fixtures/integration-test.fixture.d.ts b/src/identity/test/shared/fixtures/integration-test.fixture.d.ts deleted file mode 100644 index 9dd02a0..0000000 --- a/src/identity/test/shared/fixtures/integration-test.fixture.d.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { IUserRepository } from '../../../src/data/repositories/user.repository'; -import { INestApplication } from '@nestjs/common'; -import { IAuthRepository } from '../../../src/data/repositories/auth.repository'; -import { IRabbitmqConsumer } from 'building-blocks/rabbitmq/rabbitmq-subscriber'; -import { IRabbitmqPublisher } from 'building-blocks/rabbitmq/rabbitmq-publisher'; -import { CommandBus, QueryBus } from '@nestjs/cqrs'; -import { IRabbitmqConnection } from 'building-blocks/rabbitmq/rabbitmq-connection'; -import { StartedTestContainer } from 'testcontainers'; -export declare class Fixture { - userRepository: IUserRepository; - authRepository: IAuthRepository; - postgresContainer: StartedTestContainer; - rabbitmqContainer: StartedTestContainer; - rabbitmqConsumer: IRabbitmqConsumer; - rabbitmqConnection: IRabbitmqConnection; - rabbitmqPublisher: IRabbitmqPublisher; - commandBus: CommandBus; - queryBus: QueryBus; - app: INestApplication; -} -export declare class IntegrationTestFixture { - private fixture; - initializeFixture(): Promise; - cleanUp(): Promise; -} diff --git a/src/identity/test/shared/fixtures/integration-test.fixture.js b/src/identity/test/shared/fixtures/integration-test.fixture.js deleted file mode 100644 index e0c407c..0000000 --- a/src/identity/test/shared/fixtures/integration-test.fixture.js +++ /dev/null @@ -1,95 +0,0 @@ -"use strict"; -var __importDefault = (this && this.__importDefault) || function (mod) { - return (mod && mod.__esModule) ? mod : { "default": mod }; -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.IntegrationTestFixture = exports.Fixture = void 0; -const common_1 = require("@nestjs/common"); -const testing_1 = require("@nestjs/testing"); -const postgres_container_1 = require("building-blocks/test/container/postgres/postgres-container"); -const rabbitmq_container_1 = require("building-blocks/test/container/rabbitmq/rabbitmq-container"); -const cqrs_1 = require("@nestjs/cqrs"); -const passport_1 = require("@nestjs/passport"); -const jwt_1 = require("@nestjs/jwt"); -const configs_1 = __importDefault(require("building-blocks/configs/configs")); -const open_telemetry_module_1 = require("building-blocks/openTelemetry/open-telemetry.module"); -const typeorm_1 = require("@nestjs/typeorm"); -const user_module_1 = require("../../../src/user/user.module"); -const auth_module_1 = require("../../../src/auth/auth.module"); -const core_1 = require("@nestjs/core"); -const jwt_strategy_1 = require("building-blocks/passport/jwt.strategy"); -const jwt_guard_1 = require("building-blocks/passport/jwt.guard"); -class Fixture { - userRepository; - authRepository; - postgresContainer; - rabbitmqContainer; - rabbitmqConsumer; - rabbitmqConnection; - rabbitmqPublisher; - commandBus; - queryBus; - app; -} -exports.Fixture = Fixture; -class IntegrationTestFixture { - fixture = new Fixture(); - async initializeFixture() { - const [postgresContainer, postgresOptions] = await new postgres_container_1.PostgresContainer().start(); - this.fixture.postgresContainer = postgresContainer; - const [rabbitmqContainer, rabbitmqOptions] = await new rabbitmq_container_1.RabbitmqContainer().start(); - this.fixture.rabbitmqContainer = rabbitmqContainer; - const module = await testing_1.Test.createTestingModule({ - imports: [ - passport_1.PassportModule, - jwt_1.JwtModule.register({ - secret: configs_1.default.jwt.secret, - signOptions: { expiresIn: configs_1.default.jwt.refreshExpirationDays } - }), - open_telemetry_module_1.OpenTelemetryModule.forRoot(), - typeorm_1.TypeOrmModule.forRootAsync(postgresOptions), - user_module_1.UserModule, - auth_module_1.AuthModule, - core_1.RouterModule.register([ - { - path: '/', - module: user_module_1.UserModule - }, - { - path: '/', - module: auth_module_1.AuthModule - } - ]) - ], - providers: [jwt_strategy_1.JwtStrategy, cqrs_1.CommandBus, cqrs_1.QueryBus] - }) - .overrideGuard(jwt_guard_1.JwtGuard) - .useValue({ - canActivate: (context) => { - const req = context.switchToHttp().getRequest(); - req.user = { userId: 1, username: 'test_user' }; - return true; - } - }) - .compile(); - this.fixture.app = module.createNestApplication(); - this.fixture.app.setGlobalPrefix('api'); - this.fixture.app.enableVersioning({ - type: common_1.VersioningType.URI - }); - await this.fixture.app.init(); - this.fixture.userRepository = module.get('IUserRepository'); - this.fixture.authRepository = module.get('IAuthRepository'); - this.fixture.rabbitmqPublisher = module.get('IRabbitmqPublisher'); - this.fixture.rabbitmqConnection = module.get('IRabbitmqConnection'); - this.fixture.commandBus = module.get(cqrs_1.CommandBus); - this.fixture.queryBus = module.get(cqrs_1.QueryBus); - return this.fixture; - } - async cleanUp() { - await this.fixture.rabbitmqContainer.stop(); - await this.fixture.postgresContainer.stop(); - await this.fixture.app.close(); - } -} -exports.IntegrationTestFixture = IntegrationTestFixture; diff --git a/src/identity/test/shared/fixtures/integration-test.fixture.js.map b/src/identity/test/shared/fixtures/integration-test.fixture.js.map deleted file mode 100644 index 7e542fd..0000000 --- a/src/identity/test/shared/fixtures/integration-test.fixture.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"integration-test.fixture.js","sourceRoot":"","sources":["integration-test.fixture.ts"],"names":[],"mappings":";;;;;;AACA,2CAAoF;AACpF,6CAAsD;AACtD,mGAA+F;AAC/F,mGAA+F;AAI/F,uCAAoD;AACpD,+CAAkD;AAClD,qCAAwC;AACxC,8EAAsD;AACtD,+FAA0F;AAC1F,6CAAgD;AAChD,+DAA2D;AAC3D,+DAA2D;AAC3D,uCAA4C;AAC5C,wEAAoE;AACpE,kEAA8D;AAI9D,MAAa,OAAO;IAClB,cAAc,CAAkB;IAChC,cAAc,CAAkB;IAChC,iBAAiB,CAAuB;IACxC,iBAAiB,CAAuB;IACxC,gBAAgB,CAAoB;IACpC,kBAAkB,CAAsB;IACxC,iBAAiB,CAAqB;IACtC,UAAU,CAAa;IACvB,QAAQ,CAAW;IACnB,GAAG,CAAmB;CACvB;AAXD,0BAWC;AAED,MAAa,sBAAsB;IACzB,OAAO,GAAY,IAAI,OAAO,EAAE,CAAC;IAElC,KAAK,CAAC,iBAAiB;QAC5B,MAAM,CAAC,iBAAiB,EAAE,eAAe,CAAC,GAAG,MAAM,IAAI,sCAAiB,EAAE,CAAC,KAAK,EAAE,CAAC;QACnF,IAAI,CAAC,OAAO,CAAC,iBAAiB,GAAG,iBAAiB,CAAC;QAEnD,MAAM,CAAC,iBAAiB,EAAE,eAAe,CAAC,GAAG,MAAM,IAAI,sCAAiB,EAAE,CAAC,KAAK,EAAE,CAAC;QACnF,IAAI,CAAC,OAAO,CAAC,iBAAiB,GAAG,iBAAiB,CAAC;QAEnD,MAAM,MAAM,GAAkB,MAAM,cAAI,CAAC,mBAAmB,CAAC;YAC3D,OAAO,EAAE;gBACP,yBAAc;gB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,CAAC,GAAG,CAAkB,iBAAiB,CAAC,CAAC;QAC7E,IAAI,CAAC,OAAO,CAAC,cAAc,GAAG,MAAM,CAAC,GAAG,CAAkB,iBAAiB,CAAC,CAAC;QAE7E,IAAI,CAAC,OAAO,CAAC,iBAAiB,GAAG,MAAM,CAAC,GAAG,CAAqB,oBAAoB,CAAC,CAAC;QACtF,IAAI,CAAC,OAAO,CAAC,kBAAkB,GAAG,MAAM,CAAC,GAAG,CAAsB,qBAAqB,CAAC,CAAC;QAEzF,IAAI,CAAC,OAAO,CAAC,UAAU,GAAG,MAAM,CAAC,GAAG,CAAa,iBAAU,CAAC,CAAC;QAC7D,IAAI,CAAC,OAAO,CAAC,QAAQ,GAAG,MAAM,CAAC,GAAG,CAAW,eAAQ,CAAC,CAAC;QAEvD,OAAO,IAAI,CAAC,OAAO,CAAC;IACtB,CAAC;IAEM,KAAK,CAAC,OAAO;QAClB,MAAM,IAAI,CAAC,OAAO,CAAC,iBAAiB,CAAC,IAAI,EAAE,CAAC;QAC5C,MAAM,IAAI,CAAC,OAAO,CAAC,iBAAiB,CAAC,IAAI,EAAE,CAAC;QAE5C,MAAM,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,KAAK,EAAE,CAAC;IACjC,CAAC;CACF;AAxED,wDAwEC"} \ No newline at end of file diff --git a/src/identity/test/shared/fixtures/integration-test.fixture.ts b/src/identity/test/shared/fixtures/integration-test.fixture.ts index bd92381..3adfd55 100644 --- a/src/identity/test/shared/fixtures/integration-test.fixture.ts +++ b/src/identity/test/shared/fixtures/integration-test.fixture.ts @@ -1,108 +1,110 @@ -import { IUserRepository } from '../../../src/data/repositories/user.repository'; -import { ExecutionContext, INestApplication, VersioningType } from '@nestjs/common'; -import { Test, TestingModule } from '@nestjs/testing'; -import { PostgresContainer } from 'building-blocks/test/container/postgres/postgres-container'; -import { RabbitmqContainer } from 'building-blocks/test/container/rabbitmq/rabbitmq-container'; -import { IAuthRepository } from '../../../src/data/repositories/auth.repository'; -import { IRabbitmqConsumer } from 'building-blocks/rabbitmq/rabbitmq-subscriber'; -import { IRabbitmqPublisher } from 'building-blocks/rabbitmq/rabbitmq-publisher'; -import { CommandBus, QueryBus } from '@nestjs/cqrs'; -import { PassportModule } from '@nestjs/passport'; -import { JwtModule } from '@nestjs/jwt'; +import {IUserRepository} from '../../../src/data/repositories/user.repository'; +import {ExecutionContext, INestApplication, VersioningType} from '@nestjs/common'; +import {Test, TestingModule} from '@nestjs/testing'; +import {PostgresContainer} from 'building-blocks/test/container/postgres/postgres-container'; +import {RabbitmqContainer} from 'building-blocks/test/container/rabbitmq/rabbitmq-container'; +import {IAuthRepository} from '../../../src/data/repositories/auth.repository'; +import {IRabbitmqConsumer} from 'building-blocks/rabbitmq/rabbitmq-subscriber'; +import {IRabbitmqPublisher} from 'building-blocks/rabbitmq/rabbitmq-publisher'; +import {CommandBus, QueryBus} from '@nestjs/cqrs'; +import {PassportModule} from '@nestjs/passport'; +import {JwtModule} from '@nestjs/jwt'; import configs from 'building-blocks/configs/configs'; -import { OpenTelemetryModule } from 'building-blocks/openTelemetry/open-telemetry.module'; -import { TypeOrmModule } from '@nestjs/typeorm'; -import { UserModule } from '../../../src/user/user.module'; -import { AuthModule } from '../../../src/auth/auth.module'; -import { RouterModule } from '@nestjs/core'; -import { JwtStrategy } from 'building-blocks/passport/jwt.strategy'; -import { JwtGuard } from 'building-blocks/passport/jwt.guard'; -import { IRabbitmqConnection } from 'building-blocks/rabbitmq/rabbitmq-connection'; -import { StartedTestContainer } from 'testcontainers'; +import {OpenTelemetryModule} from 'building-blocks/openTelemetry/open-telemetry.module'; +import {TypeOrmModule} from '@nestjs/typeorm'; +import {UserModule} from '../../../src/user/user.module'; +import {AuthModule} from '../../../src/auth/auth.module'; +import {RouterModule} from '@nestjs/core'; +import {JwtStrategy} from 'building-blocks/passport/jwt.strategy'; +import {JwtGuard} from 'building-blocks/passport/jwt.guard'; +import {IRabbitmqConnection} from 'building-blocks/rabbitmq/rabbitmq-connection'; +import {StartedTestContainer} from 'testcontainers'; +import {TypeOrmModuleOptions} from "@nestjs/typeorm/dist/interfaces/typeorm-options.interface"; export class Fixture { - userRepository: IUserRepository; - authRepository: IAuthRepository; - postgresContainer: StartedTestContainer; - rabbitmqContainer: StartedTestContainer; - rabbitmqConsumer: IRabbitmqConsumer; - rabbitmqConnection: IRabbitmqConnection; - rabbitmqPublisher: IRabbitmqPublisher; - commandBus: CommandBus; - queryBus: QueryBus; - app: INestApplication; + userRepository: IUserRepository; + authRepository: IAuthRepository; + postgresContainer: StartedTestContainer; + rabbitmqContainer: StartedTestContainer; + rabbitmqConsumer: IRabbitmqConsumer; + rabbitmqConnection: IRabbitmqConnection; + rabbitmqPublisher: IRabbitmqPublisher; + commandBus: CommandBus; + queryBus: QueryBus; + app: INestApplication; } export class IntegrationTestFixture { - private fixture: Fixture = new Fixture(); - - public async initializeFixture(): Promise { - const [postgresContainer, postgresOptions] = await new PostgresContainer().start(); - this.fixture.postgresContainer = postgresContainer; - - const [rabbitmqContainer, rabbitmqOptions] = await new RabbitmqContainer().start(); - this.fixture.rabbitmqContainer = rabbitmqContainer; - - const module: TestingModule = await Test.createTestingModule({ - imports: [ - PassportModule, - JwtModule.register({ - secret: configs.jwt.secret, - signOptions: { expiresIn: configs.jwt.refreshExpirationDays } - }), - OpenTelemetryModule.forRoot(), - TypeOrmModule.forRootAsync(postgresOptions), - UserModule, - AuthModule, - RouterModule.register([ - { - path: '/', - module: UserModule - }, - { - path: '/', - module: AuthModule - } - ]) - ], - providers: [JwtStrategy, CommandBus, QueryBus] - }) - .overrideGuard(JwtGuard) - .useValue({ - canActivate: (context: ExecutionContext) => { - const req = context.switchToHttp().getRequest(); - req.user = { userId: 1, username: 'test_user' }; - return true; - } - }) - .compile(); - - this.fixture.app = module.createNestApplication(); - - this.fixture.app.setGlobalPrefix('api'); - - this.fixture.app.enableVersioning({ - type: VersioningType.URI - }); - - await this.fixture.app.init(); - - this.fixture.userRepository = module.get('IUserRepository'); - this.fixture.authRepository = module.get('IAuthRepository'); - - this.fixture.rabbitmqPublisher = module.get('IRabbitmqPublisher'); - this.fixture.rabbitmqConnection = module.get('IRabbitmqConnection'); - - this.fixture.commandBus = module.get(CommandBus); - this.fixture.queryBus = module.get(QueryBus); - - return this.fixture; - } - - public async cleanUp() { - await this.fixture.rabbitmqContainer.stop(); - await this.fixture.postgresContainer.stop(); - - await this.fixture.app.close(); - } + private fixture: Fixture = new Fixture(); + + public async initializeFixture(): Promise { + const [postgresContainer, postgresOptions] = await new PostgresContainer().start(); + this.fixture.postgresContainer = postgresContainer; + + const [rabbitmqContainer, rabbitmqOptions] = await new RabbitmqContainer().start(); + this.fixture.rabbitmqContainer = rabbitmqContainer; + + const module: TestingModule = await Test.createTestingModule({ + imports: [ + PassportModule, + JwtModule.register({ + secret: configs.jwt.secret, + signOptions: {expiresIn: configs.jwt.refreshExpirationDays} + }), + OpenTelemetryModule.forRoot(), + TypeOrmModule.forRoot(postgresOptions as TypeOrmModuleOptions), + UserModule, + AuthModule, + RouterModule.register([ + { + path: '/', + module: UserModule + }, + { + path: '/', + module: AuthModule + } + ]) + ], + providers: [JwtStrategy, CommandBus, QueryBus] + }) + .overrideGuard(JwtGuard) + .useValue({ + canActivate: (context: ExecutionContext) => { + const req = context.switchToHttp().getRequest(); + req.user = {userId: 1, username: 'test_user'}; + return true; + } + }) + .compile(); + + this.fixture.app = module.createNestApplication(); + + this.fixture.app.setGlobalPrefix('api'); + + this.fixture.app.enableVersioning({ + type: VersioningType.URI + }); + + await this.fixture.app.init(); + + this.fixture.userRepository = module.get('IUserRepository'); + this.fixture.authRepository = module.get('IAuthRepository'); + + this.fixture.rabbitmqPublisher = module.get('IRabbitmqPublisher'); + this.fixture.rabbitmqConnection = module.get('IRabbitmqConnection'); + + this.fixture.commandBus = module.get(CommandBus); + this.fixture.queryBus = module.get(QueryBus); + + return this.fixture; + } + + public async cleanUp() { + + await this.fixture.rabbitmqContainer.stop(); + await this.fixture.postgresContainer.stop(); + + await this.fixture.app.close(); + } }