exchange name configurable
This commit is contained in:
@ -41,7 +41,7 @@ def main():
|
||||
queue_declare_result = channel.queue_declare(queue='', exclusive=True)
|
||||
queue_name = queue_declare_result.method.queue
|
||||
|
||||
channel.queue_bind(exchange='wave-extract', queue=queue_name)
|
||||
channel.queue_bind(exchange=os.environ['PIKA_EXCHANGE_NAME'], queue=queue_name)
|
||||
channel.basic_consume(queue=queue_name, on_message_callback=message_callback, auto_ack=True)
|
||||
|
||||
logging.info("Connection complete! Listening to messages...")
|
||||
|
Reference in New Issue
Block a user