GRPC C++  1.39.1
file_watcher_certificate_provider_factory.h
Go to the documentation of this file.
1 //
2 //
3 // Copyright 2020 gRPC authors.
4 //
5 // Licensed under the Apache License, Version 2.0 (the "License");
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
8 //
9 // http://www.apache.org/licenses/LICENSE-2.0
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 //
17 //
18 
19 #ifndef GRPC_CORE_EXT_XDS_FILE_WATCHER_CERTIFICATE_PROVIDER_FACTORY_H
20 #define GRPC_CORE_EXT_XDS_FILE_WATCHER_CERTIFICATE_PROVIDER_FACTORY_H
21 
23 
25 
26 namespace grpc_core {
27 
30  public:
32  public:
33  static RefCountedPtr<Config> Parse(const Json& config_json,
35 
36  const char* name() const override;
37 
38  std::string ToString() const override;
39 
40  const std::string& identity_cert_file() const {
41  return identity_cert_file_;
42  }
43 
44  const std::string& private_key_file() const { return private_key_file_; }
45 
46  const std::string& root_cert_file() const { return root_cert_file_; }
47 
48  grpc_millis refresh_interval_ms() const { return refresh_interval_ms_; }
49 
50  private:
51  std::string identity_cert_file_;
52  std::string private_key_file_;
53  std::string root_cert_file_;
54  grpc_millis refresh_interval_ms_;
55  };
56 
57  const char* name() const override;
58 
60  CreateCertificateProviderConfig(const Json& config_json,
61  grpc_error_handle* error) override;
62 
65 };
66 
67 } // namespace grpc_core
68 
69 #endif // GRPC_CORE_EXT_XDS_FILE_WATCHER_CERTIFICATE_PROVIDER_FACTORY_H
Definition: certificate_provider_factory.h:35
Definition: certificate_provider_factory.h:32
Definition: file_watcher_certificate_provider_factory.h:31
const char * name() const override
Definition: file_watcher_certificate_provider_factory.cc:41
const std::string & identity_cert_file() const
Definition: file_watcher_certificate_provider_factory.h:40
const std::string & private_key_file() const
Definition: file_watcher_certificate_provider_factory.h:44
grpc_millis refresh_interval_ms() const
Definition: file_watcher_certificate_provider_factory.h:48
const std::string & root_cert_file() const
Definition: file_watcher_certificate_provider_factory.h:46
std::string ToString() const override
Definition: file_watcher_certificate_provider_factory.cc:45
static RefCountedPtr< Config > Parse(const Json &config_json, grpc_error_handle *error)
Definition: file_watcher_certificate_provider_factory.cc:66
Definition: file_watcher_certificate_provider_factory.h:29
RefCountedPtr< CertificateProviderFactory::Config > CreateCertificateProviderConfig(const Json &config_json, grpc_error_handle *error) override
Definition: file_watcher_certificate_provider_factory.cc:114
RefCountedPtr< grpc_tls_certificate_provider > CreateCertificateProvider(RefCountedPtr< CertificateProviderFactory::Config > config) override
Definition: file_watcher_certificate_provider_factory.cc:121
const char * name() const override
Definition: file_watcher_certificate_provider_factory.cc:109
Definition: json.h:38
Definition: ref_counted_ptr.h:35
int64_t grpc_millis
Definition: exec_ctx.h:37
grpc_error_handle error
Definition: lame_client.cc:54
Round Robin Policy.
Definition: backend_metric.cc:26
RefCountedPtr< LoadBalancingPolicy::Config > config
Definition: priority.cc:60
Definition: error_internal.h:41