android-textile icon indicating copy to clipboard operation
android-textile copied to clipboard

Assure node is started for background upload events

Open asutula opened this issue 6 years ago • 4 comments

Similar to what I did in ios-textile:

https://github.com/textileio/ios-textile/pull/82

asutula avatar Sep 06 '19 20:09 asutula

This might not be needed because our background events do not "wake up" the app in the iOS sense. See https://developer.android.com/guide/components/broadcasts#context-registered-receivers, which is what we use. So far as I can tell, manifest-registered receivers are no longer available for non-system events: https://developer.android.com/guide/components/broadcasts#manifest-declared-receivers

sanderpick avatar Sep 06 '19 21:09 sanderpick

Ok cool. I guess this ticket was just more to get a handle on the situation, understand how it does work. Sounds like you have a better handle on it than me.

asutula avatar Sep 06 '19 21:09 asutula

So given the way you describe it, do the upload events always get sent to a running node? Or are we going to miss events and there's nothing we can do about it?

asutula avatar Sep 06 '19 21:09 asutula

Needs more research... I think we could miss events but not sure. I was never able to get a definitive answer about the manifest registered broadcast receivers no longer being available. I spent a lot of time trying to get them to work w/o luck. There's a chance that the node stops during an upload and the events just go into the ether.... but again, not sure.

sanderpick avatar Sep 06 '19 21:09 sanderpick