Class InboundMessageRoutingServiceImpl
java.lang.Object
com.flowable.engage.external.system.service.InboundMessageRoutingServiceImpl
- All Implemented Interfaces:
InboundMessageRoutingService
public class InboundMessageRoutingServiceImpl
extends Object
implements InboundMessageRoutingService
- Author:
- Filip Hrisafov
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected boolean
protected final ConversationService
static final String
protected final EventRegistry
protected final ExternalSystemContentService
protected final InboundMessageEventPayloadExtractor
protected final MessageService
static final String
-
Constructor Summary
ConstructorsConstructorDescriptionInboundMessageRoutingServiceImpl
(MessageService messageService, ConversationService conversationService, ExternalSystemContentService externalSystemContentService, EventRegistry eventRegistry, InboundMessageEventPayloadExtractor inboundMessageEventPayloadExtractor) -
Method Summary
Modifier and TypeMethodDescriptionprotected Collection<EventPayloadInstance>
extractEventPayload
(InboundMessage inboundMessage, UserAccount userAccount, Message message) extractHints
(InboundMessage inboundMessage) findConversationForUserAccount
(UserAccount userAccount) Find the conversation id for the givenuserAccount
.protected Message
getReplyToMessage
(String externalSystemId, String replyToExternalMessageId) boolean
protected boolean
isDuplicateMessage
(String externalId) void
routeInboundMessage
(InboundMessage inboundMessage, UserAccount userAccount) Route the inbound message to a conversation for the giveuserAccount
void
setAlwaysSendSystemEvent
(boolean alwaysSendSystemEvent)
-
Field Details
-
EVENT_KEY_EXTERNAL_MESSAGE_RECEIVED
- See Also:
-
SYSTEM_TYPE
- See Also:
-
messageService
-
conversationService
-
externalSystemContentService
-
eventRegistry
-
inboundMessageEventPayloadExtractor
-
alwaysSendSystemEvent
protected boolean alwaysSendSystemEvent
-
-
Constructor Details
-
InboundMessageRoutingServiceImpl
public InboundMessageRoutingServiceImpl(MessageService messageService, ConversationService conversationService, ExternalSystemContentService externalSystemContentService, EventRegistry eventRegistry, InboundMessageEventPayloadExtractor inboundMessageEventPayloadExtractor)
-
-
Method Details
-
routeInboundMessage
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
-
extractEventPayload
protected Collection<EventPayloadInstance> extractEventPayload(InboundMessage inboundMessage, UserAccount userAccount, Message message) -
extractHints
-
findConversationForUserAccount
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
-
getReplyToMessage
-
isAlwaysSendSystemEvent
public boolean isAlwaysSendSystemEvent() -
setAlwaysSendSystemEvent
public void setAlwaysSendSystemEvent(boolean alwaysSendSystemEvent)
-