package cn.axzo.workflow.core.listener;

import org.flowable.common.engine.api.delegate.event.FlowableEngineEventType;
import org.flowable.common.engine.api.delegate.event.FlowableEvent;
import org.springframework.core.Ordered;

/**
 * 对引擎内异步任务执行异常的事件扩展监听接口
 *
 * @author wangli
 * @since 2024/4/29 16:57
 */
public interface BpmnAsyncJobEventListener extends Ordered {

    /**
     * 是否支持处理
     *
     * @param eventType
     * @return
     */
    boolean support(FlowableEngineEventType eventType);

    /**
     * 具体的处理逻辑
     *
     * @param flowableEvent
     */
    void notify(FlowableEvent flowableEvent);

}
