I have an single Activity application that starts a Service and binds to it.
I want the Service to continue to run even after I exit the Activity.
Right now I am doing a stopService then an unbindService. My assumption is that I do need to unbind but to keep it running I shouldn’t (obviously) call stopService, right?
I just want to know the proper service management techniques for a long running service.
This one can be answered from the Service documentation:
To clean up your service, it is good practice to unbind it. You can always restart it again using another intent with a Context.startService(). Depending on how you use it, it might be optimal to start the service for a while, do some stuff, stop it (you can even use a call to stopSelf to do this), and then restart it again when you have more work to do — or get another intent.