• Post Reply Bookmark Topic Watch Topic
  • New Topic

SOAPMessage SOAPConnection : how to do gzip in java  RSS feed

 
santosh sharma
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I need to use compression when sending SOAP requests and receiving responses
from the WebService. Unfortunately I didn't find any references on how to
enable GZIP compression. Here is the simple code I use to send the soap
request:

--

SOAPConnectionFactory scf = SOAPConnectionFactory.newInstance();

SOAPConnection sc = scf.createConnection();

MessageFactory mf = MessageFactory.newInstance();

SOAPMessage message = mf.createMessage();

/*

.... some code

*/

URL url = new URL("https://blahblah/service/ws/Someservice");

SOAPMessage reply = sc.call(message, url);

--

Is there any way to enable the compression on the API level or will I have
to wrap the SOAPMessage to implement compression myself?
 
Rob Spoor
Sheriff
Posts: 20903
81
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the Ranch, Santosh!

I'll move this thread to our Web Services forum where SOAP is usually discussed.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!