lib/cotton_tail/queue/bunny.rb in cotton-tail-0.5.0 vs lib/cotton_tail/queue/bunny.rb in cotton-tail-0.6.0
- old
+ new
@@ -28,14 +28,15 @@
bind request.routing_key
exchange.publish request.payload, routing_key: request.routing_key
end
def pop
- Request.new(*super)
+ delivery_info, properties, payload = super
+ Request.new(delivery_info, MessageProperties.new(properties.to_h), payload)
end
def bind(routing_key)
- source.bind('amq.topic', routing_key: routing_key)
+ source.bind('amq.topic', routing_key: Route.new(routing_key).binding)
end
private
attr_reader :connection