CXF with gzip

Eight Stars

CXF with gzip

Hi

In a Talend route, how can we use gzip compression during the CXF soap request/response ?

I tried adding "Accept-Enconding" header to true in my camel Route before the CXF component and adding "zip" module in the advanced parameters of a MessagingEndpoint, but I always get this error, even with a very simple message body that contains only 1 letter, read from a true UTF-8 file.

 

java.lang.RuntimeException: Couldn't parse stream.
	at org.apache.cxf.staxutils.StaxUtils.createXMLStreamReader(StaxUtils.java:1729)
	at org.apache.cxf.interceptor.StaxInInterceptor.handleMessage(StaxInInterceptor.java:127)
	at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
	at org.apache.cxf.endpoint.ClientImpl.onMessage(ClientImpl.java:780)
	at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponseInternal(HTTPConduit.java:1680)
	at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream$1.run(HTTPConduit.java:1176)
	at org.apache.cxf.workqueue.AutomaticWorkQueueImpl$3.run(AutomaticWorkQueueImpl.java:428)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
	at org.apache.cxf.workqueue.AutomaticWorkQueueImpl$AWQThreadFactory$1.run(AutomaticWorkQueueImpl.java:353)
	at java.lang.Thread.run(Unknown Source)
Caused by: com.ctc.wstx.exc.WstxIOException: Invalid UTF-8 start byte 0x8b (at char #2, byte #-1)
	at com.ctc.wstx.stax.WstxInputFactory.doCreateSR(WstxInputFactory.java:550)
	at com.ctc.wstx.stax.WstxInputFactory.createSR(WstxInputFactory.java:605)
	at com.ctc.wstx.stax.WstxInputFactory.createSR(WstxInputFactory.java:628)
	at com.ctc.wstx.stax.WstxInputFactory.createXMLStreamReader(WstxInputFactory.java:331)
	at org.apache.cxf.staxutils.StaxUtils.createXMLStreamReader(StaxUtils.java:1727)
	... 10 more
Caused by: java.io.CharConversionException: Invalid UTF-8 start byte 0x8b (at char #2, byte #-1)
	at com.ctc.wstx.io.UTF8Reader.reportInvalidInitial(UTF8Reader.java:303)
	at com.ctc.wstx.io.UTF8Reader.read(UTF8Reader.java:189)
	at com.ctc.wstx.io.ReaderBootstrapper.initialLoad(ReaderBootstrapper.java:250)
	at com.ctc.wstx.io.ReaderBootstrapper.bootstrapInput(ReaderBootstrapper.java:133)
	at com.ctc.wstx.stax.WstxInputFactory.doCreateSR(WstxInputFactory.java:545)
	... 14 more

 

What's the way to use Soap compression in Talend ESB ?

Thanks

Loko

2019 GARNER MAGIC QUADRANT FOR DATA INTEGRATION TOOL

Talend named a Leader.

Get your copy

OPEN STUDIO FOR DATA INTEGRATION

Kickstart your first data integration and ETL projects.

Download now

What’s New for Talend Summer ’19

Watch the recorded webinar!

Watch Now

Talend API Designer – Technical Overview

Take a look at this technical overview video of Talend API Designer

Watch Now

Getting Started with APIs

Find out how to get started with APIs

Read