Careful!
You are browsing documentation for the next version of Kuma. Use this version at your own risk.
MeshMultiZoneService
MeshMultiZoneService groups multiple MeshService resources across zones into a single addressable destination. While MeshService represents a service in a specific zone, MeshMultiZoneService aggregates services from multiple zones and provides zone-agnostic hostnames for cross-zone load balancing.
Kuma automatically assigns virtual IPs and generates hostnames for each MeshMultiZoneService. Traffic sent to these addresses is load balanced across all matching MeshServices, with preference for the local zone when available.
For usage patterns and migration guidance, see the MeshMultiZoneService guide.
Spec fields
| Field | Description |
|---|---|
selector |
Defines which MeshServices to group together. Required. |
selector.meshService |
Label selector matching MeshServices across zones. Required. |
selector.meshService.matchLabels |
Map of label key-value pairs. All labels must match. Common labels: kuma.io/display-name, k8s.kuma.io/namespace, kuma.io/zone. |
ports |
List of ports exposed by this multi-zone service (minimum 1 required). |
ports[].port |
Port number exposed by the service (required). |
ports[].name |
Optional port name for referencing in policies. |
ports[].appProtocol |
Protocol hint: tcp (default), http, http2, grpc. |
Status fields
Status is managed by Kuma and visible only in zone control planes (not global):
| Field | Description |
|---|---|
addresses |
hostnames generated by HostnameGenerators. |
vips |
Virtual IP addresses assigned from the multi-zone service CIDR (default 243.0.0.0/8). |
meshServices |
List of matched MeshServices with name, namespace, zone, and mesh. |
hostnameGenerators |
Status of hostname generation from each HostnameGenerator. |
Examples
Basic MeshMultiZoneService
Group all MeshServices named redis across zones:
apiVersion: kuma.io/v1alpha1
kind: MeshMultiZoneService
metadata:
name: redis
namespace: kuma-system
labels:
kuma.io/mesh: default
spec:
selector:
meshService:
matchLabels:
kuma.io/display-name: redis
ports:
- port: 6379
appProtocol: tcp
MeshMultiZoneService with namespace selector
Select services from a specific namespace across all zones:
apiVersion: kuma.io/v1alpha1
kind: MeshMultiZoneService
metadata:
name: backend
namespace: kuma-system
labels:
kuma.io/mesh: default
spec:
selector:
meshService:
matchLabels:
kuma.io/display-name: backend
k8s.kuma.io/namespace: prod
ports:
- port: 8080
appProtocol: http
MeshMultiZoneService with multiple ports
Expose multiple ports from the same service:
apiVersion: kuma.io/v1alpha1
kind: MeshMultiZoneService
metadata:
name: webapp
namespace: kuma-system
labels:
kuma.io/mesh: default
spec:
selector:
meshService:
matchLabels:
kuma.io/display-name: webapp
ports:
- name: http
port: 8080
appProtocol: http
- name: metrics
port: 9090
appProtocol: http
MeshMultiZoneService with zone selector
Select services only from specific zones:
apiVersion: kuma.io/v1alpha1
kind: MeshMultiZoneService
metadata:
name: regional-service
namespace: kuma-system
labels:
kuma.io/mesh: default
spec:
selector:
meshService:
matchLabels:
kuma.io/display-name: api
kuma.io/zone: us-east
ports:
- port: 443
appProtocol: http2