Tetrate Istio SubscriptionVersion: Next
TIS0804 - MeshConfig Telemetry Configuration Detected
Using MeshConfig
for telemetry configuration is deprecated. Istio now provides a dedicated Telemetry API for better customization of metrics, traces, and access logs.
Recommendation: Migrate telemetry configuration to the Telemetry API.
Transition your telemetry settings from MeshConfig
to the dedicated Telemetry API to leverage enhanced flexibility and maintain compatibility with the latest Istio features.
Examples
-
Using MeshConfig for Custom Metrics Tags
apiVersion: install.istio.io/v1alpha1
kind: IstioOperator
spec:
meshConfig:
telemetry:
v2:
prometheus:
configOverride:
inboundSidecar:
metrics:
- name: requests_total
dimensions:
user-agent: request.headers['User-Agent']
outboundSidecar:
metrics:
- name: requests_total
dimensions:
user-agent: request.headers['User-Agent']
gateway:
metrics:
- name: requests_total
dimensions:
user-agent: request.headers['User-Agent']
host: request.headers['Host']
- name: request_duration_milliseconds
dimensions:
host: request.headers['Host']Explanation: The
telemetry.v2.prometheus.configOverride
field inMeshConfig
is used to add custom dimensions to Prometheus metrics. This configuration is deprecated and should be migrated to the Telemetry API.
Recommendation
-
Migrate Custom Metrics Tags Configuration
apiVersion: telemetry.istio.io/v1
kind: Telemetry
metadata:
name: custom-tags-sidecars
namespace: istio-system
spec:
metrics:
- providers:
- name: prometheus
overrides:
- match:
metric: REQUEST_COUNT
mode: CLIENT_AND_SERVER
tagOverrides:
user_agent:
value: request.headers['User-Agent']apiVersion: telemetry.istio.io/v1
kind: Telemetry
metadata:
name: custom-tags-gateways
namespace: istio-system
spec:
selector:
matchLabels:
istio: ingressgateway
metrics:
- providers:
- name: prometheus
overrides:
- match:
metric: REQUEST_COUNT
mode: CLIENT_AND_SERVER
tagOverrides:
x_tenant_id:
value: request.headers['X-Tenant-Id']
user_agent:
value: request.headers['User-Agent']
- match:
metric: REQUEST_DURATION
mode: CLIENT_AND_SERVER
tagOverrides:
host:
value: request.headers['Host']