-
Notifications
You must be signed in to change notification settings - Fork 166
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(dispatch): decrease timer interval to 15 sec #345
Conversation
Hi @chreck, thanks for your pull request! I just checked and tried to understand it. Maybe you can help me there. As far as I am understanding the problem, according to the SO thread you linked in the ticket, iOS terminates the app if it is running longer than 30 seconds in the background. The I am struggling to understand how changing this is preventing the iOS to kill the app if it runs longer than 30 seconds in the background. |
Maybe an example helps to understand the case.
|
Hey @chreck, thanks. That helped to understand the issue in question. I think there are two underlying problems:
Against case 1, there isn't too much we can do in this situation. Reducing the 30 seconds to 15, can't fix this problem, it just reduces the probability. But it comes with the downside of talking to the network more often (which has an effect on battery) since now events are per default dispatched twice as often. Since this is a public, variable, I would leave it to the user to decide which tradeoff to take. For case 2, there is a public protocol, called |
I will close this for now because I am not convinced it's the right approach. Additionally the Feel free to open it again if needed. |
@brototyp we use currently the dispatch 15 seconds approach. What about the persisting of the events? I dont think I have time to test your approach, maybe someone else. Sorry. |
#344