From 3cfb0d84fd7dd0872410d668f121243a7f75f1c7 Mon Sep 17 00:00:00 2001 From: "Felix T.J. Dietrich" Date: Sat, 17 Aug 2024 11:49:34 +0200 Subject: [PATCH] idk4 --- server/webhook-ingest/app/nats_client.py | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/server/webhook-ingest/app/nats_client.py b/server/webhook-ingest/app/nats_client.py index 9d9cf6bc..e31c377d 100644 --- a/server/webhook-ingest/app/nats_client.py +++ b/server/webhook-ingest/app/nats_client.py @@ -1,5 +1,3 @@ -import ssl - from nats.aio.client import Client as NATS from app.config import settings from app.logger import logger @@ -9,14 +7,11 @@ def __init__(self): self.nc = NATS() async def connect(self): - ssl_context = ssl.create_default_context(ssl.Purpose.CLIENT_AUTH) - ssl_context.check_hostname = False - ssl_context.verify_mode = ssl.CERT_NONE - await self.nc.connect( servers=settings.NATS_URL, token=settings.NATS_AUTH_TOKEN, - tls=ssl_context, + verbose=True, + pedantic=True, max_reconnect_attempts=-1, allow_reconnect=True, reconnect_time_wait=2,