sbmt-outbox 6.10.0 → 6.10.1

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: e9c1d6731755da78bfaf755eb229d0b0574cb305aa09be61ff4b582297be40ca
4
- data.tar.gz: 33e1cc5bf44df4ab4fa85ed41552c86a5990bc4570c3019408800359823cc432
3
+ metadata.gz: 563533826523f381bff35759aecedd3f1b5ed4e20067725e7f28d0a94808ab89
4
+ data.tar.gz: 3a974ff0df4cf3a771888b521d33e9d5b5df367973b9a43fc6dfd4f6418caed0
5
5
  SHA512:
6
- metadata.gz: '09554fa859af8e022eb5b48ed2595ee34fa946bd4d43bf22b83435f5fbffd57eba30cde7324eebd8e282132ec98d10379e939d2e257727f309fec77a67f3b041'
7
- data.tar.gz: ed32aa05783c3a83ee92ae9a30e6d059d608ecfe0451c95a8b6ab7e72bda4a6deb6684489cc69ca83b28322e1fb58cce9438868909db18fc2f33424c68e4e748
6
+ metadata.gz: 4af541b2e8db7fa1fec41071caf150a1df4e973a1f93bfc2491288d0d4fe69a49d20cc9ebd96dcb378d0b6cc381baef68b8dbd5cfde8fdb062730125fdcac120
7
+ data.tar.gz: 8274526f2a1c4fa433a20787ef14b07b83de4d11fa5d87f9ba30c7639bbb1396d4ae0fcec6d07493336d050ff757324e9bf88d14495e1ac803c1bf074a71734b
@@ -28,7 +28,9 @@ module Sbmt
28
28
  extracted_context = ::OpenTelemetry.propagation.extract(item_options_headers)
29
29
  ::OpenTelemetry::Context.with_current(extracted_context) do
30
30
  tracer.in_span(span_name(item_class), attributes: span_attributes.compact, kind: :consumer) do
31
- yield
31
+ Sbmt::Outbox.logger.with_tags(trace_id: trace_id) do
32
+ yield
33
+ end
32
34
  end
33
35
  end
34
36
  end
@@ -42,6 +44,12 @@ module Sbmt
42
44
  def span_name(item_class)
43
45
  "#{item_class.box_type}/#{item_class.box_name} process item"
44
46
  end
47
+
48
+ def trace_id
49
+ context = ::OpenTelemetry::Trace.current_span.context
50
+
51
+ context.valid? ? context.hex_trace_id : nil
52
+ end
45
53
  end
46
54
  end
47
55
  end
@@ -16,7 +16,6 @@ module Sbmt
16
16
 
17
17
  # transaction will be nil if sentry tracing is not enabled
18
18
  transaction = start_transaction(scope, job)
19
- job.log_tags[:trace_id] = scope&.tags&.[](:trace_id)
20
19
 
21
20
  begin
22
21
  yield
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Sbmt
4
4
  module Outbox
5
- VERSION = "6.10.0"
5
+ VERSION = "6.10.1"
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sbmt-outbox
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.10.0
4
+ version: 6.10.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sbermarket Ruby-Platform Team
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-09-23 00:00:00.000000000 Z
11
+ date: 2024-09-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: connection_pool
@@ -640,7 +640,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
640
640
  - !ruby/object:Gem::Version
641
641
  version: '0'
642
642
  requirements: []
643
- rubygems_version: 3.5.19
643
+ rubygems_version: 3.1.6
644
644
  signing_key:
645
645
  specification_version: 4
646
646
  summary: Outbox service