Hi,
I plan to capture it through Fiddler to check. This call
should route it through the Fiddler proxy. It didn't when I tried.
Request[] requests = new Request[] {
Request.Post("http://localhost:9090/print").
viaProxy(new HttpHost("127.0.0.1", 8888)).
bodyString(getJSon(), ContentType.
APPLICATION_JSON),
Request.Post("http://localhost:9090/print").
viaProxy(new HttpHost("127.0.0.1", 8888)).
bodyString(getJSon(), ContentType.
APPLICATION_JSON),
};
Thanks,
Mohan
From: Oleg Kalnichevski <[email protected]>
To: HttpClient User Discussion <[email protected]>
Date: 10/09/2013 05:28 PM
Subject: Re: Async API call
On Wed, 2013-10-09 at 12:23 +0530, [email protected]
wrote:
> Hi,
> I am using this JUnit test( example from Apache HTTP Components
as
> it is ). I am sending JSON to a Netty server which is able to receive 2
> POSTS
> and also send responses. I believe Netty can receive more requests but
> that might be a different issue.
>
> Here even for the 2 POSTS that Netty receives and sends responses the
> callback methods are not called. I was thinking this unit test will
> complete and the JVM will exit. But it doesn't happen.
>
> When does 'future.get' return ? Does it return as soon as it sends and
> receives a response ?
>
> Since I am a new user I could be making some minor mistakes but the
code
> is able to send and the server receives the JSON.
>
> Thanks,
> Mohan
I ran your code with some minor modifications (I had to eliminate JSON
and Netty dependencies) and it worked just fine for me (both responses
correctly processed and the JVM terminated as expected). This seems to
point at the server side.
Oleg
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
This e-Mail may contain proprietary and confidential information and is sent
for the intended recipient(s) only. If by an addressing or transmission error
this mail has been misdirected to you, you are requested to delete this mail
immediately. You are also hereby notified that any use, any form of
reproduction, dissemination, copying, disclosure, modification, distribution
and/or publication of this e-mail message, contents or its attachment other
than by its intended recipient/s is strictly prohibited.
Visit us at http://www.polarisFT.com