tree: c49ca96a7aabd5903da2ca54645bf9f208211da0 [path history] [tgz]
  1. .clang-format
  2. backup_poller.cc
  3. backup_poller.h
  4. client_channel_channelz.cc
  5. client_channel_channelz.h
  6. client_channel_factory.cc
  7. client_channel_factory.h
  8. client_channel_filter.cc
  9. client_channel_filter.h
  10. client_channel_internal.h
  11. client_channel_plugin.cc
  12. client_channel_service_config.cc
  13. client_channel_service_config.h
  14. config_selector.cc
  15. config_selector.h
  16. connector.h
  17. dynamic_filters.cc
  18. dynamic_filters.h
  19. global_subchannel_pool.cc
  20. global_subchannel_pool.h
  21. http_proxy_mapper.cc
  22. http_proxy_mapper.h
  23. local_subchannel_pool.cc
  24. local_subchannel_pool.h
  25. README.md
  26. retry_filter.cc
  27. retry_filter.h
  28. retry_filter_legacy_call_data.cc
  29. retry_filter_legacy_call_data.h
  30. retry_service_config.cc
  31. retry_service_config.h
  32. retry_throttle.cc
  33. retry_throttle.h
  34. subchannel.cc
  35. subchannel.h
  36. subchannel_interface_internal.h
  37. subchannel_pool_interface.cc
  38. subchannel_pool_interface.h
  39. subchannel_stream_client.cc
  40. subchannel_stream_client.h
src/core/client_channel/README.md

Client Configuration Support for GRPC

This library provides high level configuration machinery to construct client channels and load balance between them.

Each grpc_channel is created with a Resolver. It is the resolver's duty to resolve a name into a set of arguments for the channel. Such arguments might include:

  • a list of (ip, port) addresses to connect to
  • a load balancing policy to decide which server to send a request to
  • a set of filters to mutate outgoing requests (say, by adding metadata)

The resolver provides this data as a stream of grpc_channel_args objects to the channel. We represent arguments as a stream so that they can be changed by the resolver during execution, by reacting to external events (such as new service configuration data being pushed to some store).

Load Balancing

Load balancing configuration is provided by a LoadBalancingPolicy object.

The primary job of the load balancing policies is to pick a target server given only the initial metadata for a request. It does this by providing a ConnectedSubchannel object to the owning channel.

Sub-Channels

A sub-channel provides a connection to a server for a client channel. It has a connectivity state like a regular channel, and so can be connected or disconnected. This connectivity state can be used to inform load balancing decisions (for example, by avoiding disconnected backends).

Configured sub-channels are fully setup to participate in the grpc data plane. Their behavior is specified by a set of grpc channel filters defined at their construction. To customize this behavior, transports build ClientChannelFactory objects, which customize construction arguments for concrete subchannel instances.

Naming for GRPC

See [/doc/naming.md](gRPC name resolution).