{"record":{"id":"25ba40703aa50305","repo":"grpc/grpc-go","slug":"produced-zero-addresses-25ba40","errorCode":null,"errorMessage":"produced zero addresses","messagePattern":"produced zero addresses","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"balancer/ringhash/ringhash.go","lineNumber":299,"sourceCode":"\t\t}\n\t\tif idleBalancer != nil {\n\t\t\tidleBalancer.ExitIdle()\n\t\t}\n\t}\n\n\tif b.inhibitChildUpdates {\n\t\treturn\n\t}\n\n\t// Update the channel.\n\tif b.endpointStates.Len() > 0 && b.shouldRegenerateRing {\n\t\t// with a non-empty list of endpoints.\n\t\tb.ring = newRing(b.endpointStates, b.config.MinRingSize, b.config.MaxRingSize, b.logger)\n\t}\n\tb.shouldRegenerateRing = false\n\tvar newPicker balancer.Picker\n\tif b.endpointStates.Len() == 0 {\n\t\tnewPicker = base.NewErrPicker(errors.New(\"produced zero addresses\"))\n\t} else {\n\t\tnewPicker = b.newPickerLocked()\n\t}\n\tb.ClientConn.UpdateState(balancer.State{\n\t\tConnectivityState: state,\n\t\tPicker:            newPicker,\n\t})\n}\n\nfunc (b *ringhashBalancer) Close() {\n\tb.logger.Infof(\"Shutdown\")\n\tb.child.Close()\n}\n\nfunc (b *ringhashBalancer) ExitIdle() {\n\t// ExitIdle implementation is a no-op because connections are either\n\t// triggers from picks or from child balancer state changes.\n}","sourceCodeStart":281,"sourceCodeEnd":317,"githubUrl":"https://github.com/grpc/grpc-go/blob/0c51461d27177d997e14c642fe18c11668fc09a3/balancer/ringhash/ringhash.go#L281-L317","documentation":"Thrown by ParseFilterConfigOverride on the Router filter when a non-nil per-route override is provided. The gRPC Router filter is purely a marker/terminal filter — it does not support any per-route configuration overrides. Envoy's router filter has per-route options, but gRPC's implementation intentionally rejects them.","triggerScenarios":"A RouteConfiguration route entry includes a typed_per_filter_config key for the router filter (e.g., envoy.extensions.filters.http.router.v3.Router) with a non-nil override. The xdsclient passes this override to the router builder, which does not expect one.","commonSituations":"An EnvoyFilter or route configuration template that was copied from a full Envoy deployment where router per-route overrides (like rewrite settings) are used, then applied to a gRPC xDS setup. A control plane that generically populates typed_per_filter_config for all listed filters. A misunderstanding that gRPC's router filter supports the same per-route config as Envoy's.","solutions":["Remove the typed_per_filter_config entry for the router filter from the affected route(s) in the RouteConfiguration.","If the control plane auto-generates per-filter-config for every filter, configure it to skip the router filter.","Understand that gRPC routing (method matching, action selection) is handled by the resolver/config-selector, not by per-route router overrides."],"exampleFix":"// before: RDS route with router override\nroute:\n  typed_per_filter_config:\n    \"envoy.filters.http.router\":\n      \"@type\": type.googleapis.com/envoy.extensions.filters.http.router.v3.Router\n      dynamic_stats: false\n\n// after: remove the router override entirely\nroute:\n  typed_per_filter_config: {}","handlingStrategy":"validation","validationCode":"// Strip router per-route overrides before sending RDS to the data plane:\nfor _, vh := range routeConfig.GetVirtualHosts() {\n    for _, route := range vh.GetRoutes() {\n        cfg := route.GetTypedPerFilterConfig()\n        for k := range cfg {\n            if strings.Contains(k, \"router\") {\n                delete(cfg, k)\n            }\n        }\n    }\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Do not include the router filter in typed_per_filter_config maps; gRPC's router has no per-route config.","Audit control-plane templates that copy Envoy configs wholesale and strip gRPC-incompatible per-route overrides.","Document for your team that gRPC routing is handled by the config selector, not by router per-route config."],"tags":["xds","router","grpc","config","override"],"backgroundTag":null,"analyzedSha":"0c51461d27177d997e14c642fe18c11668fc09a3","analyzedAt":"2026-08-11T14:49:15.055Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}