Начальная реализация транспорта ws для max web и прочие улучшения

This commit is contained in:
Alexey Polyakov
2026-04-07 12:36:30 +03:00
parent 52949602af
commit 0ffc649dd9
19 changed files with 873 additions and 228 deletions
+4 -4
View File
@@ -1,6 +1,6 @@
import asyncio
from tamtam.socket import TTMobileServer
from tamtam.websocket import TTWebSocketServer
from tamtam.socket import TamTamMobile
from tamtam.websocket import TamTamWS
from classes.controllerbase import ControllerBase
from common.config import ServerConfig
@@ -11,7 +11,7 @@ class TTController(ControllerBase):
def launch(self, api):
async def _start_all():
await asyncio.gather(
TTMobileServer(
TamTamMobile(
host=self.config.host,
port=self.config.tamtam_tcp_port,
ssl_context=api['ssl'],
@@ -19,7 +19,7 @@ class TTController(ControllerBase):
clients=api['clients'],
send_event=api['event']
).start(),
TTWebSocketServer(
TamTamWS(
host=self.config.host,
port=self.config.tamtam_ws_port,
ssl_context=api['ssl'],
+1 -1
View File
@@ -7,7 +7,7 @@ from common.rate_limiter import RateLimiter
from common.opcodes import Opcodes
from common.tools import Tools
class TTMobileServer:
class TamTamMobile:
def __init__(self, host, port, ssl_context, db_pool, clients, send_event):
self.host = host
self.port = port
+1 -1
View File
@@ -7,7 +7,7 @@ from common.rate_limiter import RateLimiter
from common.opcodes import Opcodes
from common.tools import Tools
class TTWebSocketServer:
class TamTamWS:
def __init__(self, host, port, clients, ssl_context, db_pool, send_event):
self.host = host
self.port = port