userver
C++ Async Framework
Toggle main menu visibility
Loading...
Searching...
No Matches
client_factory_settings.hpp
Go to the documentation of this file.
1
#pragma once
2
5
6
#include <memory>
7
#include <optional>
8
#include <string>
9
#include <unordered_map>
10
11
#include <grpcpp/security/credentials.h>
12
#include <grpcpp/support/channel_arguments.h>
13
14
#include <
userver/ugrpc/client/auth_type.hpp
>
15
#include <userver/ugrpc/client/proxy_settings.hpp>
16
#include <
userver/ugrpc/client/retry_config.hpp
>
17
#include <
userver/ugrpc/client/retry_limiter.hpp
>
18
19
USERVER_NAMESPACE_BEGIN
20
21
namespace
ugrpc::client
{
22
24
struct
ClientFactorySettings
final {
25
AuthType
auth_type{AuthType::kInsecure};
26
28
std::shared_ptr<grpc::ChannelCredentials>
credentials
;
29
32
std::unordered_map<std::string, std::shared_ptr<grpc::ChannelCredentials>>
client_credentials
;
33
35
RetryConfig
retry_config
;
36
38
RetryLimiterFactory
*
retry_limiter_factory
{
nullptr
};
39
42
grpc::ChannelArguments
channel_args
{};
43
46
std::optional<std::string>
default_service_config
;
47
50
std::size_t
channel_count
{1};
51
53
ProxySettings
proxy_settings
;
54
};
55
58
std::shared_ptr<grpc::ChannelCredentials>
GetClientCredentials
(
59
const
ClientFactorySettings
& client_factory_settings,
60
const
std::string& client_name
61
);
62
63
}
// namespace ugrpc::client
64
65
USERVER_NAMESPACE_END
userver
ugrpc
client
client_factory_settings.hpp
Generated on
for userver by
Doxygen
1.17.0