Spring / Spring gRPC Interview Questions
How do you handle configuration for multiple gRPC clients pointing to different backend services?
Each backend gets its own named client configuration block:
grpc: client: order-service: address: static://order-service:9090 payment-service: address: static://payment-service:9091
Each matching @GrpcClient("order-service") / @GrpcClient("payment-service") field then resolves independently, and each named client can carry its own settings for negotiation type, TLS, deadlines, and retry policy - so, for example, an internal service can use plaintext while a partner-facing client uses TLS, all configured declaratively rather than in code.
More Related questions...