Added more stuff to results
This commit is contained in:
@@ -22,11 +22,12 @@ def message_callback(channel, method, properties, body):
|
||||
with start_transaction(op="cnn-classification-service", name="classify-soundfile"):
|
||||
results = MagicDoer.run_everything(msg) # <- This is where the magic happens
|
||||
|
||||
channel.basic_publish(
|
||||
exchange=os.environ['PIKA_OUTPUT_EXCHANGE'],
|
||||
routing_key='classification-result',
|
||||
body=json.dumps(results).encode("utf-8")
|
||||
)
|
||||
if results:
|
||||
channel.basic_publish(
|
||||
exchange=os.environ['PIKA_OUTPUT_EXCHANGE'],
|
||||
routing_key='classification-result',
|
||||
body=json.dumps(results).encode("utf-8")
|
||||
)
|
||||
|
||||
|
||||
def main():
|
||||
|
||||
Reference in New Issue
Block a user