Add event-based mechanism for business decoupling | 添加基于事件的处理机制进行业务解耦
Opened this issue · 0 comments
jnan806 commented
Issue Description
Type: feature request
Describe what feature you want
Add event-based mechanism for business decoupling.
when some special events(like keepalive, error, timeout-retry, ...) occurred, push them into an or several event pool, a or several listeners listen the event pool, if there is new event was pushed into the event pool, the corresponding handler will handle the event in order.
--
添加基于事件的处理机制进行业务解耦。
当一些特殊的事件(例如 保活事件,error事件,超时重试事件,等...)发生时,将这些事件 push 到 一个或多个事件池中,然后由一个或多个监听器监听对应的事件池,当监听器监听到事件池中 push 了新的事件时,对应事件的处理器依次处理事件池中的事件。