You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

@titicaca/ecs-dd-trace

Package Overview
Dependencies
Maintainers
57
Versions
36
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install
Package was removed
Sorry, it seems this package was removed from the registry

@titicaca/ecs-dd-trace

Dadadog trace library for Node.js services on ECS

4.0.0
unpublished
latest
Source
npmnpm
Version published
Maintainers
57
Created
Source

ECS-DD-TRACE

ECS 에서만 사용할 수 있는 Node.js Datadog Monitoring Library 입니다.

지원하는 기능은 APM 측정과 Metric 측정입니다.

Install

Dependency 에 추가해주세요.

$ npm install @titicaca/ecs-dd-trace

APM

APM 기능은 node.js 가 시작할 때 start script 에 넣어주면 자동으로 APM 을 수집합니다.

ENABLE_DD_APM 환경 변수에 true 를 넣어줍니다.

package.json 의 scripts 를 수정해 줍니다. --require @titicaca/ecs-dd-trace

{
  "scripts": {
    "start": "NODE_ENV=production node --require @titicaca/ecs-dd-trace dist"
  }
}

PREVENT_PARAMETERIZED_ROUTE_PATH

PREVENT_PARAMETERIZED_ROUTE_PATH 환경 변수에 true 를 넣어줄 경우 동작합니다.

GET /users/{user_id} 와 같이 dynamic path routing API 를 사용할 경우 Datadog APM 에서는 통일된 API로 처리하지만 이것을 분리하여 보여주고 싶은 요구사항을 해결할 때 사용합니다.

Metric

Metric 은 원하는 지표를 카운트 할 수 있는 기능입니다.

ENABLE_DD_METRIC 환경 변수에 true 를 넣어줍니다.

사용법

const metricClient = await MetricClient.init()
await increaseMetricCount('campaign_api.test')

환경 변수

ECS 에서 동작하는 모든 컨테이너에는 ECS_CONTAINER_METADATA_URI_V4 환경 변수가 있습니다.

FAQs

Package last updated on 09 Aug 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts