Re: Axis2 - can I obtain the HTTP client?

Andreas Veithen <[email protected]>
Newsgroups gmane.text.xml.axis.user
Message-ID <CADx4_uUJkmtZpNFoWzffsDnrEoDUf5Q6dJ+nQgfhTemkrzauzg@mail.gmail.com>
On Sat, Nov 19, 2016 at 8:22 PM, Sterpu Victor <[email protected]> wrote:
> I use a Axis client on a non Axis server.
> I need to overide(on clietnside) the Content-Encoding received in the HTTP
> header from the server because the server sends an invalid Content-Encoding.
> Can I  obtain the HTTP client from the stub class? I want to try to rewrite
> the header before it gets processed as described here:
> https://adamscheller.com/java/httpexception-unsupported-content-coding-none-solution/

Note that this is for httpclient4, but the stacktrace you posted
earlier shows that you are using the httpclient3 based transport
(which is the default in Axis2 1.7.x). You will first need to switch
to the httpclient4 based transport.

I think you can inject an HTTPClient instance into the message
context. Probably the best is to look at the source code of the
httpclient4 transport.

>
> Thank you.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.