16 lines
1.1 KiB
Markdown
16 lines
1.1 KiB
Markdown
# starry-client-sdk demo
|
|
|
|
Demo SDK: request `https://blog.starryskymeow.top/{path}`, return response text, and raise `StarryNotFoundError` on HTTP 404. Telemetry is enabled by default. Metrics are pushed to Fluent Bit with Prometheus remote_write; exception logs and traces are exported with OTLP/HTTP. In the demo compose stack, traces are forwarded from Fluent Bit to VictoriaTraces. Trace sampling defaults to 100%.
|
|
|
|
Environment variables:
|
|
|
|
- `STARRYSDK_TELEMETRY_ENABLED`: default `true`; set `false` to disable SDK telemetry.
|
|
- `STARRYSDK_SERVICE_NAME`: default `starry-python-sdk-consumer`.
|
|
- `STARRYSDK_PROMETHEUS_REMOTE_WRITE_ENDPOINT`: default `http://host.docker.internal:8080/api/prom/push`.
|
|
- `STARRYSDK_METRIC_PUSH_INTERVAL_SECONDS`: default `5`.
|
|
- `STARRYSDK_METRIC_PUSH_TIMEOUT_SECONDS`: default `2`.
|
|
- `STARRYSDK_TRACE_SAMPLE_RATE`: default `1.0`; clamped to `0.0`-`1.0`.
|
|
- `OTEL_EXPORTER_OTLP_ENDPOINT`: default `http://host.docker.internal:4318`; SDK appends `/v1/logs` and `/v1/traces` for OTLP/HTTP telemetry.
|
|
- `OTEL_EXPORTER_OTLP_LOGS_ENDPOINT`: optional explicit logs endpoint.
|
|
- `OTEL_EXPORTER_OTLP_TRACES_ENDPOINT`: optional explicit traces endpoint.
|