-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
org.apache.http deprecated in API 23 #104
Comments
I was just able to solve this problem using the following conversation. http://stackoverflow.com/questions/17587751/gradle-execution-failed-for-task-processdebugmanifest I have not rewritten all our network code to support new version of HTTP connection library. In fact, I added the some workaround which android team has shown here to use legacy http library: However, later, we would upgrade to new version of http library. Or use other http libraries which are advanced enough to download pictures from server. |
Sojharo Thanks for the update. When we should upgrade to the newer level so we do have workaround? It is better to be current. |
We would upgrade when demos are done in june. Yes, we have the workaround and it works. It is also given by android as upgrading the apps to Android 6.0 will break most of apps if there is not workaround. |
OK. Make sense |
As discussed in above comments, we had to upgrade to latest version of our http network library org.apache.http. Therefore, I want to reopen this issue and I would gradually upgrade all the networking code. This is required at this time as we are working on uploading and downloading of images. So, I have found a very good and well-maintained library called Ion. https://github.com/koush/ion This would be very helpful in downloading images and loading them into our image viewers. It will do all this mundane task in background for us with just few lines of code. It uses the apache http in background with its updated version. I need to use this library in downloading icon task i.e. #233 @jekram |
@sojharo Nice! no AsycTask will make the code much more readable and easy to maintain, Lets have a discussion on monday. Also I will study the library in the meantime so that we can have a discussion. |
Yes, but AsyncTask is a lot of code which we have to write every where to do http request. This library is asynchronous and handles AsyncTask inside it. The syntax of library is cleaner and easy to maintain. In your study, please go through the sample codes too. |
@sojharo Thanks I will look at it 😄 |
@sojharo Thanks. I agree with the approach. "The best programmer is who writes the least amount of code and get the work done." So leveraging "good" components from outside or writing modular reusable code is a great approach. |
I have integrated the library and have used it for uploading and downloading image. The integration was successful and I was able to reduce at least 40 lines of code which was scattered in 3 separated files. Now just in 8 lines I am able to download and upload image. I would discuss this with Asad and dayem so that they can move to this. |
Thanks |
I had to upgrade to android API 23 from API 22. This has solved the error in #89 but has introduced the error in some functions that I used in HTTP connection library.
In the API 23, http functions have been deprecated and I have to go to new version functions. Else it gives error.
The text was updated successfully, but these errors were encountered: