Class InboundMessageRoutingServiceImpl
java.lang.Object
com.flowable.engage.external.system.service.InboundMessageRoutingServiceImpl
- All Implemented Interfaces:
InboundMessageRoutingService
public class InboundMessageRoutingServiceImpl extends java.lang.Object implements InboundMessageRoutingService
- Author:
- Filip Hrisafov
-
Field Summary
Fields Modifier and Type Field Description protected ConversationService
conversationService
protected ExternalSystemContentService
externalSystemContentService
protected MessageService
messageService
-
Constructor Summary
Constructors Constructor Description InboundMessageRoutingServiceImpl(MessageService messageService, ConversationService conversationService, ExternalSystemContentService externalSystemContentService)
-
Method Summary
Modifier and Type Method Description protected java.util.Map<java.lang.String,java.lang.String>
extractHints(InboundMessage inboundMessage)
java.lang.String
findConversationForUserAccount(com.flowable.core.idm.api.UserAccount userAccount)
Find the conversation id for the givenuserAccount
.protected Message
getReplyToMessage(java.lang.String externalSystemId, java.lang.String replyToExternalMessageId)
protected boolean
isDuplicateMessage(java.lang.String externalId)
void
routeInboundMessage(InboundMessage inboundMessage, com.flowable.core.idm.api.UserAccount userAccount)
Route the inbound message to a conversation for the giveuserAccount
-
Field Details
-
Constructor Details
-
InboundMessageRoutingServiceImpl
public InboundMessageRoutingServiceImpl(MessageService messageService, ConversationService conversationService, ExternalSystemContentService externalSystemContentService)
-
-
Method Details
-
routeInboundMessage
public void routeInboundMessage(InboundMessage inboundMessage, com.flowable.core.idm.api.UserAccount userAccount)Description copied from interface:InboundMessageRoutingService
Route the inbound message to a conversation for the giveuserAccount
- Specified by:
routeInboundMessage
in interfaceInboundMessageRoutingService
- Parameters:
inboundMessage
- the received message from the external systemuserAccount
- the user account that the message belongs to
-
extractHints
protected java.util.Map<java.lang.String,java.lang.String> extractHints(InboundMessage inboundMessage) -
findConversationForUserAccount
public java.lang.String findConversationForUserAccount(com.flowable.core.idm.api.UserAccount userAccount)Description copied from interface:InboundMessageRoutingService
Find the conversation id for the givenuserAccount
. The conversation id is the if of the conversation that can be used to route messages into.- Specified by:
findConversationForUserAccount
in interfaceInboundMessageRoutingService
- Parameters:
userAccount
- the user account- Returns:
- the id of the conversation, never
null
-
isDuplicateMessage
protected boolean isDuplicateMessage(java.lang.String externalId) -
getReplyToMessage
protected Message getReplyToMessage(java.lang.String externalSystemId, java.lang.String replyToExternalMessageId)
-