forge
Explore
Log in

Don't you dare go Hollow

OpenObserve replaces Temps as the telemetry sink

Browse files at this commit

5a1ac4253afbd18dc827ec662a15d4f5f47c5ec7Ahmet Kaan GümüşParent: 66c56ad
  • feat
    • OpenObserve replaces Temps as the telemetry sink
Show full message
✨ feat: OpenObserve replaces Temps as the telemetry sink

Temps needed a container socket to even start its console, plus a
TimescaleDB and a ClickHouse of its own — three services, a locally
built image and a socket mount for one dev sink. OpenObserve is one
Rust binary with its own storage: no socket, no sidecars, retention
per stream in days.

compose.yaml drops temps/temps-postgres/temps-clickhouse and their
volumes for a single `openobserve` service on
docker.io/openobserve/openobserve:v1.0.0-rc2, UI + API + OTLP/HTTP on
127.0.0.1:5080 and OTLP/gRPC on 127.0.0.1:5081, ZO_DATA_DIR=/data on
the openobserve-data volume, ZO_COMPACT_DATA_RETENTION_DAYS=90, root
user admin@hezarfen.local (local-dev password, and OpenObserve panics
at boot on anything weaker than upper+lower+digit+special). The
backend's commented OTEL_* block now carries the gRPC form ready to
uncomment and the OTLP/HTTP variant beside it.

Proved end to end against the real backend over OTLP/gRPC: 18 spans
(GET /health ×11, GET /modules/catalog ×5, POST /builder/login,
GET unmatched), the http_server_request_duration metric family and 11
log records, all timestamped 2026-09-07 rather than 1970. Privacy
check over every span and log attribute key found none of the banned
set (url.path, client.address, user_agent.original, user.*, cookie,
email, http.*.header.*); no username and no IP but 127.0.0.1 in any
body.

Claude-Session: https://claude.ai/code/session_018sqvyBCZ9kpQP6vnGomT2s
README.mdmodified+14 -16
@@ -240,22 +240,20 @@ container so the published port works. Production knobs (`COOKIE_SECURE`,
240 means dev mirror mode without credentials; a cookie-using browser frontend240 means dev mirror mode without credentials; a cookie-using browser frontend
241 must be allowlisted explicitly. Works with `docker compose` too.241 must be allowlisted explicitly. Works with `docker compose` too.
242 242
243-Three more services make up the telemetry sink: `temps` (UI and API on243+One more service is the telemetry sink: `openobserve`, a single Rust binary
244-`127.0.0.1:3000`, OTLP ingest on `127.0.0.1:9000`) with its TimescaleDB and244+that stores logs, metrics and traces itself — no sidecar databases and no
245-ClickHouse stores. Its image is built locally from245+container socket. Its UI, search API and OTLP/HTTP ingest share
246-`observability/Containerfile.temps` — the published one is tagged alpine but246+`127.0.0.1:5080`; OTLP/gRPC listens on `127.0.0.1:5081`. Log in at
247-ships a glibc binary that cannot exec. Temps refuses to start its console247+http://127.0.0.1:5080 as the `ZO_ROOT_USER_EMAIL`/`ZO_ROOT_USER_PASSWORD` pair
248-without a container socket, so `systemctl --user start podman.socket` first.248+set on the service (`admin@hezarfen.local` / `Hezarfen_dev1!` for local dev —
249-Log in at http://127.0.0.1:3000 as `admin@hezarfen.local` with the password in249+OpenObserve rejects a weaker password at boot). Retention is per stream in
250-`observability/temps-admin-password`, then mint an ingest key (Settings → API250+days, defaulted globally to 90 by `ZO_COMPACT_DATA_RETENTION_DAYS`. Uncomment
251-Keys, or `podman exec hezarfen-temps temps api-key --name <name>`) and note the251+the backend's `OTEL_EXPORTER_OTLP_ENDPOINT` (`http://openobserve:5081`) and
252-project id shown on the project page. Uncomment the backend's252+`OTEL_EXPORTER_OTLP_HEADERS` (`Authorization=Basic <base64 email:password>`
253-`OTEL_EXPORTER_OTLP_ENDPOINT` (`http://temps:9000/api/otel`),253+plus `organization=default,stream-name=default`), and traces, metrics and logs
254-`OTEL_EXPORTER_OTLP_PROTOCOL` (`http/protobuf` — Temps has no gRPC listener)254+start landing; the commented OTLP/HTTP variant uses
255-and `OTEL_EXPORTER_OTLP_HEADERS`255+`http://openobserve:5080/api/default` with `OTEL_EXPORTER_OTLP_PROTOCOL:
256-(`Authorization=Bearer <key>,X-Temps-Project-Id=<id>`), and traces, metrics and256+http/protobuf` instead.
257-logs start landing. Signals are kept 90 days
258-(`TEMPS_OTEL_RETENTION_DAYS`).
259 257
260 The backend survives the database going away, at boot and at runtime.258 The backend survives the database going away, at boot and at runtime.
261 259
compose.yamlmodified+42 -118
@@ -58,16 +58,18 @@ services:
58 # RATE_LIMIT_AUTH_PER_MINUTE: "10"58 # RATE_LIMIT_AUTH_PER_MINUTE: "10"
59 # RATE_LIMIT_API_PER_MINUTE: "300"59 # RATE_LIMIT_API_PER_MINUTE: "300"
60 # TRUST_PROXY: "true"60 # TRUST_PROXY: "true"
61- # Telemetry — export traces, metrics and logs to Temps over OTLP/HTTP.61+ # Telemetry — export traces, metrics and logs to OpenObserve over OTLP.
62- # Uncomment once a Temps project exists: create the project in the UI at62+ # The Authorization value is base64("<ZO_ROOT_USER_EMAIL>:<password>");
63- # http://127.0.0.1:3000, mint an API key (tk_...) under Settings > API63+ # for the local-dev pair above that is the string below. gRPC carries the
64- # Keys, and put its numeric project id in the header. OTLP/HTTP protobuf64+ # organization and the target stream as metadata headers.
65- # only — Temps has no gRPC port, and the ingest path is /api/otel/v1/*,65+ # OTEL_EXPORTER_OTLP_ENDPOINT: http://openobserve:5081
66- # so the endpoint carries the /api/otel prefix.66+ # OTEL_EXPORTER_OTLP_HEADERS: "Authorization=Basic YWRtaW5AaGV6YXJmZW4ubG9jYWw6SGV6YXJmZW5fZGV2MSE=,organization=default,stream-name=default"
67- # OTEL_EXPORTER_OTLP_ENDPOINT: http://temps:9000/api/otel
68- # OTEL_EXPORTER_OTLP_PROTOCOL: http/protobuf
69- # OTEL_EXPORTER_OTLP_HEADERS: "Authorization=Bearer tk_xxx,X-Temps-Project-Id=1"
70 # OTEL_SERVICE_NAME: hezarfen-backend67 # OTEL_SERVICE_NAME: hezarfen-backend
68+ # OTLP/HTTP instead: the org goes in the path (the SDK appends
69+ # /v1/{traces,metrics,logs}) and only Authorization is needed.
70+ # OTEL_EXPORTER_OTLP_ENDPOINT: http://openobserve:5080/api/default
71+ # OTEL_EXPORTER_OTLP_PROTOCOL: http/protobuf
72+ # OTEL_EXPORTER_OTLP_HEADERS: "Authorization=Basic YWRtaW5AaGV6YXJmZW4ubG9jYWw6SGV6YXJmZW5fZGV2MSE="
71 # AI bridge — the AI services dial IN over QUIC. Unset means off; a73 # AI bridge — the AI services dial IN over QUIC. Unset means off; a
72 # bad address or a missing token fails the boot rather than leaving a74 # bad address or a missing token fails the boot rather than leaving a
73 # silently dead feature. Listening with no service connected is fine:75 # silently dead feature. Listening with no service connected is fine:
@@ -91,123 +93,45 @@ services:
91 start_period: 10s93 start_period: 10s
92 94
93 # ── Telemetry sink ────────────────────────────────────────────────────────95 # ── Telemetry sink ────────────────────────────────────────────────────────
94- # Temps is the only telemetry sink (no Grafana/Jaeger/Loki). It stores96+ # OpenObserve is the only telemetry sink (no Grafana/Jaeger/Loki): one Rust
95- # metadata in TimescaleDB and the OTLP signals themselves in ClickHouse, so97+ # binary, its own storage, no container socket and no sidecar databases. It
96- # both come along. Neither database is published to the host; only the Temps98+ # speaks OTLP itself — HTTP on 5080 (also the UI and the search API), gRPC on
97- # API/UI (3000) and its public ingest listener (9000) are, on loopback.99+ # 5081. Both are published on loopback only.
98- temps-postgres:100+ openobserve:
99- image: docker.io/gotempsh/timescaledb-walg:pg18101+ image: docker.io/openobserve/openobserve:v1.0.0-rc2
100- container_name: hezarfen-temps-postgres102+ container_name: hezarfen-openobserve
101- environment:
102- POSTGRES_DB: temps
103- POSTGRES_USER: temps
104- # Local-dev credential, same status as the root/root above. Never leaves
105- # the compose network — the port is not published.
106- POSTGRES_PASSWORD: temps_local_dev
107- TIMESCALEDB_TELEMETRY: off
108- volumes:
109- # Spilo/timescaledb-ha initialises its cluster here, not in the stock
110- # postgres image's /var/lib/postgresql/data. Mounting the wrong path
111- # loses everything on every recreation.
112- - temps-postgres-data:/home/postgres/pgdata/data
113- restart: unless-stopped
114- healthcheck:
115- test:
116- [
117- "CMD-SHELL",
118- "PGPASSWORD=$$POSTGRES_PASSWORD psql -h 127.0.0.1 -U temps -d temps -tAc 'SELECT 1' | grep -qx 1",
119- ]
120- interval: 10s
121- timeout: 5s
122- retries: 12
123- start_period: 30s
124-
125- temps-clickhouse:
126- image: docker.io/clickhouse/clickhouse-server:26.7.5.10-alpine
127- container_name: hezarfen-temps-clickhouse
128- environment:
129- CLICKHOUSE_DB: temps
130- CLICKHOUSE_USER: temps
131- CLICKHOUSE_PASSWORD: temps_local_dev
132- volumes:
133- - temps-clickhouse-data:/var/lib/clickhouse
134- ulimits:
135- nofile:
136- soft: 262144
137- hard: 262144
138- restart: unless-stopped
139- healthcheck:
140- test: ["CMD", "clickhouse-client", "--user", "temps", "--database", "temps", "--query", "SELECT 1"]
141- interval: 10s
142- timeout: 5s
143- retries: 12
144- start_period: 20s
145-
146- temps:
147- # Built locally from the pinned upstream artifact — see
148- # observability/Containerfile.temps for why the published image can't run.
149- build:
150- context: ./observability
151- dockerfile: Containerfile.temps
152- image: localhost/hezarfen-temps:0.1.0-nightly.20260906.48c2396e
153- container_name: hezarfen-temps
154 environment:103 environment:
155- TEMPS_DATABASE_URL: postgresql://temps:temps_local_dev@temps-postgres:5432/temps104+ # First-boot root account, created once. Local-dev credentials, same
156- # UI + API on 3000, public ingest (OTLP among it) on 9000.105+ # status as the root/root above — change them before this is reachable
157- TEMPS_ADDRESS: 0.0.0.0:3000106+ # from anywhere but your machine. OpenObserve enforces a password policy
158- TEMPS_CONSOLE_ADDRESS: 0.0.0.0:9000107+ # (8-128 chars, upper + lower + digit + special) and panics on boot
159- TEMPS_DATA_DIR: /app/data108+ # otherwise, hence the shape of this one.
160- TEMPS_LOG_LEVEL: info109+ ZO_ROOT_USER_EMAIL: admin@hezarfen.local
161- TEMPS_CLICKHOUSE_URL: http://temps-clickhouse:8123110+ ZO_ROOT_USER_PASSWORD: Hezarfen_dev1!
162- TEMPS_CLICKHOUSE_DATABASE: temps111+ ZO_DATA_DIR: /data
163- TEMPS_CLICKHOUSE_USER: temps112+ # Retention is per stream in days; this is the global default applied to
164- TEMPS_CLICKHOUSE_PASSWORD: temps_local_dev113+ # streams that don't override it (upstream default is 3650).
165- # Signal retention. 90 is also Temps' own default (the spans table's114+ ZO_COMPACT_DATA_RETENTION_DAYS: "90"
166- # `retention_days` column defaults to 90 and the TTL is derived from it),
167- # set here so the number is in the file rather than only in Temps' own
168- # settings row, which the console can change.
169- TEMPS_OTEL_RETENTION_DAYS: "90"
170- # First-boot admin, created once. The password is mounted from a file so
171- # it stays out of argv; change observability/temps-admin-password before
172- # this is reachable from anywhere but your machine.
173- TEMPS_ADMIN_EMAIL: admin@hezarfen.local
174- TEMPS_ADMIN_PASSWORD_FILE: /run/temps/admin_password
175- TEMPS_EXECUTION_ENV: docker
176 ports:115 ports:
177- - "127.0.0.1:3000:3000"116+ - "127.0.0.1:5080:5080"
178- - "127.0.0.1:9000:9000"117+ - "127.0.0.1:5081:5081"
179 volumes:118 volumes:
180- - temps-data:/app/data119+ - openobserve-data:/data
181- - ./observability/temps-admin-password:/run/temps/admin_password:ro
182- # Temps refuses to start its console (UI + OTLP ingest) without a
183- # container socket. Podman's API is Docker-compatible; start it with
184- # `systemctl --user start podman.socket`. Running as root inside the
185- # container is what makes the rootless socket readable (container root
186- # maps to your host user) — same reasoning as surrealdb above.
187- - ${XDG_RUNTIME_DIR:-/run/user/1000}/podman/podman.sock:/var/run/docker.sock
188- user: "0"
189- # SELinux blocks reading the podman socket from inside the container
190- # ("Permission denied", which Temps reports as "Socket not found").
191- # Relabelling the socket itself would break podman, so the label is
192- # dropped for this container only.
193- security_opt:
194- - label=disable
195- depends_on:
196- temps-postgres:
197- condition: service_healthy
198- temps-clickhouse:
199- condition: service_healthy
200 restart: unless-stopped120 restart: unless-stopped
201 healthcheck:121 healthcheck:
202- test: ["CMD", "wget", "--no-verbose", "--tries=1", "--spider", "http://127.0.0.1:9000/readyz"]122+ # corner-cut: the image is distroless (only /openobserve, no shell and no
123+ # HTTP client), so the container cannot probe its own /healthz. `node
124+ # list` is the closest in-image liveness signal — it succeeds only once
125+ # the node has registered itself in the cluster registry, which happens
126+ # after the server starts. Ceiling: it does not prove the HTTP listener
127+ # answers; from the host that is `curl -fsS http://127.0.0.1:5080/healthz`.
128+ test: ["CMD", "/openobserve", "node", "list"]
203 interval: 30s129 interval: 30s
204 timeout: 5s130 timeout: 5s
205- retries: 3131+ retries: 5
206- start_period: 40s132+ start_period: 10s
207 133
208 volumes:134 volumes:
209 hezarfen-data:135 hezarfen-data:
210 surreal-data:136 surreal-data:
211- temps-postgres-data:137+ openobserve-data:
212- temps-clickhouse-data:
213- temps-data:
observability/Containerfile.tempsdeleted+0 -20
@@ -1,20 +0,0 @@
1-# Temps ships a broken runtime image: ghcr.io/gotempsh/temps:* is alpine/musl
2-# but the binary inside is glibc-linked, so it dies with "exec container
3-# process (missing dynamic library?) /usr/local/bin/temps". Their supported
4-# path is building the whole thing from source. Rebasing the same pinned
5-# artifact onto debian-slim gives a runnable image in seconds instead.
6-# Delete this file and use the upstream image directly once it executes.
7-FROM ghcr.io/gotempsh/temps:0.1.0-nightly.20260906.48c2396e AS artifacts
8-
9-FROM docker.io/library/debian:bookworm-slim
10-RUN apt-get update \
11- && apt-get install -y --no-install-recommends ca-certificates tzdata wget \
12- && rm -rf /var/lib/apt/lists/*
13-COPY --from=artifacts /usr/local/bin/temps /usr/local/bin/temps
14-RUN useradd --uid 1000 --create-home temps \
15- && mkdir -p /app/data \
16- && chown -R temps:temps /app
17-USER temps
18-WORKDIR /app
19-ENTRYPOINT ["/usr/local/bin/temps"]
20-CMD ["serve"]
observability/temps-admin-passworddeleted+0 -1
@@ -1 +0,0 @@
1-Temps-Local-Dev-1