fix(operator): set appProtocol: grpc on registry gRPC Service#6367
Open
tmvfb wants to merge 1 commit intofeast-dev:masterfrom
Open
fix(operator): set appProtocol: grpc on registry gRPC Service#6367tmvfb wants to merge 1 commit intofeast-dev:masterfrom
tmvfb wants to merge 1 commit intofeast-dev:masterfrom
Conversation
Signed-off-by: Igor Kvachenok <igor.kvachenok@prokube.ai>
15e640c to
1124abd
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The registry
Service(the use case is local registry +server.grpcenabled, i.e. SQLite) is always created withname: httpand noappProtocol. This causes service meshes (notably Istio) to misclassify the registry gRPC traffic as HTTP/1.1, breaking connections in two places simultaneously:name: http→ downgrades to HTTP/1.1. gRPC requires HTTP/2.Both failures stem from the same missing field. The fix is minimal: set
appProtocol: grpcon the registry gRPCServiceport.Changes
getServiceAppProtocolhelper that returnsptr.To("grpc")for the registry gRPC Service andnilfor all other services.AppProtocolon theServicePortinsetServicevia this helper.k8s.io/utils/ptrimport toservices.go(already a transitive dependency, used in tests).Effect
With
appProtocol: grpcset, Istio and other service meshes correctly identify the port as gRPC and handle HTTP/2 and mTLS normally, no workarounds required.Testing
go vet ./internal/...passes. Existing operator unit tests are unaffected (they assert on port number and name, notappProtocol). Manual verification on a cluster with Istio sidecar injection confirmed gRPC connectivity works end-to-end after this change with no additional mesh configuration.Workaround
appProtocol: grpc.traffic.sidecar.istio.io/excludeInboundPorts: "6570"on the feast-server pod to bypass it entirely.DestinationRulewithtls: DISABLEis also required to stop the client from attempting it.