opentelemetry-exporter-otlp 0.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 7fb2bdcf07cb323140c330bf581d3fcd1a7202371a0be2d8ebe6df453b9ef880
4
+ data.tar.gz: 381a17d0a1428c56fde01fa1096b5716ab069d030ff0c9311a9a151ddac7ffb9
5
+ SHA512:
6
+ metadata.gz: 38a72e4e1112f5b0d4e706f0316e72d73ba6ae40301358843f51ba11938e6fed069a33598de3f8974f19168b4bfea9b8a90dd0d8354740f88b4e1de985a3551b
7
+ data.tar.gz: 2819b77a20f46dd9a7aaa872ff17487963bbcf5005b539a9092d1a7c21aef752028220fc3bf7f80178e6ee93266f46120c2f7f02bc9f8a7fdafe90e151204855
@@ -0,0 +1,9 @@
1
+ --no-private
2
+ --title=OpenTelemetry OTLP Exporter
3
+ --markup=markdown
4
+ --main=OVERVIEW.md
5
+ ./lib/opentelemetry/exporter/otlp/**/*.rb
6
+ ./lib/opentelemetry/exporter/otlp.rb
7
+ -
8
+ OVERVIEW.md
9
+ CHANGELOG.md
@@ -0,0 +1,5 @@
1
+ # Release History: opentelemetry-exporter-otlp
2
+
3
+ ### v0.6.0 / 2020-09-10
4
+
5
+ * Initial release.
data/LICENSE ADDED
@@ -0,0 +1,201 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright 2020 OpenTelemetry Authors
190
+
191
+ Licensed under the Apache License, Version 2.0 (the "License");
192
+ you may not use this file except in compliance with the License.
193
+ You may obtain a copy of the License at
194
+
195
+ http://www.apache.org/licenses/LICENSE-2.0
196
+
197
+ Unless required by applicable law or agreed to in writing, software
198
+ distributed under the License is distributed on an "AS IS" BASIS,
199
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
+ See the License for the specific language governing permissions and
201
+ limitations under the License.
@@ -0,0 +1,87 @@
1
+ # opentelemetry-exporter-otlp
2
+
3
+ The `opentelemetry-exporter-otlp` gem provides an [OTLP](https://github.com/open-telemetry/opentelemetry-proto) exporter for OpenTelemetry for Ruby. Using `opentelemetry-exporter-otlp`, an application can configure OpenTelemetry to export collected tracing data to [the OpenTelemetry Collector][opentelemetry-collector-home].
4
+
5
+ ## What is OpenTelemetry?
6
+
7
+ [OpenTelemetry][opentelemetry-home] is an open source observability framework, providing a general-purpose API, SDK, and related tools required for the instrumentation of cloud-native software, frameworks, and libraries.
8
+
9
+ OpenTelemetry provides a single set of APIs, libraries, agents, and collector services to capture distributed traces and metrics from your application. You can analyze them using Prometheus, Jaeger, and other observability tools.
10
+
11
+ ## How does this gem fit in?
12
+
13
+ The `opentelemetry-exporter-otlp` gem is a plugin that provides OTLP export. To export to the OpenTelemetry Collector, an application can include this gem along with `opentelemetry-sdk`, and configure the `SDK` to use the provided OTLP exporter as a span processor.
14
+
15
+ Generally, *libraries* that produce telemetry data should avoid depending directly on specific exporter, deferring that choice to the application developer.
16
+
17
+ ### Supported protocol version
18
+
19
+ This gem supports the [v0.4.0 release](https://github.com/open-telemetry/opentelemetry-proto/releases/tag/v0.4.0) of OTLP.
20
+
21
+ ## How do I get started?
22
+
23
+ Install the gem using:
24
+
25
+ ```
26
+ gem install opentelemetry-sdk
27
+ gem install opentelemetry-exporter-otlp
28
+ ```
29
+
30
+ Or, if you use [bundler][bundler-home], include `opentelemetry-sdk` in your `Gemfile`.
31
+
32
+ Then, configure the SDK to use the OTLP exporter as a span processor, and use the OpenTelemetry interfaces to produces traces and other information. Following is a basic example.
33
+
34
+ ```ruby
35
+ require 'opentelemetry/sdk'
36
+ require 'opentelemetry/exporter/otlp'
37
+
38
+ # Configure the sdk with custom export
39
+ OpenTelemetry::SDK.configure do |c|
40
+ c.add_span_processor(
41
+ OpenTelemetry::SDK::Trace::Export::SimpleSpanProcessor.new(
42
+ OpenTelemetry::Exporter::OTLP::Exporter.new(
43
+ host: 'localhost', port: 55680
44
+ )
45
+ )
46
+ )
47
+ end
48
+
49
+ # To start a trace you need to get a Tracer from the TracerProvider
50
+ tracer = OpenTelemetry.tracer_provider.tracer('my_app_or_gem', '0.1.0')
51
+
52
+ # create a span
53
+ tracer.in_span('foo') do |span|
54
+ # set an attribute
55
+ span.set_attribute('platform', 'osx')
56
+ # add an event
57
+ span.add_event(name: 'event in bar')
58
+ # create bar as child of foo
59
+ tracer.in_span('bar') do |child_span|
60
+ # inspect the span
61
+ pp child_span
62
+ end
63
+ end
64
+ ```
65
+
66
+ For additional examples, see the [examples on github][examples-github].
67
+
68
+ ## How can I get involved?
69
+
70
+ The `opentelemetry-exporter-otlp` gem source is [on github][repo-github], along with related gems including `opentelemetry-sdk`.
71
+
72
+ The OpenTelemetry Ruby gems are maintained by the OpenTelemetry-Ruby special interest group (SIG). You can get involved by joining us on our [gitter channel][ruby-gitter] or attending our weekly meeting. See the [meeting calendar][community-meetings] for dates and times. For more information on this and other language SIGs, see the OpenTelemetry [community page][ruby-sig].
73
+
74
+ ## License
75
+
76
+ The `opentelemetry-exporter-otlp` gem is distributed under the Apache 2.0 license. See [LICENSE][license-github] for more information.
77
+
78
+
79
+ [opentelemetry-collector-home]: https://opentelemetry.io/docs/collector/about/
80
+ [opentelemetry-home]: https://opentelemetry.io
81
+ [bundler-home]: https://bundler.io
82
+ [repo-github]: https://github.com/open-telemetry/opentelemetry-ruby
83
+ [license-github]: https://github.com/open-telemetry/opentelemetry-ruby/blob/master/LICENSE
84
+ [examples-github]: https://github.com/open-telemetry/opentelemetry-ruby/tree/master/examples
85
+ [ruby-sig]: https://github.com/open-telemetry/community#ruby-sig
86
+ [community-meetings]: https://github.com/open-telemetry/community#community-meetings
87
+ [ruby-gitter]: https://gitter.im/open-telemetry/opentelemetry-ruby
@@ -0,0 +1,7 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright The OpenTelemetry Authors
4
+ #
5
+ # SPDX-License-Identifier: Apache-2.0
6
+
7
+ require 'opentelemetry/exporter/otlp'
@@ -0,0 +1,17 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright The OpenTelemetry Authors
4
+ #
5
+ # SPDX-License-Identifier: Apache-2.0
6
+
7
+ require 'opentelemetry/exporter/otlp/exporter'
8
+ require 'opentelemetry/exporter/otlp/version'
9
+
10
+ # OpenTelemetry is an open source observability framework, providing a
11
+ # general-purpose API, SDK, and related tools required for the instrumentation
12
+ # of cloud-native software, frameworks, and libraries.
13
+ #
14
+ # The OpenTelemetry module provides global accessors for telemetry objects.
15
+ # See the documentation for the `opentelemetry-api` gem for details.
16
+ module OpenTelemetry
17
+ end
@@ -0,0 +1,292 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright The OpenTelemetry Authors
4
+ #
5
+ # SPDX-License-Identifier: Apache-2.0
6
+
7
+ require 'opentelemetry/sdk'
8
+ require 'net/http'
9
+ require 'csv'
10
+
11
+ require 'opentelemetry/proto/common/v1/common_pb'
12
+ require 'opentelemetry/proto/resource/v1/resource_pb'
13
+ require 'opentelemetry/proto/trace/v1/trace_pb'
14
+ require 'opentelemetry/proto/collector/trace/v1/trace_service_pb'
15
+
16
+ module OpenTelemetry
17
+ module Exporter
18
+ module OTLP
19
+ # An OpenTelemetry trace exporter that sends spans over HTTP as Protobuf encoded OTLP ExportTraceServiceRequests.
20
+ class Exporter # rubocop:disable Metrics/ClassLength
21
+ SUCCESS = OpenTelemetry::SDK::Trace::Export::SUCCESS
22
+ FAILURE = OpenTelemetry::SDK::Trace::Export::FAILURE
23
+ private_constant(:SUCCESS, :FAILURE)
24
+
25
+ # Default timeouts in seconds.
26
+ KEEP_ALIVE_TIMEOUT = 30
27
+ OPEN_TIMEOUT = 5
28
+ READ_TIMEOUT = 5
29
+ RETRY_COUNT = 5
30
+ private_constant(:KEEP_ALIVE_TIMEOUT, :OPEN_TIMEOUT, :READ_TIMEOUT, :RETRY_COUNT)
31
+
32
+ def initialize(endpoint: config_opt('OTEL_EXPORTER_OTLP_SPAN_ENDPOINT', 'OTEL_EXPORTER_OTLP_ENDPOINT', default: 'localhost:55681/v1/trace'), # rubocop:disable Metrics/AbcSize, Metrics/CyclomaticComplexity
33
+ insecure: config_opt('OTEL_EXPORTER_OTLP_SPAN_INSECURE', 'OTEL_EXPORTER_OTLP_INSECURE', default: false),
34
+ certificate_file: config_opt('OTEL_EXPORTER_OTLP_SPAN_CERTIFICATE', 'OTEL_EXPORTER_OTLP_CERTIFICATE'),
35
+ headers: config_opt('OTEL_EXPORTER_OTLP_SPAN_HEADERS', 'OTEL_EXPORTER_OTLP_HEADERS'), # TODO: what format is expected here?
36
+ compression: config_opt('OTEL_EXPORTER_OTLP_SPAN_COMPRESSION', 'OTEL_EXPORTER_OTLP_COMPRESSION'),
37
+ timeout: config_opt('OTEL_EXPORTER_OTLP_SPAN_TIMEOUT', 'OTEL_EXPORTER_OTLP_TIMEOUT', default: 10))
38
+ raise ArgumentError, "invalid url for OTLP::Exporter #{endpoint}" if invalid_url?("http://#{endpoint}")
39
+ raise ArgumentError, "unsupported compression key #{compression}" unless compression.nil?
40
+ raise ArgumentError, 'headers must be comma-separated k:v pairs or a Hash' unless valid_headers?(headers)
41
+
42
+ uri = URI "http://#{endpoint}"
43
+ @http = Net::HTTP.new(uri.host, uri.port)
44
+ @http.use_ssl = insecure.to_s.downcase == 'false'
45
+ @http.ca_file = certificate_file unless certificate_file.nil?
46
+ @http.keep_alive_timeout = KEEP_ALIVE_TIMEOUT
47
+ @http.open_timeout = OPEN_TIMEOUT
48
+ @http.read_timeout = READ_TIMEOUT
49
+
50
+ @path = uri.path
51
+ @headers = case headers
52
+ when String then CSV.parse(headers, col_sep: ':', row_sep: ',').to_h
53
+ when Hash then headers
54
+ end
55
+ @timeout = timeout.to_f # TODO: use this as a default timeout when we implement timeouts in https://github.com/open-telemetry/opentelemetry-ruby/pull/341
56
+ @tracer = OpenTelemetry.tracer_provider.tracer
57
+
58
+ @shutdown = false
59
+ end
60
+
61
+ # Called to export sampled {OpenTelemetry::SDK::Trace::SpanData} structs.
62
+ #
63
+ # @param [Enumerable<OpenTelemetry::SDK::Trace::SpanData>] span_data the
64
+ # list of recorded {OpenTelemetry::SDK::Trace::SpanData} structs to be
65
+ # exported.
66
+ # @return [Integer] the result of the export.
67
+ def export(span_data)
68
+ return FAILURE if @shutdown
69
+
70
+ send_bytes(encode(span_data))
71
+ end
72
+
73
+ # Called when {OpenTelemetry::SDK::Trace::Tracer#shutdown} is called, if
74
+ # this exporter is registered to a {OpenTelemetry::SDK::Trace::Tracer}
75
+ # object.
76
+ def shutdown
77
+ @shutdown = true
78
+ @http.finish if @http.started?
79
+ end
80
+
81
+ private
82
+
83
+ def config_opt(*env_vars, default: nil)
84
+ env_vars.each do |env_var|
85
+ val = ENV[env_var]
86
+ return val unless val.nil?
87
+ end
88
+ default
89
+ end
90
+
91
+ def valid_headers?(headers)
92
+ return true if headers.nil? || headers.is_a?(Hash)
93
+ return false unless headers.is_a?(String)
94
+
95
+ CSV.parse(headers, col_sep: ':', row_sep: ',').to_h
96
+ true
97
+ rescue ArgumentError
98
+ false
99
+ end
100
+
101
+ def invalid_url?(url)
102
+ return true if url.nil? || url.strip.empty?
103
+
104
+ uri = URI(url)
105
+ uri.path.nil? || uri.path.empty?
106
+ rescue URI::InvalidURIError
107
+ true
108
+ end
109
+
110
+ def send_bytes(bytes) # rubocop:disable Metrics/AbcSize, Metrics/CyclomaticComplexity, Metrics/MethodLength, Metrics/PerceivedComplexity
111
+ retry_count = 0
112
+ untraced do # rubocop:disable Metrics/BlockLength
113
+ request = Net::HTTP::Post.new(@path)
114
+ request.body = bytes
115
+ request.add_field('Content-Type', 'application/x-protobuf')
116
+ @headers&.each { |key, value| request.add_field(key, value) }
117
+ # TODO: enable gzip when https://github.com/open-telemetry/opentelemetry-collector/issues/1344 is fixed.
118
+ # request.add_field('Content-Encoding', 'gzip')
119
+
120
+ @http.start unless @http.started?
121
+ response = @http.request(request)
122
+
123
+ case response
124
+ when Net::HTTPOK
125
+ response.body # Read and discard body
126
+ SUCCESS
127
+ when Net::HTTPServiceUnavailable, Net::HTTPTooManyRequests
128
+ response.body # Read and discard body
129
+ redo if backoff?(retry_after: response['Retry-After'], retry_count: retry_count += 1)
130
+ FAILURE
131
+ when Net::HTTPRequestTimeOut, Net::HTTPGatewayTimeOut, Net::HTTPBadGateway
132
+ response.body # Read and discard body
133
+ redo if backoff?(retry_count: retry_count += 1)
134
+ FAILURE
135
+ when Net::HTTPBadRequest, Net::HTTPClientError, Net::HTTPServerError
136
+ # TODO: decode the body as a google.rpc.Status Protobuf-encoded message when https://github.com/open-telemetry/opentelemetry-collector/issues/1357 is fixed.
137
+ response.body # Read and discard body
138
+ FAILURE
139
+ when Net::HTTPRedirection
140
+ @http.finish
141
+ handle_redirect(response['location'])
142
+ redo if backoff?(retry_after: 0, retry_count: retry_count += 1)
143
+ else
144
+ @http.finish
145
+ FAILURE
146
+ end
147
+ rescue Net::OpenTimeout, Net::ReadTimeout
148
+ retry if backoff?(retry_count: retry_count += 1)
149
+ return FAILURE
150
+ end
151
+ end
152
+
153
+ def handle_redirect(location)
154
+ # TODO: figure out destination and reinitialize @http and @path
155
+ end
156
+
157
+ def untraced
158
+ @tracer.with_span(OpenTelemetry::Trace::Span.new) { yield }
159
+ end
160
+
161
+ def backoff?(retry_after: nil, retry_count:, reason:)
162
+ return false if retry_count > RETRY_COUNT
163
+
164
+ sleep_interval = nil
165
+ unless retry_after.nil?
166
+ sleep_interval =
167
+ begin
168
+ Integer(retry_after)
169
+ rescue ArgumentError
170
+ nil
171
+ end
172
+ sleep_interval ||=
173
+ begin
174
+ Time.httpdate(retry_after) - Time.now
175
+ rescue # rubocop:disable Style/RescueStandardError
176
+ nil
177
+ end
178
+ sleep_interval = nil unless sleep_interval&.positive?
179
+ end
180
+ sleep_interval ||= rand(2**retry_count)
181
+
182
+ sleep(sleep_interval)
183
+ true
184
+ end
185
+
186
+ def encode(span_data) # rubocop:disable Metrics/MethodLength
187
+ Opentelemetry::Proto::Collector::Trace::V1::ExportTraceServiceRequest.encode(
188
+ Opentelemetry::Proto::Collector::Trace::V1::ExportTraceServiceRequest.new(
189
+ resource_spans: span_data
190
+ .group_by(&:resource)
191
+ .map do |resource, span_datas|
192
+ Opentelemetry::Proto::Trace::V1::ResourceSpans.new(
193
+ resource: Opentelemetry::Proto::Resource::V1::Resource.new(
194
+ attributes: resource.attribute_enumerator.map { |key, value| as_otlp_key_value(key, value) }
195
+ ),
196
+ instrumentation_library_spans: span_datas
197
+ .group_by(&:instrumentation_library)
198
+ .map do |il, sds|
199
+ Opentelemetry::Proto::Trace::V1::InstrumentationLibrarySpans.new(
200
+ instrumentation_library: Opentelemetry::Proto::Common::V1::InstrumentationLibrary.new(
201
+ name: il.name,
202
+ version: il.version
203
+ ),
204
+ spans: sds.map { |sd| as_otlp_span(sd) }
205
+ )
206
+ end
207
+ )
208
+ end
209
+ )
210
+ )
211
+ end
212
+
213
+ def as_otlp_span(span_data) # rubocop:disable Metrics/AbcSize, Metrics/MethodLength
214
+ Opentelemetry::Proto::Trace::V1::Span.new(
215
+ trace_id: span_data.trace_id,
216
+ span_id: span_data.span_id,
217
+ trace_state: span_data.tracestate,
218
+ parent_span_id: span_data.parent_span_id,
219
+ name: span_data.name,
220
+ kind: as_otlp_span_kind(span_data.kind),
221
+ start_time_unix_nano: as_otlp_timestamp(span_data.start_timestamp),
222
+ end_time_unix_nano: as_otlp_timestamp(span_data.end_timestamp),
223
+ attributes: span_data.attributes&.map { |k, v| as_otlp_key_value(k, v) },
224
+ dropped_attributes_count: span_data.total_recorded_attributes - span_data.attributes&.size.to_i,
225
+ events: span_data.events&.map do |event|
226
+ Opentelemetry::Proto::Trace::V1::Span::Event.new(
227
+ time_unix_nano: as_otlp_timestamp(event.timestamp),
228
+ name: event.name,
229
+ attributes: event.attributes&.map { |k, v| as_otlp_key_value(k, v) }
230
+ # TODO: track dropped_attributes_count in Span#append_event
231
+ )
232
+ end,
233
+ dropped_events_count: span_data.total_recorded_events - span_data.events&.size.to_i,
234
+ links: span_data.links&.map do |link|
235
+ Opentelemetry::Proto::Trace::V1::Span::Link.new(
236
+ trace_id: link.context.trace_id,
237
+ span_id: link.context.span_id,
238
+ trace_state: link.context.tracestate,
239
+ attributes: link.attributes&.map { |k, v| as_otlp_key_value(k, v) }
240
+ # TODO: track dropped_attributes_count in Span#trim_links
241
+ )
242
+ end,
243
+ dropped_links_count: span_data.total_recorded_links - span_data.links&.size.to_i,
244
+ status: span_data.status&.yield_self do |status|
245
+ Opentelemetry::Proto::Trace::V1::Status.new(
246
+ code: status.canonical_code,
247
+ message: status.description
248
+ )
249
+ end
250
+ )
251
+ end
252
+
253
+ def as_otlp_timestamp(timestamp)
254
+ (timestamp.to_r * 1_000_000_000).to_i
255
+ end
256
+
257
+ def as_otlp_span_kind(kind)
258
+ case kind
259
+ when :internal then Opentelemetry::Proto::Trace::V1::Span::SpanKind::INTERNAL
260
+ when :server then Opentelemetry::Proto::Trace::V1::Span::SpanKind::SERVER
261
+ when :client then Opentelemetry::Proto::Trace::V1::Span::SpanKind::CLIENT
262
+ when :producer then Opentelemetry::Proto::Trace::V1::Span::SpanKind::PRODUCER
263
+ when :consumer then Opentelemetry::Proto::Trace::V1::Span::SpanKind::CONSUMER
264
+ else Opentelemetry::Proto::Trace::V1::Span::SpanKind::SPAN_KIND_UNSPECIFIED
265
+ end
266
+ end
267
+
268
+ def as_otlp_key_value(key, value)
269
+ Opentelemetry::Proto::Common::V1::KeyValue.new(key: key, value: as_otlp_any_value(value))
270
+ end
271
+
272
+ def as_otlp_any_value(value)
273
+ result = Opentelemetry::Proto::Common::V1::AnyValue.new
274
+ case value
275
+ when String
276
+ result.string_value = value
277
+ when Integer
278
+ result.int_value = value
279
+ when Float
280
+ result.double_value = value
281
+ when true, false
282
+ result.bool_value = value
283
+ when Array
284
+ values = value.map { |element| as_otlp_any_value(element) }
285
+ result.array_value = Opentelemetry::Proto::Common::V1::ArrayValue.new(values: values)
286
+ end
287
+ result
288
+ end
289
+ end
290
+ end
291
+ end
292
+ end
@@ -0,0 +1,14 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2019 OpenTelemetry Authors
4
+ #
5
+ # SPDX-License-Identifier: Apache-2.0
6
+
7
+ module OpenTelemetry
8
+ module Exporter
9
+ module OTLP
10
+ ## Current OpenTelemetry OTLP exporter version
11
+ VERSION = '0.6.0'
12
+ end
13
+ end
14
+ end
@@ -0,0 +1,28 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: opentelemetry/proto/collector/trace/v1/trace_service.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ require 'opentelemetry/proto/trace/v1/trace_pb'
7
+ Google::Protobuf::DescriptorPool.generated_pool.build do
8
+ add_file("opentelemetry/proto/collector/trace/v1/trace_service.proto", :syntax => :proto3) do
9
+ add_message "opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest" do
10
+ repeated :resource_spans, :message, 1, "opentelemetry.proto.trace.v1.ResourceSpans"
11
+ end
12
+ add_message "opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse" do
13
+ end
14
+ end
15
+ end
16
+
17
+ module Opentelemetry
18
+ module Proto
19
+ module Collector
20
+ module Trace
21
+ module V1
22
+ ExportTraceServiceRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest").msgclass
23
+ ExportTraceServiceResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse").msgclass
24
+ end
25
+ end
26
+ end
27
+ end
28
+ end
@@ -0,0 +1,52 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: opentelemetry/proto/common/v1/common.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ Google::Protobuf::DescriptorPool.generated_pool.build do
7
+ add_file("opentelemetry/proto/common/v1/common.proto", :syntax => :proto3) do
8
+ add_message "opentelemetry.proto.common.v1.AnyValue" do
9
+ oneof :value do
10
+ optional :string_value, :string, 1
11
+ optional :bool_value, :bool, 2
12
+ optional :int_value, :int64, 3
13
+ optional :double_value, :double, 4
14
+ optional :array_value, :message, 5, "opentelemetry.proto.common.v1.ArrayValue"
15
+ optional :kvlist_value, :message, 6, "opentelemetry.proto.common.v1.KeyValueList"
16
+ end
17
+ end
18
+ add_message "opentelemetry.proto.common.v1.ArrayValue" do
19
+ repeated :values, :message, 1, "opentelemetry.proto.common.v1.AnyValue"
20
+ end
21
+ add_message "opentelemetry.proto.common.v1.KeyValueList" do
22
+ repeated :values, :message, 1, "opentelemetry.proto.common.v1.KeyValue"
23
+ end
24
+ add_message "opentelemetry.proto.common.v1.KeyValue" do
25
+ optional :key, :string, 1
26
+ optional :value, :message, 2, "opentelemetry.proto.common.v1.AnyValue"
27
+ end
28
+ add_message "opentelemetry.proto.common.v1.StringKeyValue" do
29
+ optional :key, :string, 1
30
+ optional :value, :string, 2
31
+ end
32
+ add_message "opentelemetry.proto.common.v1.InstrumentationLibrary" do
33
+ optional :name, :string, 1
34
+ optional :version, :string, 2
35
+ end
36
+ end
37
+ end
38
+
39
+ module Opentelemetry
40
+ module Proto
41
+ module Common
42
+ module V1
43
+ AnyValue = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.common.v1.AnyValue").msgclass
44
+ ArrayValue = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.common.v1.ArrayValue").msgclass
45
+ KeyValueList = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.common.v1.KeyValueList").msgclass
46
+ KeyValue = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.common.v1.KeyValue").msgclass
47
+ StringKeyValue = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.common.v1.StringKeyValue").msgclass
48
+ InstrumentationLibrary = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.common.v1.InstrumentationLibrary").msgclass
49
+ end
50
+ end
51
+ end
52
+ end
@@ -0,0 +1,24 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: opentelemetry/proto/resource/v1/resource.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ require 'opentelemetry/proto/common/v1/common_pb'
7
+ Google::Protobuf::DescriptorPool.generated_pool.build do
8
+ add_file("opentelemetry/proto/resource/v1/resource.proto", :syntax => :proto3) do
9
+ add_message "opentelemetry.proto.resource.v1.Resource" do
10
+ repeated :attributes, :message, 1, "opentelemetry.proto.common.v1.KeyValue"
11
+ optional :dropped_attributes_count, :uint32, 2
12
+ end
13
+ end
14
+ end
15
+
16
+ module Opentelemetry
17
+ module Proto
18
+ module Resource
19
+ module V1
20
+ Resource = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.resource.v1.Resource").msgclass
21
+ end
22
+ end
23
+ end
24
+ end
@@ -0,0 +1,97 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: opentelemetry/proto/trace/v1/trace.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ require 'opentelemetry/proto/common/v1/common_pb'
7
+ require 'opentelemetry/proto/resource/v1/resource_pb'
8
+ Google::Protobuf::DescriptorPool.generated_pool.build do
9
+ add_file("opentelemetry/proto/trace/v1/trace.proto", :syntax => :proto3) do
10
+ add_message "opentelemetry.proto.trace.v1.ResourceSpans" do
11
+ optional :resource, :message, 1, "opentelemetry.proto.resource.v1.Resource"
12
+ repeated :instrumentation_library_spans, :message, 2, "opentelemetry.proto.trace.v1.InstrumentationLibrarySpans"
13
+ end
14
+ add_message "opentelemetry.proto.trace.v1.InstrumentationLibrarySpans" do
15
+ optional :instrumentation_library, :message, 1, "opentelemetry.proto.common.v1.InstrumentationLibrary"
16
+ repeated :spans, :message, 2, "opentelemetry.proto.trace.v1.Span"
17
+ end
18
+ add_message "opentelemetry.proto.trace.v1.Span" do
19
+ optional :trace_id, :bytes, 1
20
+ optional :span_id, :bytes, 2
21
+ optional :trace_state, :string, 3
22
+ optional :parent_span_id, :bytes, 4
23
+ optional :name, :string, 5
24
+ optional :kind, :enum, 6, "opentelemetry.proto.trace.v1.Span.SpanKind"
25
+ optional :start_time_unix_nano, :fixed64, 7
26
+ optional :end_time_unix_nano, :fixed64, 8
27
+ repeated :attributes, :message, 9, "opentelemetry.proto.common.v1.KeyValue"
28
+ optional :dropped_attributes_count, :uint32, 10
29
+ repeated :events, :message, 11, "opentelemetry.proto.trace.v1.Span.Event"
30
+ optional :dropped_events_count, :uint32, 12
31
+ repeated :links, :message, 13, "opentelemetry.proto.trace.v1.Span.Link"
32
+ optional :dropped_links_count, :uint32, 14
33
+ optional :status, :message, 15, "opentelemetry.proto.trace.v1.Status"
34
+ end
35
+ add_message "opentelemetry.proto.trace.v1.Span.Event" do
36
+ optional :time_unix_nano, :fixed64, 1
37
+ optional :name, :string, 2
38
+ repeated :attributes, :message, 3, "opentelemetry.proto.common.v1.KeyValue"
39
+ optional :dropped_attributes_count, :uint32, 4
40
+ end
41
+ add_message "opentelemetry.proto.trace.v1.Span.Link" do
42
+ optional :trace_id, :bytes, 1
43
+ optional :span_id, :bytes, 2
44
+ optional :trace_state, :string, 3
45
+ repeated :attributes, :message, 4, "opentelemetry.proto.common.v1.KeyValue"
46
+ optional :dropped_attributes_count, :uint32, 5
47
+ end
48
+ add_enum "opentelemetry.proto.trace.v1.Span.SpanKind" do
49
+ value :SPAN_KIND_UNSPECIFIED, 0
50
+ value :INTERNAL, 1
51
+ value :SERVER, 2
52
+ value :CLIENT, 3
53
+ value :PRODUCER, 4
54
+ value :CONSUMER, 5
55
+ end
56
+ add_message "opentelemetry.proto.trace.v1.Status" do
57
+ optional :code, :enum, 1, "opentelemetry.proto.trace.v1.Status.StatusCode"
58
+ optional :message, :string, 2
59
+ end
60
+ add_enum "opentelemetry.proto.trace.v1.Status.StatusCode" do
61
+ value :Ok, 0
62
+ value :Cancelled, 1
63
+ value :UnknownError, 2
64
+ value :InvalidArgument, 3
65
+ value :DeadlineExceeded, 4
66
+ value :NotFound, 5
67
+ value :AlreadyExists, 6
68
+ value :PermissionDenied, 7
69
+ value :ResourceExhausted, 8
70
+ value :FailedPrecondition, 9
71
+ value :Aborted, 10
72
+ value :OutOfRange, 11
73
+ value :Unimplemented, 12
74
+ value :InternalError, 13
75
+ value :Unavailable, 14
76
+ value :DataLoss, 15
77
+ value :Unauthenticated, 16
78
+ end
79
+ end
80
+ end
81
+
82
+ module Opentelemetry
83
+ module Proto
84
+ module Trace
85
+ module V1
86
+ ResourceSpans = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.trace.v1.ResourceSpans").msgclass
87
+ InstrumentationLibrarySpans = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.trace.v1.InstrumentationLibrarySpans").msgclass
88
+ Span = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.trace.v1.Span").msgclass
89
+ Span::Event = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.trace.v1.Span.Event").msgclass
90
+ Span::Link = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.trace.v1.Span.Link").msgclass
91
+ Span::SpanKind = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.trace.v1.Span.SpanKind").enummodule
92
+ Status = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.trace.v1.Status").msgclass
93
+ Status::StatusCode = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("opentelemetry.proto.trace.v1.Status.StatusCode").enummodule
94
+ end
95
+ end
96
+ end
97
+ end
metadata ADDED
@@ -0,0 +1,215 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: opentelemetry-exporter-otlp
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.6.0
5
+ platform: ruby
6
+ authors:
7
+ - OpenTelemetry Authors
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2020-09-11 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: google-protobuf
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: 3.4.1.1
20
+ - - "<"
21
+ - !ruby/object:Gem::Version
22
+ version: '4'
23
+ type: :runtime
24
+ prerelease: false
25
+ version_requirements: !ruby/object:Gem::Requirement
26
+ requirements:
27
+ - - ">="
28
+ - !ruby/object:Gem::Version
29
+ version: 3.4.1.1
30
+ - - "<"
31
+ - !ruby/object:Gem::Version
32
+ version: '4'
33
+ - !ruby/object:Gem::Dependency
34
+ name: opentelemetry-api
35
+ requirement: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - "~>"
38
+ - !ruby/object:Gem::Version
39
+ version: 0.6.0
40
+ type: :runtime
41
+ prerelease: false
42
+ version_requirements: !ruby/object:Gem::Requirement
43
+ requirements:
44
+ - - "~>"
45
+ - !ruby/object:Gem::Version
46
+ version: 0.6.0
47
+ - !ruby/object:Gem::Dependency
48
+ name: bundler
49
+ requirement: !ruby/object:Gem::Requirement
50
+ requirements:
51
+ - - ">="
52
+ - !ruby/object:Gem::Version
53
+ version: '1.17'
54
+ type: :development
55
+ prerelease: false
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ requirements:
58
+ - - ">="
59
+ - !ruby/object:Gem::Version
60
+ version: '1.17'
61
+ - !ruby/object:Gem::Dependency
62
+ name: faraday
63
+ requirement: !ruby/object:Gem::Requirement
64
+ requirements:
65
+ - - "~>"
66
+ - !ruby/object:Gem::Version
67
+ version: '0.13'
68
+ type: :development
69
+ prerelease: false
70
+ version_requirements: !ruby/object:Gem::Requirement
71
+ requirements:
72
+ - - "~>"
73
+ - !ruby/object:Gem::Version
74
+ version: '0.13'
75
+ - !ruby/object:Gem::Dependency
76
+ name: minitest
77
+ requirement: !ruby/object:Gem::Requirement
78
+ requirements:
79
+ - - "~>"
80
+ - !ruby/object:Gem::Version
81
+ version: '5.0'
82
+ type: :development
83
+ prerelease: false
84
+ version_requirements: !ruby/object:Gem::Requirement
85
+ requirements:
86
+ - - "~>"
87
+ - !ruby/object:Gem::Version
88
+ version: '5.0'
89
+ - !ruby/object:Gem::Dependency
90
+ name: rake
91
+ requirement: !ruby/object:Gem::Requirement
92
+ requirements:
93
+ - - "~>"
94
+ - !ruby/object:Gem::Version
95
+ version: '12.0'
96
+ type: :development
97
+ prerelease: false
98
+ version_requirements: !ruby/object:Gem::Requirement
99
+ requirements:
100
+ - - "~>"
101
+ - !ruby/object:Gem::Version
102
+ version: '12.0'
103
+ - !ruby/object:Gem::Dependency
104
+ name: rubocop
105
+ requirement: !ruby/object:Gem::Requirement
106
+ requirements:
107
+ - - "~>"
108
+ - !ruby/object:Gem::Version
109
+ version: 0.73.0
110
+ type: :development
111
+ prerelease: false
112
+ version_requirements: !ruby/object:Gem::Requirement
113
+ requirements:
114
+ - - "~>"
115
+ - !ruby/object:Gem::Version
116
+ version: 0.73.0
117
+ - !ruby/object:Gem::Dependency
118
+ name: simplecov
119
+ requirement: !ruby/object:Gem::Requirement
120
+ requirements:
121
+ - - "~>"
122
+ - !ruby/object:Gem::Version
123
+ version: '0.17'
124
+ type: :development
125
+ prerelease: false
126
+ version_requirements: !ruby/object:Gem::Requirement
127
+ requirements:
128
+ - - "~>"
129
+ - !ruby/object:Gem::Version
130
+ version: '0.17'
131
+ - !ruby/object:Gem::Dependency
132
+ name: webmock
133
+ requirement: !ruby/object:Gem::Requirement
134
+ requirements:
135
+ - - "~>"
136
+ - !ruby/object:Gem::Version
137
+ version: 3.7.6
138
+ type: :development
139
+ prerelease: false
140
+ version_requirements: !ruby/object:Gem::Requirement
141
+ requirements:
142
+ - - "~>"
143
+ - !ruby/object:Gem::Version
144
+ version: 3.7.6
145
+ - !ruby/object:Gem::Dependency
146
+ name: yard
147
+ requirement: !ruby/object:Gem::Requirement
148
+ requirements:
149
+ - - "~>"
150
+ - !ruby/object:Gem::Version
151
+ version: '0.9'
152
+ type: :development
153
+ prerelease: false
154
+ version_requirements: !ruby/object:Gem::Requirement
155
+ requirements:
156
+ - - "~>"
157
+ - !ruby/object:Gem::Version
158
+ version: '0.9'
159
+ - !ruby/object:Gem::Dependency
160
+ name: yard-doctest
161
+ requirement: !ruby/object:Gem::Requirement
162
+ requirements:
163
+ - - "~>"
164
+ - !ruby/object:Gem::Version
165
+ version: 0.1.6
166
+ type: :development
167
+ prerelease: false
168
+ version_requirements: !ruby/object:Gem::Requirement
169
+ requirements:
170
+ - - "~>"
171
+ - !ruby/object:Gem::Version
172
+ version: 0.1.6
173
+ description: OTLP exporter for the OpenTelemetry framework
174
+ email:
175
+ - cncf-opentelemetry-contributors@lists.cncf.io
176
+ executables: []
177
+ extensions: []
178
+ extra_rdoc_files: []
179
+ files:
180
+ - ".yardopts"
181
+ - CHANGELOG.md
182
+ - LICENSE
183
+ - README.md
184
+ - lib/opentelemetry-exporter-otlp.rb
185
+ - lib/opentelemetry/exporter/otlp.rb
186
+ - lib/opentelemetry/exporter/otlp/exporter.rb
187
+ - lib/opentelemetry/exporter/otlp/version.rb
188
+ - lib/opentelemetry/proto/collector/trace/v1/trace_service_pb.rb
189
+ - lib/opentelemetry/proto/common/v1/common_pb.rb
190
+ - lib/opentelemetry/proto/resource/v1/resource_pb.rb
191
+ - lib/opentelemetry/proto/trace/v1/trace_pb.rb
192
+ homepage: https://github.com/open-telemetry/opentelemetry-ruby
193
+ licenses:
194
+ - Apache-2.0
195
+ metadata: {}
196
+ post_install_message:
197
+ rdoc_options: []
198
+ require_paths:
199
+ - lib
200
+ required_ruby_version: !ruby/object:Gem::Requirement
201
+ requirements:
202
+ - - ">="
203
+ - !ruby/object:Gem::Version
204
+ version: 2.5.0
205
+ required_rubygems_version: !ruby/object:Gem::Requirement
206
+ requirements:
207
+ - - ">="
208
+ - !ruby/object:Gem::Version
209
+ version: '0'
210
+ requirements: []
211
+ rubygems_version: 3.1.2
212
+ signing_key:
213
+ specification_version: 4
214
+ summary: OTLP exporter for the OpenTelemetry framework
215
+ test_files: []