librabbitmq
librabbitmq copied to clipboard
Missing exchange_bind implementation
librabbitmq does not implement exchange_bind for the Channel object. This is especially visible when using Kombu.
Versions:
librabbitmq==2.0.0kombu==4.6.7
Bug:
from kombu import Connection, Exchange
conn = Connection("amqp://user:password@host//")
conn.transport_cls # yields librabbitmq
Exchange("some_exchange", channel=conn.channel()).declare()
Exchange("some_exchange", channel=conn.channel()).bind_to("amq.topic", routing_key="some_key")
# raises AttributeError: 'Channel' object has no attribute 'exchange_bind'
Using pyamqp to demonstrate the expected behaviour:
from kombu import Connection, Exchange
conn = Connection("amqp://user:password@host//", transport="pyamqp")
conn.transport_cls # yields pyamqp
Exchange("some_exchange", channel=conn.channel()).declare()
Exchange("some_exchange", channel=conn.channel()).bind_to("amq.topic", routing_key="some_key")
PRs welcome.