From e9777164dd21970b3cce1877628f12c3f8280a31 Mon Sep 17 00:00:00 2001 From: Steve Waterworth Date: Mon, 23 Jul 2018 12:20:20 +0100 Subject: [PATCH] pinned to 3.6 and updated to OT 2.0 --- payment/Dockerfile | 2 +- payment/payment.py | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/payment/Dockerfile b/payment/Dockerfile index d76ca00..daeb38f 100644 --- a/payment/Dockerfile +++ b/payment/Dockerfile @@ -1,4 +1,4 @@ -FROM python:2 +FROM python:3.6 # Downgraded to Python 2 due to futures package clash # Will update back to Python 3 once depency hell is fixed diff --git a/payment/payment.py b/payment/payment.py index 3f01bf7..dc59f38 100644 --- a/payment/payment.py +++ b/payment/payment.py @@ -53,9 +53,11 @@ def queueOrder(order): # RabbitMQ is not currently traced automatically # opentracing tracer is automatically set to Instana tracer # start a span - context = ot.tracer.current_context() + + # context = ot.tracer.current_context() + sspan = ot.tracer.active_span span = ot.tracer.start_span(operation_name='queue-order', - child_of=ot.tracer.current_context(), + child_of=sspan, tags={ tags.SPAN_KIND: 'producer', tags.COMPONENT: 'payment',