On Wednesday, October 21, 2020 at 1:27:27 AM UTC-7 [email protected] wrote:
> To ask my question in another word. If to build a "Thick client" load > balancing <https://grpc.io/blog/grpc-load-balancing/#thick-client> with > gRpc, the client is responsible to keep track of available servers. While > when client detected available servers changed, how does it manages > corresponding SubChannels under existing Channels? I searched around docs > today again, didn't find APIs for that. I'm looking into csharp. Sorry if I > overlooked something. > > thanks a lot > > 在2020年10月19日星期一 UTC+8 下午8:07:33<li yabo> 写道: > >> While considering moving a http client/service call to using gRpc, I'm >> looking at load balancing solutions. We currently have each client manages >> a list of server names (for one service VIP) and connection pools. The >> server names changes from time to time, so each client has it's logic to >> maintain the server names list and http connection pools. >> >> If move to using gRpc, I think the easiest change regarding LB might be >> to let client fill the server names list to gRpc as Subchannels of a >> Channel to the service VIP. So that client sends request to one Channel and >> get requests well load balanced. Once there is changes in the client server >> names list, the client Application layer code goes to update Subchannels in >> gRpc again. >> While I'm not sure if that's a do-able or ok approach that doesn't >> violate gRpc design? >> >> managing one Channel for each server name might be a solution, but that >> possibly won't work well with gRpc retries-policy, because we hope the >> retry request issued by retries-policy hit another server name of the >> server-names list. >> >> Which language is the client? In some languages e.g. C++, retry is currently not supported. With retry-policy, a retry request will select a new subchannel based on the load balancing policy, so most likely it will hit a different backend if the backend list is well balanced (round-robin for example). > Since current client self-managed server names idea works in existing env, >> we hope we don't have to setup new roll like lookaside load balancer in the >> cluster only for the purpose to using gRpc. Does this idea make sense? >> >> Thanks a lot! >> > -- You received this message because you are subscribed to the Google Groups "grpc.io" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/grpc-io/5250604f-9779-40be-acce-2ac951ac83f9n%40googlegroups.com.
