Skip to Content
Nextra 4.0 is released πŸŽ‰
Developer GuideObservabilityOverview

Observability

Comprehensive observability is crucial for production agentic workloads. ARK provides integrated monitoring, tracing, and logging capabilities to help you understand and optimize your AI agent performance.

OpenTelemetry Integration

ARK provides observability through OpenTelemetry integration, allowing you to monitor and trace all operations across the controller, execution engines and any other services. You can connect to any OpenTelemetry-compatible provider using standard environment variables.

Telemetry is enabled by setting the OpenTelemetry environment variables:

VariableDescriptionExample
OTEL_EXPORTER_OTLP_ENDPOINTOTLP endpoint URLhttp://localhost:4318/v1/traces
OTEL_EXPORTER_OTLP_HEADERSAuthentication headersAuthorization=Basic <token>
OTEL_SERVICE_NAMEService name for telemetryark-controller
OTEL_RESOURCE_ATTRIBUTESAdditional resource attributesenvironment=production

Architecture

Some queries go directly from the controller to the OTEL endpoint, while others flow through execution engines when multi-framework agent orchestration is used.

OTEL Env Vars β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ ARK Controller β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β”œβ”€β”€β”€ β†’ Query Executor β†’ OTEL Endpoint β”‚ └─── β†’ Query Executor β†’ Execution Engine β†’ OTEL Endpoint OTEL Env Vars β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ Services, Engines, etc β”œβ”€β”€β”€ β†’ OTEL Endpoint β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Automatic Injection of OTEL Configuration

One way to set up automatic OpenTelemetry configuration is through standardized ConfigMap and Secret references. This pattern allows any Kubernetes resource to automatically pick up OTEL environment variables when available:

apiVersion: apps/v1 kind: Deployment spec: template: spec: containers: - name: your-app envFrom: # Standard OTEL configuration - will be injected if available - configMapRef: name: otel-environment-variables optional: true - secretRef: name: otel-environment-variables optional: true

When you create or update the standardized otel-environment-variables ConfigMap and Secret, all deployments and pods that reference them must be restarted to pick up the new environment variables:

# Restart components to pick up changes kubectl rollout restart deployment/ark-controller-manager -n ark-system

Service Name Configuration

You can optionally set the service name used for telemetry in your containers, using the OTEL_SERVICE_NAME variable:

spec: template: spec: containers: - name: your-app env: - name: OTEL_SERVICE_NAME value: "my-custom-service"

Additional OTEL Variables

These OpenTelemetry environment variables are also supported:

VariableDescriptionExample
OTEL_RESOURCE_ATTRIBUTESAdditional resource attributesenvironment=production,version=1.0
OTEL_EXPORTER_OTLP_TIMEOUTRequest timeout in milliseconds30000
OTEL_PROPAGATORSTrace context propagation formattracecontext,baggage
OTEL_TRACES_SAMPLERSampling strategyalways_on, always_off, traceidratio
OTEL_TRACES_SAMPLER_ARGSampler configuration0.1 (for 10% sampling)

Next: Learn about Langfuse Service for AI-specific observability.

Last updated on