stephanenicolas / robospice

Repo of the Open Source Android library : RoboSpice. RoboSpice is a modular android library that makes writing asynchronous long running tasks easy. It is specialized in network requests, supports caching and offers REST requests out-of-the box using extension modules.
Apache License 2.0
2.95k stars 545 forks source link

How to refresh data periodically? #382

Closed Tarubali closed 9 years ago

Tarubali commented 9 years ago

I am trying to use Robospice with Retrofit in my weather app and I'm not sure how to refresh data periodically and store to cache. I did some searching and came across Alarm Manager and JobScheduler(api21) and JobSchedulerCompat. Do I need these or can I get it done with robospice?

Example: user has set preference to check for weather update every hour.

I am new to Android development so any feedback is appreciated. Thanks!

stephanenicolas commented 9 years ago

There is no such feature in RS directly. You should rely on one of the options you mentioned above plus also a SyncManager.

Note that questions should be targeted to the discussion forum more than GH issues.