No project description provided
Project description
WebSockets Groups
Модуль реализующих менеджер групп WebSocket подключений
Функционал:
- Регистрация / Удаление WS
- Создание / Удаление групп WS
- Подключение WS в группу
- Поддержка реестров: memory, redis
Quick start
Установка:
pip install websockets-groups
Подключение:
from fastapi import WebSocket
from websockets_groups import WSGroupsManager, MemoryStorage, BaseDispatcher
ws_groups_manager = WSGroupsManager(MemoryStorage())
class ChatDispatcher(BaseDispatcher):
pass
@app.websocket('/chats/')
async def ws_view(webdocket: WebSocket, chat_name: str):
await ws_groups_manager.register_ws(websocket, ChatDispatcher())
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file websockets_groups-0.0.2a1.tar.gz
.
File metadata
- Download URL: websockets_groups-0.0.2a1.tar.gz
- Upload date:
- Size: 6.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.4.2 CPython/3.8.16 Linux/5.15.0-72-generic
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 71b321cb4414efc6e61b07a485e45c4a24ce204562791a3950ba01fd294c89c9 |
|
MD5 | f725213fabb9523ae8bdb42cab4aea2e |
|
BLAKE2b-256 | 683df841c559ee48033f80cf2d6be575a97017a9d7edb10e207cbb1757e13ee0 |
File details
Details for the file websockets_groups-0.0.2a1-py3-none-any.whl
.
File metadata
- Download URL: websockets_groups-0.0.2a1-py3-none-any.whl
- Upload date:
- Size: 9.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.4.2 CPython/3.8.16 Linux/5.15.0-72-generic
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b8ba8c613ddd4789978700d21cc2073cdb170fc5b54279373e1710e78bbe9f79 |
|
MD5 | 4b78f41b7c73fa115655e53f9769ca43 |
|
BLAKE2b-256 | f37ea4551a24e900d4e6b976199f0b80b01aab59f7d77a94e0d2e467527c207e |