Questions tagged [asynchttpclient]

Asynchronous HTTP client library for Java

See the GitHub repo for more information. In essence:

AsyncHttpClient allows Java applications to easily execute HTTP requests and asynchronously process the HTTP responses. Feature-packed, wicked fast, and actively maintained.

323 questions
0
votes
1 answer

Is there a way to limit the HTTP response body size received by Dispatch?

I'm using Dispatch to pull down a lot of pages from which I only need the first few K, and the pages are sometimes gigabytes. Is there any way in scala-dispatch (dispatch/reboot), or maybe in the HTTP request, to truncate the body…
Ed Staub
  • 15,480
  • 3
  • 61
  • 91
0
votes
1 answer

sending post data by HttpURLConnection crashes and don't work right

I want to send some json data to server . I used HttpURLConnection but my code crashes at line: PrintWriter out = new PrintWriter(urlConnection.getOutputStream()); and I want to know does my post data sended or not in the end. public void…
saeid ezzati
  • 855
  • 11
  • 29
0
votes
1 answer

Android method onSuccess() of AsyncHttpClient is deprecated. Is there an alternative for this?

@Override public void onSuccess(String response) { progressDialog.hide(); Toast.makeText(getApplicationContext(), response, Toast.LENGTH_LONG).show(); }
lionking
  • 65
  • 2
  • 7
0
votes
2 answers

Calling a PHP in a for loop using AsyncHttpClient

I am trying to call php file inside a for loop using AsyncHttpClient after fetching the values I am storing the values in local DB. I am sending parameters to my php file as it requires to fetch data from mySQL. Fetching part is working fine but…
TheDevMan
  • 5,914
  • 12
  • 74
  • 144
0
votes
1 answer

playframework: Is NingWSClient thread safe?

Say I have val client = new NingWSClient((new AsyncHttpClientConfig.Builder).build) Is it thread-safe to use client all over the current JVM?
Andrew Gaydenko
  • 267
  • 2
  • 11
0
votes
0 answers

issue with multiple camel routes and Camel AHC component

I have multiple call to end points configured within the same camel route. I am using camel ahc component. This works fine under the normal scenario. We are facing issues during the performance testing.
Rax
  • 323
  • 1
  • 5
  • 17
0
votes
1 answer

Async Task never ends in simple API client. Deadlock?

I'm new to C# and I'm very likely misunderstanding the the proper usage of await,async and Tasks :) I want to develop a class (OWConnector) that serves as API client for my app, for this purpose I develop a generic PostRequest method to perform POST…
Cesar
  • 4,418
  • 2
  • 31
  • 37
0
votes
1 answer

HttpClient, catch can't connect

I have the following code: ProgressMessageHandler progress = new ProgressMessageHandler(); progress.HttpSendProgress += new EventHandler(HttpSendProgress); HttpRequestMessage message = new…
Oleg Sh
  • 8,496
  • 17
  • 89
  • 159
0
votes
1 answer

How can I make a pipelined relay request with HttpAsyncClient?

I'm using Apache's HttpAsyncClient to proxy, or relay, incoming requests to another server. I have the simple case working (sample code below). The problem is that the Future will hold the response in memory, waiting until it's done…
sea-rob
  • 2,275
  • 1
  • 22
  • 22
0
votes
1 answer

Cancellation not returning past whenall using httpclient

Here is an updated version of the code posted under httpclient.GetStringAsync blocking The question is when cancel is done, though the tasks are cancelled, I am expecting Await Task.WhenAll(tasks) to return and print whats in finally, but its not. I…
0
votes
2 answers

Why asynchttpclient in tornado don't send request immediately?

At one point, I need a lot of time to submit a non-blocking request and for 2 seconds, with a tornado write an example, help me! I have a Server Client program in python which uses Tornado. Server.py : import tornado.httpserver import…
xu.
  • 11
  • 3
0
votes
1 answer

logging apache httpasyncclient

Hi I followed the instructions here: http://hc.apache.org/httpclient-3.x/logging.html since it was the only logging instructions I could find on the site, but I was still not able to turn logging on for the httpasyncclient. It works for the typical…
0
votes
1 answer

Android async httpclient: how to intercept authentication failures in one place?

I have the following mental model that for my android app, all authentication failures should be handled in a single place and the login screen should interrupt and be flashed on top of the view stack to allow the user to reauthenticate. Not sure…
user798719
  • 9,619
  • 25
  • 84
  • 123
0
votes
1 answer

Get JSON response containing Github user list using AsyncHttpClient

I'm trying to get response with user json list from github api. Could anyone tell me the reason why code execution path doesn't reach overriden methods onFailure() and onSuccess? public String getResponse() { AsyncHttpClient client=new…
AnZyuZya
  • 201
  • 1
  • 3
  • 18
0
votes
1 answer

Apache Camel: request-reply pattern with bean URIs and async-http-client

Apache Camel 2.13.1 Ning async-http-client 1.7.19 I'm trying to understand if I can use the reply-request pattern with Camel and the Ning async-http-client so that the route blocks until receipt of the HTTP response. ("Why are you using the async…
Jon Archer
  • 618
  • 9
  • 14