Skip to content

Commit

Permalink
Support swim-protocol 0.5.0
Browse files Browse the repository at this point in the history
  • Loading branch information
icgood committed Aug 13, 2023
1 parent 4ae392a commit 2e0a70c
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion pymap/__about__.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#: The package version string.
__version__ = '0.36.2'
__version__ = '0.36.3'
4 changes: 3 additions & 1 deletion pymap/cluster/swim.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
from swimprotocol.members import Member, Members
from swimprotocol.status import Status
from swimprotocol.transport import load_transport
from swimprotocol.worker import Worker


__all__ = ['transport_type', 'SwimService']
Expand Down Expand Up @@ -65,9 +66,10 @@ async def _start(self, args: Namespace, stack: AsyncExitStack) -> None:

transport = transport_type(config)
members = Members(config)
worker = Worker(config, members)
cluster_metadata.get().listen(self._local_update, members)
stack.enter_context(members.listener.on_notify(self._remote_update))
worker = await stack.enter_async_context(transport.enter(members))
await stack.enter_async_context(transport.enter(worker))
task = asyncio.create_task(worker.run())
stack.callback(task.cancel)

Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ admin = ['pymap-admin ~= 0.12.0']
macaroon = ['pymacaroons ~= 0.13.0']
redis = ['redis ~= 4.2', 'msgpack ~= 1.0']
sieve = ['sievelib ~= 1.2']
swim = ['swim-protocol ~= 0.4.0']
swim = ['swim-protocol ~= 0.5.0']
systemd = ['systemd-python']
optional = ['hiredis', 'passlib ~= 1.7', 'pid ~= 3.0']

Expand Down

0 comments on commit 2e0a70c

Please sign in to comment.