#include <userver/ugrpc/client/common_component.hpp>
Contains common machinery that's required for all ugrpc clients.
| Name | Description | Default value |
|---|---|---|
| blocking-task-processor | The task processor for blocking channel creation. | – |
| native-log-level | Min log level for the native gRPC library. Possible values: debug, info, error. | error |
| completion-queue-count | Completion queue count to create. Should be ~2 times less than worker threads for best RPS. | – |
| proxy-address | Proxy server address. No proxy if address is empty Example: localhost:84. | – |
| servicemesh-settings | Service settings from separate file for service mesh integration. | – |
| servicemesh-settings.egress | Egress settings. | – |
| servicemesh-settings.egress.disable_proxy.[] | List of addresses that should be accessed directly, bypassing proxy server. Each of the elements: address that should be accessed directly. Example: some.grpc.service.net:11080. | – |
Options inherited from components::ComponentBase :
| Name | Description | Default value |
|---|---|---|
| load-enabled | Set to false to disable loading of the component. | true |
The component name for static config is "grpc-client-common".
Definition at line 33 of file common_component.hpp.
Inheritance diagram for ugrpc::client::CommonComponent:Public Member Functions | |
| CommonComponent (const components::ComponentConfig &config, const components::ComponentContext &context) | |
| ComponentHealth | GetComponentHealth () const override |
| void | OnLoadingCancelled () override |
| void | OnAllComponentsLoaded () override |
| void | OnAllComponentsAreStopping () override |
Static Public Member Functions | |
| static yaml_config::Schema | GetStaticConfigSchema () |
Static Public Attributes | |
| static constexpr std::string_view | kName = "grpc-client-common" |
| The default name of ugrpc::client::CommonComponent. | |
Protected Types | |
| using | LoggableComponentBase = ComponentBase |
|
protectedinherited |
Definition at line 67 of file component_base.hpp.
|
inlineoverridevirtualinherited |
Override this function to inform the world of the state of your component.
Reimplemented from components::RawComponentBase.
Reimplemented in server::handlers::Restart.
Definition at line 35 of file component_base.hpp.
|
inlineoverridevirtualinherited |
Component may use this function to stop doing work before the stop of the components that depend on it.
Base components may override it and make final to do some work before the derived object constructor is called. Don't use it otherwise.
Reimplemented from components::RawComponentBase.
Reimplemented in components::Server, and urabbitmq::ConsumerComponentBase.
Definition at line 58 of file component_base.hpp.
|
inlineoverridevirtualinherited |
Component may use this function to finalize registration of other components that depend on it (for example, handler components register in server component, and the latter uses OnAllComponentsLoaded() to start processing requests).
Base components may override it and make final to do some work after the derived object constructor is called. Don't use it otherwise.
Reimplemented from components::RawComponentBase.
Reimplemented in components::Server, server::handlers::Ping, and urabbitmq::ConsumerComponentBase.
Definition at line 51 of file component_base.hpp.
|
inlineoverridevirtualinherited |
Called once if the creation of any other component failed. If the current component expects some other component to take any action with the current component, this call is a signal that such action may never happen due to components loading was cancelled. Application components might not want to override it.
Reimplemented from components::RawComponentBase.
Definition at line 42 of file component_base.hpp.
|
friend |
Definition at line 45 of file common_component.hpp.