Commit 49dacb33 authored by Jonas Waeber's avatar Jonas Waeber
Browse files

Try fix for class global Kafka Producer.

parent 2a3ce60d
Pipeline #26152 passed with stages
in 2 minutes and 14 seconds
......@@ -11,9 +11,11 @@ from requests.auth import HTTPBasicAuth
class UpdateRecordSet(Resource):
producer = KafkaProducer(bootstrap_servers=current_app.config['kafka-broker-url'],
value_serializer=lambda m: json.dumps(m, ensure_ascii=False)
.encode('utf-8'))
def __init__(self):
self.producer = KafkaProducer(bootstrap_servers=current_app.config['kafka-broker-url'],
value_serializer=lambda m: json.dumps(m, ensure_ascii=False)
.encode('utf-8'))
# Todo write/correct comment for swagger
def get(self, record_set_id):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment