Android App slow connection to server

2.4k views Asked by At

We are working now on our Android App and we are actually not happy with the connection to the server and the response time at all. Our server has an Apache 2.2 and the response over an browser took 0,3 sec. The service is well optimized for speed and performance.

The problem we had now is the standart HTTP connection client from Java on Android. It took 4 seconds to establish the connection to the server and after that some ms to download the results. After there we have the parsing time and the display time. The whole time is somehow 5-6 seconds, what is impossible for an performance App like ours.

We replaced the standart HTTP connection client with an own socket connection client and we had an amazing impact. The connection time and the download time is now < 100 ms. But we have now the problem, that Volley (the library from Google) needs 4 seconds to convert the stream in a byte array.

Does anyone has an idea what we can do to improve this convertion?

P.S. are there some special settings for Apache to make the connection from an App faster?

Thanks Nik

1

There are 1 answers

2
Pasquale Anatriello On

If you really need fast connection you could take a look at SPY http://en.wikipedia.org/wiki/SPDY OkHTTP is already supporting that on Android http://square.github.io/okhttp/