Add StdoutConsumer

This commit is contained in:
Odd Stråbø 2023-01-07 18:59:36 +01:00
parent 4d96174cfa
commit ad51e0debe

View file

@ -0,0 +1,16 @@
# -*- coding: utf-8 -*-
import json
from typing import Any, Dict
from . import BaseConsumer
class StdoutConsumer(BaseConsumer):
def __init__(self, settings: Dict[str, Any]) -> None:
super().__init__(settings)
def poll(self):
return super().poll()
def write(self, data: Dict[str, Any]):
print(json.dumps(data))