@yolo-croket-dev/core 1.7.4-datadog.8 → 1.7.4-datadog.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -157,7 +157,7 @@ let LoggingServiceInterceptor = class LoggingServiceInterceptor {
157
157
  }));
158
158
  }
159
159
  };
160
- LoggingServiceInterceptor = __decorate([
160
+ exports.LoggingServiceInterceptor = LoggingServiceInterceptor;
161
+ exports.LoggingServiceInterceptor = LoggingServiceInterceptor = __decorate([
161
162
  (0, common_1.Injectable)()
162
163
  ], LoggingServiceInterceptor);
163
- exports.LoggingServiceInterceptor = LoggingServiceInterceptor;
@@ -31,9 +31,6 @@ var __importStar = (this && this.__importStar) || function (mod) {
31
31
  var __metadata = (this && this.__metadata) || function (k, v) {
32
32
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
33
33
  };
34
- var __importDefault = (this && this.__importDefault) || function (mod) {
35
- return (mod && mod.__esModule) ? mod : { "default": mod };
36
- };
37
34
  Object.defineProperty(exports, "__esModule", { value: true });
38
35
  exports.RPCInterceptor = void 0;
39
36
  /* eslint-disable @typescript-eslint/no-explicit-any */
@@ -43,7 +40,6 @@ const core_1 = require("@nestjs/core");
43
40
  const rxjs_1 = require("rxjs");
44
41
  const operators_1 = require("rxjs/operators");
45
42
  const msa_logger_1 = __importStar(require("@yolo-croket-dev/msa-logger"));
46
- const dd_trace_1 = __importDefault(require("dd-trace"));
47
43
  // import Logger from '@yolo-croket-dev/logger';
48
44
  const functions_1 = require("../functions");
49
45
  const exceptions_1 = require("../exceptions");
@@ -194,22 +190,6 @@ let RPCInterceptor = class RPCInterceptor {
194
190
  const errInfo = err.errInfo;
195
191
  const duration = Date.now() - now;
196
192
  let isAck = false;
197
- if (process.env.DD_AGENT_HOST && process.env.DD_AGENT_HOST.startsWith('datadog-agent-agent')) {
198
- const span = dd_trace_1.default.scope().active();
199
- if (span) {
200
- msaLogger.debug('Active span found', { traceId: 'ACTIVE_SPAN_FOUND' }, { err: { message: errMsg, stack: err.stack ? err.stack : null }, DD_AGENT_HOST: process.env.DD_AGENT_HOST });
201
- span.setTag('error', {
202
- message: errMsg,
203
- stack: err.stack ? err.stack : null,
204
- type: 'RpcExceptionsHandler',
205
- });
206
- span.finish();
207
- msaLogger.debug('Active span found', { traceId: 'ACTIVE_SPAN_FOUND2' }, { err: { message: errMsg, stack: err.stack ? err.stack : null }, DD_AGENT_HOST: process.env.DD_AGENT_HOST });
208
- }
209
- else {
210
- msaLogger.error('No active span found', { traceId: 'NO_ACTIVE_SPAN' });
211
- }
212
- }
213
193
  /** 파일 객체 처리 */
214
194
  (0, functions_1.reWriteFileValue)(arg === null || arg === void 0 ? void 0 : arg.file);
215
195
  const abstractAmqpHandlerData = {
@@ -254,6 +234,7 @@ let RPCInterceptor = class RPCInterceptor {
254
234
  const messageContent = message.content.toString();
255
235
  /** 파일 객체 처리 */
256
236
  (0, functions_1.reWriteFileValue)((_a = messageContent === null || messageContent === void 0 ? void 0 : messageContent.data) === null || _a === void 0 ? void 0 : _a.file);
237
+ msaLogger.traceError('RPCException error', { traceId: execInterceptor.traceId }, { error: { message: errMsg, stack: err.stack ? err.stack : '', type: 'RpcExceptionsHandler' } });
257
238
  // logger.debug(`<= (error:${traceId}): ${JSON.stringify(sendMessage.toString())}`, {
258
239
  // ...logParam,
259
240
  // duration,
@@ -324,9 +305,9 @@ let RPCInterceptor = class RPCInterceptor {
324
305
  }));
325
306
  }
326
307
  };
327
- RPCInterceptor = __decorate([
308
+ exports.RPCInterceptor = RPCInterceptor;
309
+ exports.RPCInterceptor = RPCInterceptor = __decorate([
328
310
  (0, common_1.Injectable)(),
329
311
  __metadata("design:paramtypes", [core_1.Reflector,
330
312
  graceful_shutdown_service_1.GracefulShutdownService])
331
313
  ], RPCInterceptor);
332
- exports.RPCInterceptor = RPCInterceptor;
@@ -18,9 +18,10 @@ var ErrActionTypeEnum;
18
18
  ErrActionTypeEnum["LEGACY_SHOW_TOAST"] = "LEGACY_SHOW_TOAST";
19
19
  ErrActionTypeEnum["FORCE_UPDATE"] = "FORCE_UPDATE";
20
20
  ErrActionTypeEnum["UPDATE_ACCESS_TOKEN"] = "UPDATE_ACCESS_TOKEN";
21
- })(ErrActionTypeEnum = exports.ErrActionTypeEnum || (exports.ErrActionTypeEnum = {}));
21
+ })(ErrActionTypeEnum || (exports.ErrActionTypeEnum = ErrActionTypeEnum = {}));
22
22
  class ErrAction {
23
23
  }
24
+ exports.ErrAction = ErrAction;
24
25
  __decorate([
25
26
  (0, swagger_1.ApiProperty)({
26
27
  description: '액션 타입',
@@ -57,9 +58,9 @@ __decorate([
57
58
  }),
58
59
  __metadata("design:type", String)
59
60
  ], ErrAction.prototype, "webViewUrl", void 0);
60
- exports.ErrAction = ErrAction;
61
61
  class ErrInfo {
62
62
  }
63
+ exports.ErrInfo = ErrInfo;
63
64
  __decorate([
64
65
  (0, swagger_1.ApiProperty)({
65
66
  description: '에러 종류 식별자',
@@ -81,4 +82,3 @@ __decorate([
81
82
  }),
82
83
  __metadata("design:type", ErrAction)
83
84
  ], ErrInfo.prototype, "action", void 0);
84
- exports.ErrInfo = ErrInfo;
@@ -11,11 +11,11 @@ const common_1 = require("@nestjs/common");
11
11
  const graceful_shutdown_service_1 = require("./graceful-shutdown.service");
12
12
  let GracefulShutdownModule = class GracefulShutdownModule {
13
13
  };
14
- GracefulShutdownModule = __decorate([
14
+ exports.GracefulShutdownModule = GracefulShutdownModule;
15
+ exports.GracefulShutdownModule = GracefulShutdownModule = __decorate([
15
16
  (0, common_1.Global)(),
16
17
  (0, common_1.Module)({
17
18
  providers: [graceful_shutdown_service_1.GracefulShutdownService],
18
19
  exports: [graceful_shutdown_service_1.GracefulShutdownService],
19
20
  })
20
21
  ], GracefulShutdownModule);
21
- exports.GracefulShutdownModule = GracefulShutdownModule;
@@ -1,7 +1,7 @@
1
1
  import { RmqOptions, ServerRMQ } from '@nestjs/microservices';
2
2
  import { Channel } from 'amqp-connection-manager';
3
3
  import { ConsumeMessage } from 'amqplib';
4
- export declare type GracefulRmqOptions = RmqOptions['options'] & {
4
+ export type GracefulRmqOptions = RmqOptions['options'] & {
5
5
  waitingEndingHandlersTimeoutMs?: number;
6
6
  waitingEndingHandlersIntervalMs?: number;
7
7
  };
@@ -88,7 +88,7 @@ let GracefulShutdownService = class GracefulShutdownService {
88
88
  }
89
89
  }
90
90
  };
91
- GracefulShutdownService = __decorate([
91
+ exports.GracefulShutdownService = GracefulShutdownService;
92
+ exports.GracefulShutdownService = GracefulShutdownService = __decorate([
92
93
  (0, common_1.Injectable)()
93
94
  ], GracefulShutdownService);
94
- exports.GracefulShutdownService = GracefulShutdownService;
@@ -15,10 +15,10 @@ const redisProvider = {
15
15
  };
16
16
  let RedisModule = class RedisModule {
17
17
  };
18
- RedisModule = __decorate([
18
+ exports.RedisModule = RedisModule;
19
+ exports.RedisModule = RedisModule = __decorate([
19
20
  (0, common_1.Module)({
20
21
  providers: [redisProvider],
21
22
  exports: [redisProvider],
22
23
  })
23
24
  ], RedisModule);
24
- exports.RedisModule = RedisModule;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yolo-croket-dev/core",
3
- "version": "1.7.4-datadog.8",
3
+ "version": "1.7.4-datadog.9",
4
4
  "author": "Yolo Co., Ltd.",
5
5
  "description": "Yolo commonization module",
6
6
  "main": "index.js",
@@ -17,7 +17,7 @@
17
17
  "@nestjs/common": "^8.2.3",
18
18
  "@nestjs/microservices": "9.0.8",
19
19
  "@yolo-croket-dev/logger": "^1.0.15",
20
- "@yolo-croket-dev/msa-logger": "^3.0.1",
20
+ "@yolo-croket-dev/msa-logger": "3.0.2-datadog.0",
21
21
  "@yolo-croket-dev/redis": "^1.0.23",
22
22
  "@yolo-croket-dev/swagger": "^0.0.7",
23
23
  "axios": "^1.1.3",
@@ -28,7 +28,6 @@
28
28
  "devDependencies": {
29
29
  "@types/node": "^16.11.9",
30
30
  "@types/randomstring": "^1.1.8",
31
- "@types/uuid": "^8.3.4",
32
- "dd-trace": "^5.25.0"
31
+ "@types/uuid": "^8.3.4"
33
32
  }
34
33
  }
@@ -31,8 +31,8 @@ let ValidationPipe = class ValidationPipe {
31
31
  return value;
32
32
  }
33
33
  };
34
- ValidationPipe = __decorate([
34
+ exports.ValidationPipe = ValidationPipe;
35
+ exports.ValidationPipe = ValidationPipe = __decorate([
35
36
  (0, common_1.Injectable)(),
36
37
  __metadata("design:paramtypes", [Object])
37
38
  ], ValidationPipe);
38
- exports.ValidationPipe = ValidationPipe;