import abc
import multiprocessing as mp

from ldnode.runner.config import Settings


class Worker(abc.ABC):
    """ 工作进程基类 """
    def __init__(self, worker_name: str):
        self.worker_name = worker_name
        self.running = True
    
    @abc.abstractmethod
    def run(self, settings: Settings, input: mp.Queue, output: mp.Queue):
        """ 运行工作进程 """
        ...
