mentat.daemon.component.commiter module

Daemon component that is commiting all messages. It is intended to be used at the end of the message processing chain and it will emit the ‘message_commit’ event for any message it receives.

The implementation is based on pyzenkit.zendaemon.ZenDaemonComponent

class mentat.daemon.component.commiter.CommiterDaemonComponent(**kwargs)[source]

Bases: ZenDaemonComponent

Implementation of ZenDaemonComponent commiting all messages.

EVENT_LOG_STATISTICS = 'log_statistics'
EVENT_MSG_PROCESS = 'message_process'
STATS_CNT_COMMITS = 'cnt_commits'
cbk_event_log_statistics(daemon, args)[source]

Periodical processing statistics logging.

cbk_event_message_process(daemon, args)[source]

Schedule event for commiting given message.

get_events()[source]

Get the list of event names and their appropriate callback handlers.