예제 #1
0
파일: logs.py 프로젝트: dsg101/openquake
    def __init__(self, level=logging.NOTSET):
        logging.Handler.__init__(self, level=level)
        self.connection = None
        self.channel = None

        self.connection, self.channel, self.exchange = amqp_connect()
        self.producer = kombu.messaging.Producer(self.channel, self.exchange,
                                                 serializer='json')
예제 #2
0
파일: logs.py 프로젝트: angri/openquake
 def _initialize():
     """Initialize amqp artefacts."""
     _, channel, exchange = amqp_connect()
     return kombu.messaging.Producer(channel, exchange, serializer='json')
예제 #3
0
파일: logs.py 프로젝트: pslh/oq-engine
 def _initialize():
     """Initialize amqp artefacts."""
     _, channel, exchange = amqp_connect()
     return kombu.messaging.Producer(channel, exchange, serializer='json')