-
Notifications
You must be signed in to change notification settings - Fork 0
Keep node running when the app is in background #124
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
Conversation
app/src/main/java/to/bitkit/androidServices/LightningNodeService.kt
Outdated
Show resolved
Hide resolved
…eWhenNodeRunning logic
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome work, thanks a lot for your perseverance on this, it reached a pretty nice shape 🚀
Overall, everything that was pointed out in previous review is fixed very nice and a little more, with great care 🙌. Also, the wallet sync is more robust, as an additional improvement alongside what the FG service adds.
💡 remark: (added an issue for it: #134)
Maybe one last optimization of big impact for users on my mind, but not blocking here:
Having the notification show up without wallet info, (ie. on fresh install with no wallet or after wallet wipe) feels a bit strange from the user’s perspective IMHO. Maybe we should look if there’s an optimal solution to run & stop it in connection to whether there is a wallet or not.
Test Results 2
- ✅ send onchain, LN
- ✅ CJIT: BG receive (via wake2) - after node stop via notification
- ✅ UX to stop node android-service via notification
- ✅ receive: LN, LN in bg via node FG service
- ✅ balance updated correctly after: restore, create, fund - sync seems faster 👏
- ✅ on fresh install > create wallet > fund > mine - all good
- ✅ node stopped when wiping wallet + great logging 👏
- ✅ node lifecycle is synced to to wallet exists state
- ✅ register for notifications - works great
- ✅ pull-to-refresh ux 👏
Attach the node instance to a foreground service so it keeps running when the app is in background
WalletViewModelto the repositoriesRelated to #50
Closes #76
payment_background.webm