https://github.com/lambtron/otel-deno-node
Showing how to instrument OTEL in Deno and Node projects.
https://github.com/lambtron/otel-deno-node
deno grafana loki nodejs otel tempo
Last synced: 2 months ago
JSON representation
Showing how to instrument OTEL in Deno and Node projects.
- Host: GitHub
- URL: https://github.com/lambtron/otel-deno-node
- Owner: lambtron
- License: mit
- Created: 2025-03-06T22:27:20.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-03-13T16:18:21.000Z (over 1 year ago)
- Last Synced: 2025-06-06T05:02:48.781Z (about 1 year ago)
- Topics: deno, grafana, loki, nodejs, otel, tempo
- Language: JavaScript
- Homepage: https://deno.com/blog/otel-tracing-in-node-and-deno
- Size: 138 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# OTEL in Deno vs. Node
This project is accompanied by the blog post
["How to get deep traces in your Node.js backend with OTel and Deno"](https://deno.com/blog/otel-tracing-in-node-and-deno).
## Node
In `./node-express-otel`,
Run the app:
```bash
npm run start
```
Run OTEL LGTM stack:
```bash
docker run --name lgtm -p 3000:3000 -p 4317:4317 -p 4318:4318 --rm -ti \
-v "$PWD"/lgtm/grafana:/data/grafana \
-v "$PWD"/lgtm/prometheus:/data/prometheus \
-v "$PWD"/lgtm/loki:/data/loki \
-e GF_PATHS_DATA=/data/grafana \
docker.io/grafana/otel-lgtm:0.8.1
```
Go to `localhost:3000` to view Grafana.
## Deno
In `./deno-express`:
Run the app:
```bash
# Run app without sending OTEL data
deno task start
# Run app sending OTEL data
deno task otel
```
Run OTEL LGTM stack:
```bash
docker run --name lgtm -p 3000:3000 -p 4317:4317 -p 4318:4318 --rm -ti \
-v "$PWD"/lgtm/grafana:/data/grafana \
-v "$PWD"/lgtm/prometheus:/data/prometheus \
-v "$PWD"/lgtm/loki:/data/loki \
-e GF_PATHS_DATA=/data/grafana \
docker.io/grafana/otel-lgtm:0.8.1
```
Go to `localhost:3000` to view Grafana.