20
20
#include " opentelemetry/nostd/string_view.h"
21
21
#include " opentelemetry/nostd/variant.h"
22
22
#include " opentelemetry/sdk/common/exporter_utils.h"
23
+ #include " opentelemetry/sdk/common/thread_instrumentation.h"
23
24
#include " opentelemetry/version.h"
24
25
25
26
// forward declare google::protobuf::Message
@@ -83,28 +84,32 @@ struct OtlpHttpClientOptions
83
84
// User agent
84
85
std::string user_agent;
85
86
86
- inline OtlpHttpClientOptions (nostd::string_view input_url,
87
- bool input_ssl_insecure_skip_verify,
88
- nostd::string_view input_ssl_ca_cert_path,
89
- nostd::string_view input_ssl_ca_cert_string,
90
- nostd::string_view input_ssl_client_key_path,
91
- nostd::string_view input_ssl_client_key_string,
92
- nostd::string_view input_ssl_client_cert_path,
93
- nostd::string_view input_ssl_client_cert_string,
94
- nostd::string_view input_ssl_min_tls,
95
- nostd::string_view input_ssl_max_tls,
96
- nostd::string_view input_ssl_cipher,
97
- nostd::string_view input_ssl_cipher_suite,
98
- HttpRequestContentType input_content_type,
99
- JsonBytesMappingKind input_json_bytes_mapping,
100
- nostd::string_view input_compression,
101
- bool input_use_json_name,
102
- bool input_console_debug,
103
- std::chrono::system_clock::duration input_timeout,
104
- const OtlpHeaders &input_http_headers,
105
- std::size_t input_concurrent_sessions = 64 ,
106
- std::size_t input_max_requests_per_connection = 8 ,
107
- nostd::string_view input_user_agent = GetOtlpDefaultUserAgent())
87
+ std::shared_ptr<sdk::common::ThreadInstrumentation> thread_instrumentation;
88
+
89
+ inline OtlpHttpClientOptions (
90
+ nostd::string_view input_url,
91
+ bool input_ssl_insecure_skip_verify,
92
+ nostd::string_view input_ssl_ca_cert_path,
93
+ nostd::string_view input_ssl_ca_cert_string,
94
+ nostd::string_view input_ssl_client_key_path,
95
+ nostd::string_view input_ssl_client_key_string,
96
+ nostd::string_view input_ssl_client_cert_path,
97
+ nostd::string_view input_ssl_client_cert_string,
98
+ nostd::string_view input_ssl_min_tls,
99
+ nostd::string_view input_ssl_max_tls,
100
+ nostd::string_view input_ssl_cipher,
101
+ nostd::string_view input_ssl_cipher_suite,
102
+ HttpRequestContentType input_content_type,
103
+ JsonBytesMappingKind input_json_bytes_mapping,
104
+ nostd::string_view input_compression,
105
+ bool input_use_json_name,
106
+ bool input_console_debug,
107
+ std::chrono::system_clock::duration input_timeout,
108
+ const OtlpHeaders &input_http_headers,
109
+ const std::shared_ptr<sdk::common::ThreadInstrumentation> &input_thread_instrumentation,
110
+ std::size_t input_concurrent_sessions = 64 ,
111
+ std::size_t input_max_requests_per_connection = 8 ,
112
+ nostd::string_view input_user_agent = GetOtlpDefaultUserAgent())
108
113
: url(input_url),
109
114
ssl_options(input_url,
110
115
input_ssl_insecure_skip_verify,
@@ -127,7 +132,8 @@ struct OtlpHttpClientOptions
127
132
http_headers(input_http_headers),
128
133
max_concurrent_requests(input_concurrent_sessions),
129
134
max_requests_per_connection(input_max_requests_per_connection),
130
- user_agent(input_user_agent)
135
+ user_agent(input_user_agent),
136
+ thread_instrumentation(input_thread_instrumentation)
131
137
{}
132
138
};
133
139
0 commit comments