How to keep beaconservice active after stopping local service in app that implements BeaconConsumer

I am using Alt Beacons library in my android application for beacon detection. I have used a service in my application that calls an API, takes json response

that has UUID

, and then binds the beacon service to the local service. Everything works fine. Lighthouses show up in Ranging. But when I stop the local service I get the following error:

11-26 14: 25: 42.213: E / ActivityThread (25940): Service com.example.service.GetRegionService leaked ServiceConnection org.altbeacon.beacon.BeaconManager$1@41faac98 , originally here

and the lighthouse service stops working . How can I get the beacon service to work in background

when I stop my own service that implements BeaconConsumer

.

Thanks for any help on the same.

+3


source to share





All Articles