Questions tagged [androidhttpclient]

Implementation of the Apache DefaultHttpClient that is configured with reasonable default settings and registered schemes for Android This class was deprecated in API level 22 (Android 5.1). Please use URLConnection and friends instead. The Apache HTTP client is no longer maintained and may be removed in a future release. Please visit this webpage for further details.

Implementation of the Apache DefaultHttpClient that is configured with reasonable default settings and registered schemes for Android.

Warning: This class was deprecated in API level 22 (Android 5.1).
Please use URLConnection and friends instead. The Apache HTTP client is no longer maintained and may be removed in a future release. Please visit this webpage for further details.

Useful links

418 questions
2
votes
1 answer

How to improve performance of contacting WebService?

I have an android application that communicates with WebService. My application sends request to Web Service which is written in php. The php side, just processes the request and echo out result in JSON format. Although amount of data being…
Nevercom
  • 840
  • 3
  • 14
  • 38
2
votes
0 answers

No peer certificate in Android while accessing the HTTPS URL

I'm using HTTPClient to access the HTTPS URL. I got some SSL error like No peer certificate. I pasted my code here. HttpClient client = new DefaultHttpClient(); HttpGet httpGet = new HttpGet("https://myURL.com"); HttpResponse httpResponse =…
It's me
  • 1,065
  • 6
  • 15
  • 30
2
votes
2 answers

Android common webservice class from all activities

This is a simple doubt of me. I had a android application with 10 activities. There is some web connection from each activities. So each and every activity I wrote a ASYNC Task for connecting to web service. Instead of that is there is any method…
ramesh
  • 4,008
  • 13
  • 72
  • 117
2
votes
0 answers

Should I use a single AndroidHttpClient instance or create a new one for every connection I make?

I use AndroidHttpClient for my server connections. I created a singleton class that creates a single AndroidHttpClient instance and use it for all the connections. The client uses ThreadSafeClientConnManager and from my experience it works well.…
1
vote
0 answers

java.security.cert.CertPathValidatorException: Trust anchor for certification path not found on Android 7.0

I'm using https://github.com/lingochamp/FileDownloader for downloading from https server. I'm getting the exception on below android 7 only while downloading. Trust anchor for certification path not found I have tried adding…
1
vote
2 answers

Android - Track down why app using so much data

I am currently having an issue with my app using a lot of mobile data and I am not 100% sure why as the typical request is just JSON sent/received data and typically very small (IE sending username/password for login). Some users are reporting up to…
Jayce
  • 781
  • 3
  • 16
  • 35
1
vote
0 answers

how to set proxy for all connections in an android app?

I want to use this library for playing some youtube video in my android app. but in my country youtube is blocked. I want to use proxy or anything else, only for my app to solving this problem. I tried this code but all connections is Failed except…
Hadi Ahmadi
  • 1,924
  • 2
  • 17
  • 38
1
vote
3 answers

android - how to hide url request

recently some one told me that he retrieves all the url requests from my android application and he sent them to me . I'm using proguard in my application but he told me there are some ways that he can monitor the url requests . I'm using…
Navid Abutorab
  • 1,667
  • 7
  • 31
  • 58
1
vote
2 answers

Android What happens during HTTP transaction if Device sleeps?

I couldn't produce this example which iam about to explain, so i post this here to give me more info about it. Lets say that we want to make an http request to receive a JSON object from a server. We hold no wakelocks nor we make our app a…
user10803305
1
vote
0 answers

How to load image in glide with https not secure certificate

i am trying to load image in glide, in localhost it will load perfectly, when i move to server it will not load how to solve this issue. code: Glide.with(mContext) …
Manish Ahire
  • 550
  • 4
  • 19
1
vote
0 answers

can not resolve writeStream - HTTPConnection POST

I am trying to post from Java - Android Studio to RESTful api and for some reason the IDE can not resolve "writeStream(output)" as in HttpUrlConnection /* POSTING TO RESTful API */ URL url = null; try { url = new…
CodingCode
  • 123
  • 2
  • 12
1
vote
0 answers

how to solve "javax.net.ssl.SSLHandshakeException: java.security.cert.CertPathValidatorException: Trust anchor for certification path not found."

I am new to Networking, I got this error when i was trying get data from newsapi.org error: javax.net.ssl.SSLHandshakeException: java.security.cert.CertPathValidatorException: Trust anchor for certification path not found.. I looked over some…
1
vote
0 answers

Android FileBody equivalent encoding in iOS

We have some code posting an image and some other data as part of a Multipart in a POST request. In Android is working just fine, but I can't seem to make it work on iOS, where I keep getting a 500 Internal Server Error. The working Android code…
1
vote
1 answer

what is usage scenario for DownloadManager and volley

The android training said: Volley is not suitable for large download or streaming operations, since Volley holds all responses in memory during parsing. For large download operations, consider using an alternative like DownloadManager. I just…
1
vote
1 answer

HttpConnection don't close

I want to close the get request connection but,it didn't closed. Its my code block Edit code block but doesn't work again.. try { HttpClient client = new DefaultHttpClient(); URI website = website = new…
Zarzamora
  • 45
  • 1
  • 8