Traffic Mirroring
Traffic Mirroring (or Shadow Traffic) is a technique that replicates production traffic in real-time to test new versions.
Table of Contents
Traffic Mirroring Overview
Basic Configuration
yaml
apiVersion: networking.istio.io/v1
kind: VirtualService
metadata:
name: reviews-mirror
spec:
hosts:
- reviews
http:
- route:
- destination:
host: reviews
subset: v1
weight: 100
mirror:
host: reviews
subset: v2
mirrorPercentage:
value: 100 # 100% mirroringPartial Mirroring
yaml
apiVersion: networking.istio.io/v1
kind: VirtualService
metadata:
name: reviews-partial-mirror
spec:
hosts:
- reviews
http:
- route:
- destination:
host: reviews
subset: v1
mirror:
host: reviews
subset: v2
mirrorPercentage:
value: 10 # Mirror only 10%