gufoliftbridge 0.1.0
Gufo Liftbridge
An asynchronous Python Liftbridge client
Documentation: https://docs.gufolabs.com/gufo_liftbridge/
Source Code: https://github.com/gufolabs/gufo_liftbridge/
Gufo Liftbridge is the Python asyncio Liftbridge client library. It hides complex cluster
topology management handling tasks and the internals of the gRPC as well. Client offers
following features:
Publishing.
Subscribing.
Bulk publishing.
Cursors manipulation.
Cluster metadata fetching.
Stream creating and destroying.
Transparent data compression (own extension, may be not compatible with other clients).
Installing
pip install gufo_liftbridge
Publishing
from gufo.liftbridge.client import LiftbridgeClient
async def publish():
async with LiftbridgeClient(["127.0.0.1:9292"]) as client:
await client.publish(b"mybinarydata", stream="test", partition=0)
Subscribing
from gufo.liftbridge.client import LiftbridgeClient
async def subscribe():
async with LiftbridgeClient(["127.0.0.1:9292"]) as client:
async for msg in client.subscribe("test", partition=0):
print(f"{msg.offset}: {msg.value}")
Virtues
Clean async API.
High-performance.
Full Python typing support.
Editor completion.
Well-tested, battle-proven code.
For personal and professional use. You cannot resell or redistribute these repositories in their original state.
There are no reviews.