Skip to content
This repository has been archived by the owner on Mar 29, 2022. It is now read-only.

the value returned from "Pwwka::Receiver.subscribe" is unusable when supplied "block: false" argument #107

Open
laser opened this issue Jul 27, 2021 · 0 comments

Comments

@laser
Copy link

laser commented Jul 27, 2021

Problem

The Pwwka::Receiver.subscribe class method creates a new Pwwka::Receiver which executed the provided handler once per message delivered to a queue (which it creates) bound to each routing key in the routing_key argument. If the block: false argument is provided, the Bunny subscription should be created in a non-blocking fashion, i.e. the call to Bunny::Queue#subscribe should return immediately, and the Pwwka::Receiver should be returned.

Unfortunately, the Pwwka::Receiver.subscribe's ensure block closes the underlying connection before the receiver is returned, rendering the receiver unusable.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant