bunny 2.24.0 → 3.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +15 -9
- data/lib/bunny/channel.rb +727 -124
- data/lib/bunny/concurrent/exception_accumulator.rb +115 -0
- data/lib/bunny/consumer.rb +2 -11
- data/lib/bunny/cruby/socket.rb +33 -1
- data/lib/bunny/cruby/ssl_socket.rb +41 -0
- data/lib/bunny/delivery_info.rb +22 -16
- data/lib/bunny/exceptions.rb +31 -2
- data/lib/bunny/exchange.rb +25 -13
- data/lib/bunny/get_response.rb +19 -15
- data/lib/bunny/heartbeat_sender.rb +2 -2
- data/lib/bunny/queue.rb +22 -38
- data/lib/bunny/reader_loop.rb +6 -6
- data/lib/bunny/return_info.rb +16 -11
- data/lib/bunny/session.rb +388 -36
- data/lib/bunny/timestamp.rb +1 -1
- data/lib/bunny/topology_recovery_filter.rb +71 -0
- data/lib/bunny/topology_registry.rb +824 -0
- data/lib/bunny/transport.rb +36 -9
- data/lib/bunny/version.rb +1 -1
- data/lib/bunny.rb +1 -1
- metadata +29 -7
- data/lib/bunny/versioned_delivery_tag.rb +0 -30
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: d7cc272154254919de29ea5437f5eb13c3bff2fd16b229f2fae0939982d1fe27
|
|
4
|
+
data.tar.gz: 19720fa046ac8c06ca6c7e4bb3b450979b8f9537ed8cec7c6747a26428f14a8b
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 1e604aa9511aac55434c1b458fab2ab67bb5cc454f3d8c2ada5bd910db20cb18c7382332e28e5b55d88478f7587688c80272063020ac2549fe37ee8902fade70
|
|
7
|
+
data.tar.gz: 182b111def73c1d0c25c6e4444a884703189ba7ba99c0bc39ba1db148f52210754a0da98f38ff161738db3dd647bbae5d3d78ba56dfaa6c54172803692fc58b7
|
data/README.md
CHANGED
|
@@ -43,11 +43,19 @@ Specific examples:
|
|
|
43
43
|
Web applications that display that information in the real time.
|
|
44
44
|
|
|
45
45
|
|
|
46
|
+
## Ports to Other Languages
|
|
47
|
+
|
|
48
|
+
Bunny has inspired a number of other RabbitMQ (AMQP 0-9-1) client libraries
|
|
49
|
+
that closely follow its feature set and API shape, form and ergonomics.
|
|
50
|
+
|
|
51
|
+
* [Swift 6](https://github.com/michaelklishin/bunny-swift)
|
|
52
|
+
|
|
53
|
+
|
|
46
54
|
## Supported Ruby Versions
|
|
47
55
|
|
|
48
56
|
Modern Bunny versions support
|
|
49
57
|
|
|
50
|
-
* CRuby 3.2 through
|
|
58
|
+
* CRuby 3.2 through 4.0 (inclusive)
|
|
51
59
|
* [TruffleRuby](https://www.graalvm.org/ruby/)
|
|
52
60
|
|
|
53
61
|
For environments that use TLS, Bunny expects Ruby installations to use a recent enough OpenSSL version that
|
|
@@ -57,7 +65,7 @@ For environments that use TLS, Bunny expects Ruby installations to use a recent
|
|
|
57
65
|
|
|
58
66
|
Bunny no longer supports JRuby.
|
|
59
67
|
|
|
60
|
-
JRuby users should use [March Hare](
|
|
68
|
+
JRuby users should use [March Hare](https://github.com/ruby-amqp/march_hare), which has a similar API
|
|
61
69
|
and is built on top of the RabbitMQ Java client specifically for JRuby.
|
|
62
70
|
|
|
63
71
|
|
|
@@ -87,7 +95,7 @@ may introduce, e.g. the idempotency of `queue.delete` operations.
|
|
|
87
95
|
To use Bunny in a project managed with Bundler:
|
|
88
96
|
|
|
89
97
|
``` ruby
|
|
90
|
-
gem "bunny", ">=
|
|
98
|
+
gem "bunny", ">= 3.0"
|
|
91
99
|
```
|
|
92
100
|
|
|
93
101
|
### With Rubygems
|
|
@@ -115,7 +123,9 @@ conn.start
|
|
|
115
123
|
|
|
116
124
|
# open a channel
|
|
117
125
|
ch = conn.create_channel
|
|
118
|
-
|
|
126
|
+
# enable publisher confirms with automatic tracking,
|
|
127
|
+
# see https://www.rabbitmq.com/docs/publishers#data-safety
|
|
128
|
+
ch.confirm_select(tracking: true)
|
|
119
129
|
|
|
120
130
|
# declare a queue
|
|
121
131
|
q = ch.queue("test1")
|
|
@@ -128,10 +138,6 @@ end
|
|
|
128
138
|
# publish a message to the default exchange which then gets routed to this queue
|
|
129
139
|
q.publish("Hello, everybody!")
|
|
130
140
|
|
|
131
|
-
# await confirmations from RabbitMQ, see
|
|
132
|
-
# https://www.rabbitmq.com/publishers.html#data-safety for details
|
|
133
|
-
ch.wait_for_confirms
|
|
134
|
-
|
|
135
141
|
# give the above consumer some time consume the delivery and print out the message
|
|
136
142
|
sleep 1
|
|
137
143
|
|
|
@@ -212,7 +218,7 @@ and steps to reproduce (or failing test cases).
|
|
|
212
218
|
## Other Ruby RabbitMQ Clients
|
|
213
219
|
|
|
214
220
|
The other widely used Ruby RabbitMQ client is [March Hare](http://rubymarchhare.info) (JRuby-only).
|
|
215
|
-
It's a mature library that
|
|
221
|
+
It's a mature library that requires RabbitMQ 3.3.x or later.
|
|
216
222
|
|
|
217
223
|
|
|
218
224
|
## Contributing
|