Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Publisher confirms #14

Open
podung opened this issue May 13, 2016 · 1 comment
Open

Publisher confirms #14

podung opened this issue May 13, 2016 · 1 comment

Comments

@podung
Copy link
Contributor

podung commented May 13, 2016

Split out from issue #11

I would like to see publisher confirms added to the library, to support the acks/nacks from the server when putting an item on the queue. There would need to be an api to configure that certain messages should fail to be acked from the server:

connection = MockBunny.new.start
channel = connection.create_channel
exchange = channel.direct(:some_exchange)

expect(exchange).to receive(:publish).with(some_data).and_nack

exchange.publish(some_data)

expect(channel.wait_for_confirms).to eq false
expect(channel.nacked_items.count).to be 1

I'll work on a PR soon. Any thoughts on the API or how it should work for exchanges vs queues would be great.

@baelter
Copy link
Contributor

baelter commented Jun 13, 2016

Added stub for wait_for_confirms in #20

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

No branches or pull requests

2 participants