Ecotoneinject arguments to invoked method based on
Parameter Converters. Parameter converters tells
Ecotonehow to resolve specific parameter and what kind of argument is it expecting.
Ecotonedoes resolve parameters based on given attribute types.
Payload- Does inject payload of the message. In our case it will be the command itself
Headers- Does inject all headers as array.
Reference- Does inject service from Dependency Container. If
referenceNamewhich is name of the service in the container is not given, then it will take the class name as default.
Ecotone, if parameter converters are not passed provides default converters.
Headersconverter is taken
Referenceconverter is picked
expression(Optional) - Allow for performing transformations before passing argument to parameter
payload- which is just payload of currently handled Message
headers- contains of all headers available within Message
reference- which allow for retrieving service from Dependency Container and calling a method on it. The result of the expression will be passed to parameter after optional conversion.
headerName(Required) - Allow for performing transformations before passing argument to parameter
Payload Expression, there is one more variable available
value.Value holds chosen header by
Referenceconverter is responsible for retrieving object from Dependency Container and passing it to given parameter. It does contain attributes:
referenceName(Optional) - Reference name of given object in Dependency Container. If not passed, then type hint of given parameter will be used.