I tried every possible regex but for some reason it didn't work. Eventually I
created a processor and removed the headers like below;

               
exchange.getIn().getHeaders().keySet().removeAll(Collections.singleton("Accept"));
               
exchange.getIn().getHeaders().keySet().removeAll(Collections.singleton("Accept-Encoding"));
               
exchange.getIn().getHeaders().keySet().removeAll(Collections.singleton("Accept-Language"));
               
exchange.getIn().getHeaders().keySet().removeAll(Collections.singleton("Authorization"));
               
exchange.getIn().getHeaders().keySet().removeAll(Collections.singleton("breadcrumbId"));
               
exchange.getIn().getHeaders().keySet().removeAll(Collections.singleton("breadcrumbId"));
               
exchange.getIn().getHeaders().keySet().removeAll(Collections.singleton("Cache-Control"));
               
exchange.getIn().getHeaders().keySet().removeAll(Collections.singleton("CamelHttpAuthentication"));
               
exchange.getIn().getHeaders().keySet().removeAll(Collections.singleton("CamelHttpCharacterEncoding"));
               
exchange.getIn().getHeaders().keySet().removeAll(Collections.singleton("CamelHttpMethod"));
               
exchange.getIn().getHeaders().keySet().removeAll(Collections.singleton("CamelHttpQuery"));
               
exchange.getIn().getHeaders().keySet().removeAll(Collections.singleton("CamelHttpRawQuery"));
               
exchange.getIn().getHeaders().keySet().removeAll(Collections.singleton("CamelHttpUri"));



--
View this message in context: 
http://camel.465427.n5.nabble.com/Removing-headers-tp5793667p5793734.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Reply via email to