Hi,
At some point in my flow, I would like to remove some headers of my message because they would be interpreted by another part of the flow later.
I tried using a Service Activator with a POJO and a method defined as the following:
But this won't remove any header (it seems like they are added again by the AbstractReplyProducingMessageHandler)Code:public Message<?> cleanHeaders(Message<?> message) { return MessageBuilder.withPayload(message.getPayload()).build(); }
I also tried to include a header-enricher and set to null all the headers (although I would need to know the exhaustivity of my custom headers), but the following syntax is not accepted :
Is there any way to do what I want?Code:<int:header-enricher ...> <int:header name="foo"><null/></int:header> </int:header-enricher>
Thank you!
Pierre


Reply With Quote
