Skip to content

Commit a3bcdb6

Browse files
committed
fix: use at opt
1 parent 9a55176 commit a3bcdb6

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

instrumentation/sidekiq/lib/opentelemetry/instrumentation/sidekiq/middlewares/client/tracer_middleware.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ def call(_worker_class, job, _queue, _redis_pool)
2424
}
2525
attributes[SemanticConventions::Trace::PEER_SERVICE] = instrumentation_config[:peer_service] if instrumentation_config[:peer_service]
2626

27-
scheduled_at = job['scheduled_at']
27+
scheduled_at = job['at']
2828
op = scheduled_at.nil? ? "publish" : "scheduled"
2929

3030
span_name = case instrumentation_config[:span_naming]

instrumentation/sidekiq/lib/opentelemetry/instrumentation/sidekiq/middlewares/server/tracer_middleware.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ def call(_worker, msg, _queue)
3333
extracted_context = OpenTelemetry.propagation.extract(msg)
3434
created_at = time_from_timestamp(msg['created_at'])
3535
enqueued_at = time_from_timestamp(msg['created_at'])
36-
scheduled_at = time_from_timestamp(msg['scheduled_at']) unless msg['scheduled_at'].nil?
36+
scheduled_at = time_from_timestamp(msg['at']) unless msg['at'].nil?
3737
OpenTelemetry::Context.with_current(extracted_context) do
3838
if instrumentation_config[:propagation_style] == :child
3939
tracer.in_span(span_name, attributes: attributes, kind: :consumer) do |span|

0 commit comments

Comments
 (0)