Observability#
The chart configures logging, metrics, and tracing for Storage Service. Metrics can be exposed for Prometheus to scrape or pushed to an OpenTelemetry Protocol (OTLP) collector. Traces are pushed to an OTLP collector. OTLP uses gRPC transport.
Metrics#
Choose one metric delivery mode:
Set
service.metrics.enabledtotrueto expose a Prometheus endpoint onservice.metrics.port.Set
observability.metrics.enabledtotrueto push metrics to the configured OTLP collector. OTLP metrics take precedence when both settings are enabled, so the Prometheus endpoint is not used as the metrics exporter.
The chart exposes the Prometheus port through both Service resources only when service.metrics.enabled is true. Configure the associated Service annotations, such as Prometheus scrape annotations, with service.annotations or podAnnotations.
service.metrics.enabled- Required:
no
- Type:
boolean
- Default:
false
Enables Prometheus exposition. Ignored as an exporter when OTLP metrics are enabled.
service.metrics.port- Required:
no
- Type:
integer
- Default:
8013
Port for the Prometheus metrics endpoint.
config.metrics.prefix- Required:
no
- Type:
string
- Default:
storage
Prefix for metric names. Set to an empty string to emit unprefixed names.
observability.metrics.enabled- Required:
no
- Type:
boolean
- Default:
false
Enables OTLP metric export.
observability.metrics.endpoint.grpc- Required:
when
observability.metrics.enabledis set totrue- Type:
string
gRPC endpoint of the OTLP-compatible collector.
observability.metrics.exportIntervalMs- Required:
no
- Type:
integer
- Default:
15000
Interval, in milliseconds, between OTLP metric exports.
Prometheus scraping configuration#
Enable the Prometheus exporter and add scrape annotations to the pod. Prometheus scrapes the /metrics path on the configured metrics port. Do not enable observability.metrics in this configuration because OTLP metrics take precedence over the Prometheus exporter.
service:
metrics:
enabled: true
port: 8013
podAnnotations:
prometheus.io/scrape: "true"
prometheus.io/path: "/metrics"
prometheus.io/port: "8013"
For example, the following configuration pushes metrics to an in-cluster collector:
observability:
metrics:
enabled: true
endpoint:
grpc: "http://otel-collector.observability.svc.cluster.local:4317"
exportIntervalMs: 15000
Tracing#
Enable tracing to export spans to an OTLP-compatible collector. The collector endpoint is required when tracing is enabled. To use probabilistic sampling, configure samplingRatio as a string from 0 to 1. When it is set, the chart configures parent-based trace ID ratio sampling; 1 exports all root traces and 0 exports none. Parent sampling decisions are preserved.
observability.tracing.enabled- Required:
no
- Type:
boolean
- Default:
false
Enables OTLP trace export.
observability.tracing.endpoint.grpc- Required:
when
observability.tracing.enabledis set totrue- Type:
string
gRPC endpoint of the OTLP-compatible collector.
observability.tracing.samplingRatio- Required:
no
- Type:
string
Optional sampling ratio from
0to1.config.additionalHeaders.tracingHeaderNames- Required:
no
- Type:
array of strings
- Default:
[x-request-id]
Request headers to propagate to the storage backends for distributed tracing. This list is independent of
observability.headers.forward, which selects the headers forwarded to the permission service. Set a header in both lists to propagate it to every downstream.
observability:
tracing:
enabled: true
endpoint:
grpc: "http://otel-collector.observability.svc.cluster.local:4317"
samplingRatio: "0.5"
Header forwarding#
observability.headers.forward- Required:
no
- Type:
array of strings
- Default:
[]
Headers of the incoming request to copy onto the permission queries made on its behalf. Names are case-insensitive, and every value of a repeated header is forwarded. Storage Service does not authenticate these values, so unless a trusted proxy sets or strips them the permission service must treat them as caller-controlled input.
Storage Service refuses to start when the list names a header it sets itself or one the transports treat specially; the error names the offending header.
This list is independent of
config.additionalHeaders.tracingHeaderNames, which propagates headers to the storage backends. Set a header in both lists to propagate it to every downstream.
observability:
headers:
forward:
- "user-id"
- "username"
- "username-source-claim"
- "x-forwarded-for"
- "x-request-id"
Logging#
Enable structured logging to emit one JSON object per log line, which is suitable for log aggregation systems. The config.logging settings control log filtering and Rust backtraces for the main service container and the Postgres metadata bootstrap container.
observability.logging.structured.enabled- Required:
no
- Type:
boolean
- Default:
false
Emits application and access logs as JSON instead of human-readable text.
config.logging.level- Required:
no
- Type:
string
- Default:
info
Log level for Storage Service components. Supported values are
trace,debug,info,warn, anderror.config.logging.backtrace- Required:
no
- Type:
string
- Default:
0
Rust backtrace verbosity. The chart passes this value to the
RUST_BACKTRACEenvironment variable. Supported values are:0disables backtraces.1enables a shortened backtrace that omits internal Rust frames.fullenables a complete backtrace, including internal Rust frames.
config.logging.extraTargets- Required:
no
- Type:
string
Comma-separated module filters, for example
hyper=debug,tokio=trace.
observability:
logging:
structured:
enabled: true
config:
logging:
level: info
extraTargets: "hyper=warn"
Access logging#
Enable access logging for incoming REST and gRPC requests.
The observability.logging.structured.enabled setting selects the format for both application and access logs. Set it to true for JSON output or leave it disabled for human-readable text.
observability.logging.access.enabled- Required:
no
- Type:
boolean
- Default:
false
Enables access logging.
observability.logging.access.headers- Required:
no
- Type:
object mapping strings to strings
- Default:
{}
Request headers to include in access logs. Each key names a logged property, and its value names the request header to capture. Header names are case-insensitive. Missing headers are omitted.
Keys must not be
transport,endpoint,operation,request, orresponse, which are reserved properties directly under$.access.This setting captures headers for logging independently of
observability.headers.forwardandconfig.additionalHeaders.tracingHeaderNames, which control header propagation to downstream services.
For example, enable JSON access logs and capture the request ID and client address:
observability:
logging:
structured:
enabled: true
access:
enabled: true
headers:
request_id: x-request-id
client_ip: x-forwarded-for
Access log format#
The following JSON illustrates the message shape, with all optional fields shown together and header properties from the configuration example above.
{
"type": "access",
"access": {
"transport": "REST",
"endpoint": "GET /v1beta/fileobject/by-address/{resource_address}",
"operation": "read_from_address",
"request": {
"params": {
"resource_address": "https://storage.example.com/example-bucket/example.txt"
},
"index": 0
},
"response": {
"status": 200,
"detail": {
"resource_info": {
"resource_identity": "https://storage.example.com/example-bucket/example.txt?version-id=example-version",
"metadata": {
"data_object_size": 32,
"last_modified_timestamp": "2026-10-21T12:00:00.000000000Z"
}
}
},
"index": 0,
"final": true
},
"request_id": "example-request",
"client_ip": "192.0.2.1"
}
}
Parameter path |
Description |
|---|---|
|
Message type, always |
|
Request transport: |
|
For REST, follows |
|
Optional. Human-readable operation name in snake_case. |
|
Optional when request metadata is unavailable. Request parameters, whose shape depends on the operation. |
|
Optional. Zero-based request index within a batch. |
|
Numeric HTTP status code for REST or gRPC status code for gRPC. |
|
Optional. Captured response details, whose shape depends on the operation. |
|
Optional. Zero-based response index for a streaming operation. |
|
Optional. Set to |
|
Optional. Additional properties populated from request headers through |
Batch requests#
This behavior covers the following Metadata APIs over REST and gRPC in both v1alpha and v1beta:
GetMetadataBatch.UpdateMetadataBatch.DeleteMetadataBatch.
Batch requests with valid, non-empty payloads produce an access log entry for each batch entry. Each access log entry’s status code matches the transport status when the corresponding response entry is sent.
$.access.request.index contains the zero-based position of the corresponding entry in the submitted request batch: 0 for the first entry, 1 for the second, and so on.
Streaming gRPC responses#
This behavior covers the following gRPC APIs in both v1alpha and v1beta:
Filefolder:
ListandListStat.Fileobject:
Enumerate.Versioning:
EnumerateVersions.Metadata:
QueryMetadata.
For operations logged as response streams, each response message has an access log entry whose $.access.response.index is its zero-based position in the stream: 0 for the first response, 1 for the second, and so on.
A separate final access log entry marks stream completion. Its $.access.response.index is the next index after the response messages, and $.access.response.final is true. Earlier entries omit $.access.response.final. For example, a stream with two response messages has entries indexed 0 and 1, followed by a final entry indexed 2. A stream with no response messages has a final entry indexed 0.