Skip to content

Commit

Permalink
chore: add OTel and Jaeger start scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
NeuralFlux committed Sep 12, 2024
1 parent 9f7ab80 commit 9a6d8e2
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 2 deletions.
28 changes: 27 additions & 1 deletion .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,32 @@
],
"stopOnEntry": true,
"console": "integratedTerminal"
}
},
{
"name": "Build w/ Cache and Jaeger",
"type": "pwa-node",
"preLaunchTask": "start redis",
"runtimeArgs": [
"run",
"debug-otel",
],
"cwd": "${workspaceFolder}",
"runtimeExecutable": "pnpm",
"restart": false,
"env": {
"REDIS_HOST": "localhost",
"REDIS_PORT": "6379",
"DEBUG": "biomedical-id-resolver,bte*",
"SMARTAPI_SYNC": "false",
"RESULT_CACHING": "true",
"OTEL_EXPORTER_OTLP_ENDPOINT": "http://localhost:4318",
},
"request": "launch",
"skipFiles": [
"<node_internals>/**"
],
"stopOnEntry": true,
"console": "integratedTerminal"
},
]
}
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,9 @@
"start": "./scripts/start_server.sh",
"stop": "./scripts/stop_server.sh",
"watch": "nodemon -e js,mjs,json,ts --watch './packages/**/src/*' './packages/**/data/*' --exec 'pnpm run build && node .'",
"debug": "DEBUG=biomedical-id-resolver,bte* pnpm run watch"
"watch-otel": "nodemon -e js,mjs,json,ts --watch './packages/**/src/*' './packages/**/data/*' --exec 'pnpm run build && node --require ./packages/bte-server/built/controllers/opentelemetry.js .'",
"debug": "DEBUG=biomedical-id-resolver,bte* pnpm run watch",
"debug-otel": "DEBUG=biomedical-id-resolver,bte* pnpm run watch-otel"
},
"engines": {
"node": ">=18.0.0",
Expand Down

0 comments on commit 9a6d8e2

Please sign in to comment.