Class ThreadHumanIdleTimeoutServiceDelegate
java.lang.Object
com.bytedesk.ticket.thread.delegate.ThreadHumanIdleTimeoutServiceDelegate
- All Implemented Interfaces:
org.flowable.engine.delegate.JavaDelegate
@Component("threadHumanIdleTimeoutServiceDelegate")
public class ThreadHumanIdleTimeoutServiceDelegate
extends Object
implements org.flowable.engine.delegate.JavaDelegate
人工接待访客超时服务
处理访客在人工接待过程中长时间未发送消息的情况
- 记录超时信息
- 发送超时提醒
- 结束会话
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
execute
(org.flowable.engine.delegate.DelegateExecution execution) private boolean
isReallyTimedOut
(org.flowable.engine.delegate.DelegateExecution execution) 检查是否真的超时 考虑访客最后活动时间,如果访客在超时时间内有新消息,则不应判定为超时private void
markThreadAsTimeout
(String threadUid) 标记会话为超时状态
-
Field Details
-
queueMemberRestService
-
-
Constructor Details
-
ThreadHumanIdleTimeoutServiceDelegate
public ThreadHumanIdleTimeoutServiceDelegate()
-
-
Method Details
-
execute
public void execute(org.flowable.engine.delegate.DelegateExecution execution) - Specified by:
execute
in interfaceorg.flowable.engine.delegate.JavaDelegate
-
isReallyTimedOut
private boolean isReallyTimedOut(org.flowable.engine.delegate.DelegateExecution execution) 检查是否真的超时 考虑访客最后活动时间,如果访客在超时时间内有新消息,则不应判定为超时- Parameters:
execution
- 流程执行上下文- Returns:
- 如果真的超时,返回true;否则返回false
-
markThreadAsTimeout
标记会话为超时状态
-