This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import socket | |
import asyncio | |
from aio_pika import connect, Connection | |
from yarl import URL | |
AMQP_URL = URL(os.getenv("AMQP_URL", "amqp://guest:guest@localhost")) | |
if not AMQP_URL.path: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import logging | |
from graypy import GELFHandler | |
chunk_size = 1 | |
handler = GELFHandler('127.0.0.1', compress=False, chunk_size=chunk_size) | |
logger = logging.getLogger() | |
logger.addHandler(handler) |