opentelemetry-exporter-jaeger 0.11.0 → 0.16.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 848703d712cf95041d24a3bea79822392a41aeb2f31969586d76a4284cf1a3f9
4
- data.tar.gz: 6473f43ecc99f1fcfecbe5b44d02c96ad14a81477d52dbf8e824cf08468a0247
3
+ metadata.gz: 036d3930a2fb775518f76fd5c5ac507e7479753928e135fcb412c0c66c40744b
4
+ data.tar.gz: 6b7df47b9e09f7b1f8d89d419579f9ca2aa670c39e17c3a242132b4dce20f022
5
5
  SHA512:
6
- metadata.gz: ae9eabba37cd413ecfdc4e51cb5d9b009a34860d7fe951fa494899d9ae23b779b2d8fe8442350c350a9975da8895d1404f9a3603a6b69d7f9e2fa26b05286d2f
7
- data.tar.gz: 47aa3c269bc97346d3ad562e328dcd153202561f8e22e11b29fbdbde0ac2c50edea77f3fc40d183ca29656c98bfdf4e8d88f30a9bac6535699765bf3a7c42dc0
6
+ metadata.gz: 546bfecdf9012825b5caf697070aaa605d2fb4b8513f4e1d0102f2acbeb68ce007284cd3bca3860701169ad40d5d4ba6e2457a3e3503c7e347d940ce2b35857b
7
+ data.tar.gz: 5e19582e2fd76d6ae072b20f51ddeda54bb24de2157b9986d64fe5c15e1d911eaf41f694bd5e3975020eed64895e1e7d8bb86caf3f9d67e4d071f1cd27aafe08
data/CHANGELOG.md CHANGED
@@ -1,5 +1,32 @@
1
1
  # Release History: opentelemetry-exporter-jaeger
2
2
 
3
+ ### v0.16.0 / 2021-03-17
4
+
5
+ * BREAKING CHANGE: Implement Exporter#force_flush
6
+
7
+ * ADDED: Implement Exporter#force_flush
8
+ * DOCS: Replace Gitter with GitHub Discussions
9
+
10
+ ### v0.15.0 / 2021-02-18
11
+
12
+ * BREAKING CHANGE: Streamline processor pipeline
13
+
14
+ * FIXED: Streamline processor pipeline
15
+
16
+ ### v0.14.0 / 2021-02-03
17
+
18
+ * (No significant changes)
19
+
20
+ ### v0.13.0 / 2021-01-29
21
+
22
+ * ADDED: Provide default resource in SDK
23
+ * ADDED: Add untraced wrapper to common utils
24
+ * FIXED: Jaeger ref type should be FOLLOWS_FROM
25
+
26
+ ### v0.12.0 / 2020-12-24
27
+
28
+ * ADDED: Structured error handling
29
+
3
30
  ### v0.11.0 / 2020-12-11
4
31
 
5
32
  * FIXED: Copyright comments to not reference year
data/README.md CHANGED
@@ -35,7 +35,7 @@ require 'opentelemetry/exporter/jaeger'
35
35
  OpenTelemetry::SDK.configure do |c|
36
36
  c.add_span_processor(
37
37
  OpenTelemetry::SDK::Trace::Export::BatchSpanProcessor.new(
38
- exporter: OpenTelemetry::Exporter::Jaeger::AgentExporter.new(host: '127.0.0.1', port: 6831)
38
+ OpenTelemetry::Exporter::Jaeger::AgentExporter.new(host: '127.0.0.1', port: 6831)
39
39
  # Alternatively, for the collector exporter:
40
40
  # exporter: OpenTelemetry::Exporter::Jaeger::CollectorExporter.new(endpoint: 'http://192.168.0.1:14268/api/traces')
41
41
  )
@@ -85,7 +85,7 @@ The collector exporter can be configured explicitly in code, as shown above, or
85
85
 
86
86
  The `opentelemetry-exporter-jaeger` gem source is [on github][repo-github], along with related gems including `opentelemetry-sdk`.
87
87
 
88
- 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].
88
+ The OpenTelemetry Ruby gems are maintained by the OpenTelemetry-Ruby special interest group (SIG). You can get involved by joining us in [GitHub Discussions][discussions-url] 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].
89
89
 
90
90
  ## License
91
91
 
@@ -96,8 +96,8 @@ The `opentelemetry-exporter-jaeger` gem is distributed under the Apache 2.0 lice
96
96
  [opentelemetry-home]: https://opentelemetry.io
97
97
  [bundler-home]: https://bundler.io
98
98
  [repo-github]: https://github.com/open-telemetry/opentelemetry-ruby
99
- [license-github]: https://github.com/open-telemetry/opentelemetry-ruby/blob/master/LICENSE
100
- [examples-github]: https://github.com/open-telemetry/opentelemetry-ruby/tree/master/examples
99
+ [license-github]: https://github.com/open-telemetry/opentelemetry-ruby/blob/main/LICENSE
100
+ [examples-github]: https://github.com/open-telemetry/opentelemetry-ruby/tree/main/examples
101
101
  [ruby-sig]: https://github.com/open-telemetry/community#ruby-sig
102
102
  [community-meetings]: https://github.com/open-telemetry/community#community-meetings
103
- [ruby-gitter]: https://gitter.im/open-telemetry/opentelemetry-ruby
103
+ [discussions-url]: https://github.com/open-telemetry/opentelemetry-ruby/discussions
@@ -43,13 +43,23 @@ module OpenTelemetry
43
43
  end
44
44
  end
45
45
 
46
- # Called when {OpenTelemetry::SDK::Trace::Tracer#shutdown} is called, if
47
- # this exporter is registered to a {OpenTelemetry::SDK::Trace::Tracer}
46
+ # Called when {OpenTelemetry::SDK::Trace::TracerProvider#force_flush} is called, if
47
+ # this exporter is registered to a {OpenTelemetry::SDK::Trace::TracerProvider}
48
+ # object.
49
+ #
50
+ # @param [optional Numeric] timeout An optional timeout in seconds.
51
+ def force_flush(timeout: nil)
52
+ SUCCESS
53
+ end
54
+
55
+ # Called when {OpenTelemetry::SDK::Trace::TracerProvider#shutdown} is called, if
56
+ # this exporter is registered to a {OpenTelemetry::SDK::Trace::TracerProvider}
48
57
  # object.
49
58
  #
50
59
  # @param [optional Numeric] timeout An optional timeout in seconds.
51
60
  def shutdown(timeout: nil)
52
61
  @shutdown = true
62
+ SUCCESS
53
63
  end
54
64
 
55
65
  private
@@ -45,22 +45,32 @@ module OpenTelemetry
45
45
  @transport.write(@serializer.serialize(batch))
46
46
  end
47
47
 
48
- untraced do
48
+ OpenTelemetry::Common::Utilities.untraced do
49
49
  @transport.flush
50
50
  end
51
51
  SUCCESS
52
52
  rescue StandardError => e
53
- OpenTelemetry.logger.error("unexpected error in Jaeger::CollectorExporter#export - #{e}")
53
+ OpenTelemetry.handle_error(exception: e, message: 'unexpected error in Jaeger::CollectorExporter#export')
54
54
  FAILURE
55
55
  end
56
56
 
57
- # Called when {OpenTelemetry::SDK::Trace::Tracer#shutdown} is called, if
58
- # this exporter is registered to a {OpenTelemetry::SDK::Trace::Tracer}
57
+ # Called when {OpenTelemetry::SDK::Trace::TracerProvider#force_flush} is called, if
58
+ # this exporter is registered to a {OpenTelemetry::SDK::Trace::TracerProvider}
59
+ # object.
60
+ #
61
+ # @param [optional Numeric] timeout An optional timeout in seconds.
62
+ def force_flush(timeout: nil)
63
+ SUCCESS
64
+ end
65
+
66
+ # Called when {OpenTelemetry::SDK::Trace::TracerProvider#shutdown} is called, if
67
+ # this exporter is registered to a {OpenTelemetry::SDK::Trace::TracerProvider}
59
68
  # object.
60
69
  #
61
70
  # @param [optional Numeric] timeout An optional timeout in seconds.
62
71
  def shutdown(timeout: nil)
63
72
  @shutdown = true
73
+ SUCCESS
64
74
  end
65
75
 
66
76
  private
@@ -74,10 +84,6 @@ module OpenTelemetry
74
84
  true
75
85
  end
76
86
 
77
- def untraced
78
- OpenTelemetry::Trace.with_span(OpenTelemetry::Trace::Span.new) { yield }
79
- end
80
-
81
87
  def encoded_batches(span_data)
82
88
  span_data.group_by(&:resource).map do |resource, spans|
83
89
  process = Encoder.encoded_process(resource)
@@ -30,10 +30,11 @@ module OpenTelemetry
30
30
  OpenTelemetry::Trace::SpanKind::PRODUCER => 'producer',
31
31
  OpenTelemetry::Trace::SpanKind::CONSUMER => 'consumer'
32
32
  }.freeze
33
- private_constant(:EMPTY_ARRAY, :LONG, :DOUBLE, :STRING, :BOOL, :KEY, :TYPE, :TYPE_MAP, :KIND_MAP)
33
+ DEFAULT_SERVICE_NAME = OpenTelemetry::SDK::Resources::Resource.default.attribute_enumerator.find { |k, _| k == 'service.name' }&.last || 'unknown_service'
34
+ private_constant(:EMPTY_ARRAY, :LONG, :DOUBLE, :STRING, :BOOL, :KEY, :TYPE, :TYPE_MAP, :KIND_MAP, :DEFAULT_SERVICE_NAME)
34
35
 
35
36
  def encoded_process(resource)
36
- service_name = 'unknown'
37
+ service_name = DEFAULT_SERVICE_NAME
37
38
  tags = resource&.attribute_enumerator&.select do |key, value|
38
39
  service_name = value if key == 'service.name'
39
40
  key != 'service.name'
@@ -110,7 +111,7 @@ module OpenTelemetry
110
111
  def encoded_references(links)
111
112
  links&.map do |link|
112
113
  Thrift::SpanRef.new(
113
- 'refType' => Thrift::SpanRefType::CHILD_OF,
114
+ 'refType' => Thrift::SpanRefType::FOLLOWS_FROM,
114
115
  'traceIdLow' => int64(link.span_context.trace_id[16, 16]),
115
116
  'traceIdHigh' => int64(link.span_context.trace_id[0, 16]),
116
117
  'spanId' => int64(link.span_context.span_id)
@@ -8,7 +8,7 @@ module OpenTelemetry
8
8
  module Exporter
9
9
  module Jaeger
10
10
  ## Current OpenTelemetry Jaeger exporter version
11
- VERSION = '0.11.0'
11
+ VERSION = '0.16.0'
12
12
  end
13
13
  end
14
14
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: opentelemetry-exporter-jaeger
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.0
4
+ version: 0.16.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - OpenTelemetry Authors
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-12-11 00:00:00.000000000 Z
11
+ date: 2021-03-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: opentelemetry-api
@@ -16,28 +16,28 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 0.11.0
19
+ version: 0.16.0
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 0.11.0
26
+ version: 0.16.0
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: opentelemetry-common
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: 0.11.0
33
+ version: 0.16.0
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: 0.11.0
40
+ version: 0.16.0
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: thrift
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -209,10 +209,10 @@ homepage: https://github.com/open-telemetry/opentelemetry-ruby
209
209
  licenses:
210
210
  - Apache-2.0
211
211
  metadata:
212
- changelog_uri: https://open-telemetry.github.io/opentelemetry-ruby/opentelemetry-exporter-jaeger/v0.11.0/file.CHANGELOG.html
213
- source_code_uri: https://github.com/open-telemetry/opentelemetry-ruby/tree/master/exporter/jaeger
212
+ changelog_uri: https://open-telemetry.github.io/opentelemetry-ruby/opentelemetry-exporter-jaeger/v0.16.0/file.CHANGELOG.html
213
+ source_code_uri: https://github.com/open-telemetry/opentelemetry-ruby/tree/main/exporter/jaeger
214
214
  bug_tracker_uri: https://github.com/open-telemetry/opentelemetry-ruby/issues
215
- documentation_uri: https://open-telemetry.github.io/opentelemetry-ruby/opentelemetry-exporter-jaeger/v0.11.0
215
+ documentation_uri: https://open-telemetry.github.io/opentelemetry-ruby/opentelemetry-exporter-jaeger/v0.16.0
216
216
  post_install_message:
217
217
  rdoc_options: []
218
218
  require_paths: