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
6
votes
1 answer

RoboSpice throwing okhttp exceptions

I use RoboSpice-Retrofit for calling my server REST api which has been working without problems until a few days ago when every single call now throws an exception, Example: D/Retrofit: java.lang.NoSuchMethodError: No direct method…
Arbitur
  • 38,684
  • 22
  • 91
  • 128
6
votes
1 answer

RoboSpice with Gson and Realm

I'm using RoboSpice with GsonSpringAndroidSpiceService. I also want to add Realm to save the data. the problem is that in realm each object has to extend realmObject, but the gson in the roboSpice trying to parse the realmObject instead of ignore…
dvrm
  • 3,749
  • 4
  • 34
  • 43
6
votes
0 answers

Mapping POJOs to application/x-www-form-urlencoded with custom form keys

I'm using RoboSpice with Spring Android to perform REST api calls. Data need to be sent with the Content-Type set to application/x-www-form-urlencoded. Let's say I have a Pojo class like this: public class Pojo { private String pojoAttribute; …
grandouassou
  • 2,500
  • 3
  • 25
  • 60
6
votes
0 answers

Saving foreign collection in ORMLite with Robospice and Scala

We're using Robospice on Android in Scala with the ORMLite module for persistence and are having difficulties saving foreign collections to the database. The data is being received properly (i.e. we are getting and interpreting a User with a couple…
E Rullmann
  • 344
  • 3
  • 12
6
votes
1 answer

Handling specific errors by sending another request transparently in retrofit

Here's the case I'm trying to handle, If a request is executed, and the response indicates the auth token is expired, send a refresh token request if the refresh token request succeeds, retry the original request This should be transparent to the…
Hassan Ibraheem
  • 2,329
  • 1
  • 17
  • 23
6
votes
1 answer

Android: How to get the JSON object returned in case of an exception using RoboSpice

I am using RoboSpice to access some rest services I developed using resteasy. I'm returning a JSON object when everything is ok and in the case of an exception I'm returning an http error code and a JSON object describing the nature of the…
drginm
  • 608
  • 6
  • 9
5
votes
1 answer

How generify class with T and List

I am trying to generify my class structure. I will show my real structure to be more specific. I am writing application with offline mode support, so I decided to implement my ETag cache mechanism in using Robospice and GreenDao ORM. I need to…
CROSP
  • 4,499
  • 4
  • 38
  • 89
5
votes
0 answers

Using RoboSpice and RxJava

I would like to know what is the best practice when using RoboSpice and RxJava together. The only thing I've found so far is the "RoboSpice and RxJava" thread in the RoboSpice Google Group. I wonder if there is a recommended approach when…
Julian Suarez
  • 4,499
  • 4
  • 24
  • 40
5
votes
2 answers

Retrofit/Robospice: get response headers from successful request?

I am using Retrofit/Robospice to make api calls in an app I've built, with a RetrofitGsonSpiceService. All responses are converted into POJOs using a GSON converter, however there is some information I need to retrieve from the response header. I…
AndroidNoob
  • 2,771
  • 2
  • 40
  • 53
5
votes
1 answer

How to connect to a pending request with RoboSpice (Splash > Main activity)?

I have fews questions about RoboSpice (advanced usages). Note: I use RoboSpice with OrmLite. My Android application is composed of two main activities: the first one is SplashActivity (start on launch) and the second is MainActivity (lauched 5s…
Guicara
  • 1,668
  • 2
  • 20
  • 34
5
votes
1 answer

Robospice request never ends if app goes in background and then comes to Foreground?

I am developing an app using RoboSpice library for calling REST API's. Everything works fine with the library except one thing. I don't use caching available in RoboSpice and so all the requests are made without cache. Now, when any request is going…
thefrugaldev
  • 1,619
  • 4
  • 18
  • 36
5
votes
1 answer

Setting Connection TimeOut in RoboSpice request android

I am using RoboSpice for Rest Api calls in android and i want to add connection timeout for 30 secs in calls how i will do ? here is my code public class AddBrandsService extends SpringAndroidSpiceRequest { public…
Zaid Bin Tariq
  • 298
  • 2
  • 9
5
votes
1 answer

Robospice in android.os.Service context

According to RoboSpice documentation https://github.com/octo-online/robospice/wiki/Design-of-RoboSpice , i can use it in any Context. Can't find an example of using Robospice in service context. I did some attempts but nothing happened, requests…
Dmitriy Voronin
  • 649
  • 6
  • 19
4
votes
1 answer

Retrofit + Robospice native crash on Android 6 - Fatal signal 11 (SIGSEGV), code 1

When executing this line: Response response = getService().auth(new AuthEnvelope(email, password)); inside Robospice RetrofitSpiceRequest class in loadDataFromNetwork() method - app crashes (sometimes not, but method doesn't return) with this log: …
localhost
  • 5,568
  • 1
  • 33
  • 53
4
votes
2 answers

Commons-Io Duplicate Entry Error Using Robospice and Android Studio

I've been working on the following issue for several hours, but haven't come up with a way to solve my problem. I've tried the following fixes from Stack Overflow (Android Studio update to 1.0 corrupts MultiDex and Duplicate Zip Entry after Gradle…
reggie3
  • 1,018
  • 2
  • 15
  • 22
1
2
3
16 17