-
-
Notifications
You must be signed in to change notification settings - Fork 63
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
document how to use TorService with foreground priority via binding #64
Comments
Android's More on bound services: https://developer.android.com/guide/components/bound-services |
Orbot does this today. OrbotService is the application specific foreground service that then binds to TorService: |
The Chromium docs outline some nice security properties of bound services: |
It seems to me that we should be recommending WorkManager here also. Google is putting a lot of work into it to make it the complete background task runner. This is based on this discussion #61 (comment) WorkManager started out for short lived background tasks, but has been extended to handle foreground and long-lived tasks: |
heya I was wondering is there any documentation on implementing torservice on android? I tried the sampleapp, which doesn't work for me as well. |
There isn't really documentation outside of the example code and apps at this
point. We welcome contributions. You can see it in production code in the
TorServices app, OnionShare, Orbot, and some others.
|
@eighthave atm I couldn't even start the sampleapp. even tho I just clone it from the repo. |
Android gives "foreground" priority to the activity that is currently visible. Things that are at the foreground priority are the last to be killed. With
Service
instances, it is possible to set the service to be permanently at the "foreground" priority as long as there is a permanent notification. It is also possible for aService
to get foreground priority if the currently active screen is bound to theService
usingBIND_IMPORTANT
.The text was updated successfully, but these errors were encountered: