Class ControlBusMessageProcessor
java.lang.Object
org.springframework.integration.util.AbstractExpressionEvaluator
org.springframework.integration.handler.AbstractMessageProcessor<Object>
org.springframework.integration.handler.ControlBusMessageProcessor
- All Implemented Interfaces:
Aware
,BeanFactoryAware
,InitializingBean
,MessageProcessor<Object>
,IntegrationPattern
public class ControlBusMessageProcessor
extends AbstractMessageProcessor<Object>
implements IntegrationPattern
A MessageProcessor implementation that expects a Control Bus command as a request message.
When processing, it evaluates a SpEL expression associated with requested command,
essentially target bean method invocation.
The arguments for the command must be provided
in the IntegrationMessageHeaderAccessor.CONTROL_BUS_ARGUMENTS
message header.
- Since:
- 6.4
- Author:
- Artem Bilan
-
Field Summary
Fields inherited from class org.springframework.integration.util.AbstractExpressionEvaluator
EXPRESSION_PARSER, logger
-
Constructor Summary
ConstructorDescriptionControlBusMessageProcessor
(ControlBusCommandRegistry controlBusCommandRegistry) Create an instance based on the providedControlBusCommandRegistry
. -
Method Summary
Modifier and TypeMethodDescriptionReturn a pattern type this component implements.protected void
onInit()
processMessage
(Message<?> message) Process the Message and return a value (or null).Methods inherited from class org.springframework.integration.util.AbstractExpressionEvaluator
afterPropertiesSet, evaluateExpression, evaluateExpression, evaluateExpression, evaluateExpression, evaluateExpression, evaluateExpression, evaluateExpression, getBeanFactory, getEvaluationContext, getEvaluationContext, getMessageBuilderFactory, setBeanFactory, setConversionService, setSimpleEvaluationContext
-
Constructor Details
-
ControlBusMessageProcessor
public ControlBusMessageProcessor() -
ControlBusMessageProcessor
Create an instance based on the providedControlBusCommandRegistry
.- Parameters:
controlBusCommandRegistry
- theControlBusCommandRegistry
with commands to execute.
-
-
Method Details
-
getIntegrationPatternType
Description copied from interface:IntegrationPattern
Return a pattern type this component implements.- Specified by:
getIntegrationPatternType
in interfaceIntegrationPattern
- Returns:
- the
IntegrationPatternType
this component implements.
-
onInit
protected void onInit()- Overrides:
onInit
in classAbstractExpressionEvaluator
-
processMessage
Description copied from interface:MessageProcessor
Process the Message and return a value (or null).- Specified by:
processMessage
in interfaceMessageProcessor<Object>
- Specified by:
processMessage
in classAbstractMessageProcessor<Object>
- Parameters:
message
- The message to process.- Returns:
- The result.
-