Mule ESB 3.2 Splitter destroys Enricher results
Posted
by
Eddie
on Stack Overflow
See other posts from Stack Overflow
or by Eddie
Published on 2012-04-06T05:27:09Z
Indexed on
2012/04/06
5:28 UTC
Read the original article
Hit count: 246
Here is the snippet of my flow:
<logger message="PRODUCT_ID = #[header:productID]" level="INFO" doc:name="Logger"/>
<splitter evaluator="jxpath" expression="//*/BisacHeaderCodes" doc:name="Splitter"/>
<logger message="PRODUCT_ID_POST_SPLITTER = #[header:productID]" level="INFO" doc:name="Logger"/>
#[header:productID] was set up prior to Logger call. I tried #[variable:productID] and got the same result. When I run it, this is the out put I get:
INFO 2012-04-05 23:12:47,865 [[bookinista_order_management].connector.http.mule.default.receiver.02] org.mule.api.processor.LoggerMessageProcessor: PRODUCT_ID = 72
ERROR 2012-04-05 23:12:47,871 [[bookinista_order_management].connector.http.mule.default.receiver.02] org.mule.exception.DefaultSystemExceptionStrategy: Caught exception in Exception Strategy: Expression Evaluator "header" with expression "outbound:productID" returned null but a value was required.
org.mule.api.expression.RequiredValueException: Expression Evaluator "header" with expression "outbound:productID" returned null but a value was required.
So, right before Splitter, I have a perfect value in my header, and right after Splitter, that value disappears! I understand that Splitter propagates only part of payloda, but shouldn't it leave headers and variables alone?
Any ideas for a workaround?
© Stack Overflow or respective owner