From c2bdb3fd155ef55c16cfafea733c2a7e45ac79d3 Mon Sep 17 00:00:00 2001 From: Mark Veidemanis Date: Wed, 7 Sep 2022 07:20:30 +0100 Subject: [PATCH] Reformat --- docker-compose.yml | 6 +++++- sources/ingest.py | 7 +++++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index bdce2ba..ebd9d34 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -53,7 +53,6 @@ services: - ./docker/data:/var/lib/manticore - ./docker/manticore.conf:/etc/manticoresearch/manticore.conf - tmp: image: busybox command: chmod -R 777 /var/run/redis @@ -63,6 +62,11 @@ services: redis: image: redis command: redis-server /etc/redis.conf + ulimits: + nproc: 65535 + nofile: + soft: 65535 + hard: 65535 volumes: - ${PORTAINER_GIT_DIR}/docker/redis.conf:/etc/redis.conf volumes_from: diff --git a/sources/ingest.py b/sources/ingest.py index afacd53..083a085 100644 --- a/sources/ingest.py +++ b/sources/ingest.py @@ -1,13 +1,16 @@ +import asyncio + +import ujson + import db import util -import ujson -import asyncio SOURCES = ["irc"] KEYPREFIX = "queue." CHUNK_SIZE = 1000 ITER_DELAY = 0.5 + class Ingest(object): def __init__(self): name = self.__class__.__name__