androidandroid-volleyretrofitrobospice

RoboSpice or Retrofit or Volley?


After going through the ways of calling web service calls in android.It's not recommended to use AsyncTask because of issues like device configuration change.

And Loaders are mainly used for interacting with database and Services mostly for long running operations.

Many answers says, to use libraries like Volley or Robospice or Retrofit.

What would be the most efficient one among them?

Any suggestions would be appreciated.


Solution

  • I came across different approaches in the past years and applied some of them in the real apps and some of them in some simple proof of concepts.

    Here's my opinion:

    The best option for communication with web services in Android is Retrofit + RxJava

    Retrofit is compatible with RxJava. With such approach, you have clean and simple interface, you are able to handle errors and manipulate HTTP responses as Observable streams thanks to RxJava. Such approach is becoming good practice and standard for Android applications right now.