- Support Channels 4
- Try and forestall an error during reconnect. Connecting to RabbitMQ Node B
after Node A went offline sometimes led to
group_add()
failures. - Bump carehare to v1.0.0
Upgrade instructions from v3.x
- In accordance with RabbitMQ's URI specification,
/
is no longer allowed as the last character in anamqp
URL. If yourhost
ends with/
, delete the/
.
- Drop support for
async_to_sync()
withoutsync_to_async()
. If you have been using channels_rabbitmq to open a new RabbitMQ connection per message, you'll now get a RuntimeError. Rationale - Switched to carehare, so now we:
- Expose errors. An error in the channel layers will be logged. (Previously, it could lead to a frozen layer.)
- Release unawaited tasks and futures. Now, callers must await all futures. (Previously, there were missing warnings when callers didn't await.)
- Expose
get_channel_layer().carehare_connection
: a Future Connection. (It resets to a new Future upon disconnect.)
- Added
await get_channel_layer().close()
, for clean shutdowns. On shutdown, all consumers will seeStopConsuming
. (This is not in the Channel Layers Specification.) - Stopped monkey-patching event-loop close. Now, ending the Python process
without calling
await get_channel_layer().close()
may warn about unawaited coroutines. Use ASGI Lifespan to fix the warnings.
Upgrade instructions from v2.x
- Upgrade to Python 3.8 or higher.
- Ensure your
host
andssl_context
agree. If you usessl_context
, yourhost
must begin withamqps://
; otherwise,amqp://
. - Ensure you do not call
async_to_sync()
outside ofsync_to_async()
.
local_capacity
now counts messages. (Before, it was counting how many.get()
calls were pending.)prefetch_count
no longer exists. It was confusing when combined withlocal_capacity
.- Switched to aiormq, which is better-maintained.
- Upgraded msgpack to v1.
Upgrade instructions from v1.x
- If you have configured
prefetch_count
, delete it. - Upgrade to Python 3.7 or higher.
- Upgrade to Django-Channels 3.0 or higher.
- Fix package __version__ metadata, which prevented some users from installing v1.3.0. [issue #30] [PR #31]
- Fix async_to_sync() behavior on Python 3.6 and 3.7.
- Don't crash when called in async_to_sync() on asgiref >= 3.2.4
- Nix some deprecation warnings
- Allow installing alongside django-channels 3.0. [issue #29]
- Fix race when sending to group. [issue #23]
- Support Python 3.8 (upgrade to aioamqp=0.14.0) [issue #20] [PR #21]
- Deprecate
group_expiry
[issue #18] [PR #19]. Rationale: django/channels#1371
Users who previously configured a group_expiry
should remove it. It will
produce a deprecation warning, and it will be disallowed starting in v2.0.0.
- Allow asgiref=3.2.1. [issue #15]
- Avoid race which could drop messages and hang publish(). [issue #14]
- Warn when back-pressuring. Back-pressuring can make a web server unresponsive, even though it's behaving according to spec.
- Expire messages after receiving them from RabbitMQ but before
receive()
. Warn when expiring. Allows recovery after messages are sent to nonexistent channels.
- Make
groups_exchange
configurable [issue #12]
- Retry after
declare_queue
errors during reconnect [issue #9]
- Add
ssl_context
configuration option [issue #2] - Upgrade to aioamqp 0.13
- Avoid a 'Connection lost exc=None' warning when disconnecting from a thread with its own event loop [issue #4]
- Experimental support for Python 3.5. (There's no test coverage; use at your own risk!)
channels_rabbitmq
has been humming on production long enough that it
deserves the badge, "1.0".
asgiref
has seen a major version bump. channels_rabbitmq
doesn't rely
on any of that changed code, but it does need newer dependencies so it can be
installed alongside the latest versions of channels
and daphne
.
- Bump asgiref to 3.1 and channels to 2.2.
- Bump msgpack from 0.5.2 to 0.6.1