Questions tagged [robospice]

RoboSpice is an Open source library for Android to perform long running background tasks. It has been designed primarily to execute network processing (such as performing REST requests) but it can be used as a full, working, replacement for AsyncTasks.

RoboSpice is an Open source library for Android to perform long running background tasks. It has been designed primarily to execute network processing (such as performing REST requests) but it can be used as a full, working, replacement for AsyncTasks.

The principle of RoboSpice is that "background tasks" are processed inside an Android Service. To understand why RoboSpice is better than AsyncTasks and Loaders, refer to this infographics

RoboSpice offers different module to provide REST support out of the box via various technologies :

Asynchronous Networking Made Easy. Robust and simple. GitHub repository

251 questions
71
votes
7 answers

Retrofit: multiple query parameters in @GET command?

I am using Retrofit and Robospice to make API calls in my android application. All @POST methods work great, and so do @GET commands without any parameters in the URL, but I can't get any @GET calls to work with parameters on the end! For example,…
AndroidNoob
  • 2,771
  • 2
  • 40
  • 53
30
votes
1 answer

onStart of new Activity is called before onStop of parent

I've got an application. I use startActivity() to start activity. Can anyone actually tell me why system is calling onStart() of new Activity first, instead of parents onStop()? Is that even possible (without system bug)? I've found Fragment…
cadavre
  • 1,334
  • 1
  • 18
  • 34
14
votes
5 answers

Using RoboSpice is there a way to get the HTTP Error Code out of an exception?

I am writing an application that uses RoboSpice. In the request listener onRequestFailure( SpiceException arg0 ) is there a way to know for sure that the error was a result of a 401 HTTP Error occurred? I have a back end service, that returns a 401…
JLamkin
  • 721
  • 6
  • 17
13
votes
3 answers

How to increase timeout for retrofit requests in robospice android?

I have implemented robospice in my project and using retrofit for all api calls. For some of requests, I need to increase timeout, please let me know how can I do that? Actually I am using service that extends RetrofitGsonSpiceService. The code of…
100rbh
  • 763
  • 1
  • 7
  • 10
10
votes
2 answers

How does robospice manage activity lifecycle?

I'm looking for a technical answer to how the android robospice library manages activity lifecycle. From the getting started page: https://github.com/octo-online/robospice/wiki/Starter-Guide "As an inner class of your Activity (or other context),…
craigrs84
  • 3,048
  • 1
  • 27
  • 34
9
votes
2 answers

Pause a background process in robospice

Is it possible to pause a background service currently running and running it again starting from the point its execution was stopped? If not, is it at least possible to send a signal to stop the execution of SpiceService before it finishes its…
qwerty
  • 486
  • 1
  • 11
  • 37
9
votes
0 answers

Spring Android Vs Retrofit

I've been doing some digging lately into the REST Clients for Android. Majority of the discussions have been around Volley and Retrofit, seldom I came across comparisons between Ion, Robospice with these two. I could not find any comparison with…
Mushtaq Jameel
  • 7,053
  • 7
  • 33
  • 52
8
votes
1 answer

What is RoboSpice Library in android

I am Trying to understand RoboSpice Library in android I saw the online Documentation here What i tried:: I have previously studying on using Spring Library,also Retrofit, AsyncHttp etc I understood that all above convert JSON response to…
Devrath
  • 42,072
  • 54
  • 195
  • 297
8
votes
2 answers

Robospice - keep spice service continue running when changing activity

I used RoboSpice library to do asynchronous tasks. From their examples, the spice service is declared in BaseActivity, it starts in activity's onStart method, and stops in activity's onStop. Everything is fine, but when I want download file from…
ductran
  • 10,043
  • 19
  • 82
  • 165
8
votes
2 answers

Robospice/ Retrofit background service accessing database

I've successfully created a Retrofit API Rest client making both GET & POST calls and also incorporated that into Robospice as a background service. However, I want the Robospice service to connect to the database and asynchronously persist the…
saywhatnow
  • 1,026
  • 2
  • 15
  • 26
7
votes
0 answers

Change ConnectionTimeout of Retrofit OkHttpClient at runtime

I am using Dagger to inject RestAdapter.Builder and I am making an OkHttpClient inside that function. The function is as follows: @Provides @Singleton @Named("JSON") public RestAdapter.Builder provideJsonRestAdapterBuilder(final ChangeableEndpoint…
SoH
  • 2,180
  • 2
  • 24
  • 53
7
votes
1 answer

Using Cookies with Robospice Retrofit requests

Can anyone please suggest me a way to manage cookies in robospice retrofit type HTTP requests. I have a authentication system which has a login , a few GET HTTP requests , and a logout. During login i need to save the session and use the same…
Revanth Gopi
  • 350
  • 4
  • 14
7
votes
3 answers

How to execute RoboSpice requests synchronously?

How to execure RoboSpice requests synchronously? Is it possible? I would like to use RoboSpice in IntentService. Edit: From time to time comes the need to execute something synchronously e.g. in service. In my recent project I have to queue some…
Ziem
  • 6,579
  • 8
  • 53
  • 86
7
votes
4 answers

How to call the static class method for a generic object?

I need to pass the class of a generic type into a class's constructor. The class is SpiceRequest from the RoboSpice Android library for a reference to the constructor. It seems odd that the class requires passing the generic's class into the…
Jeff Lockhart
  • 5,379
  • 4
  • 36
  • 51
6
votes
1 answer

No such method error while using robospice-retrofit and getstream.io

In our project we are using com.octo.android.robospice:robospice-retrofit:1.4.14 , Which require okhttp: 1.6.0 And getstream java client io.getstream.client:stream-repo-okhttp:1.2.2', Which require okhttp:2.2.0 So here gradle is picking up, 2.2.0…
Sanyasirao Mopada
  • 943
  • 12
  • 31
1
2 3
16 17