My app put in the notification connectivity infomration
the Wifi SSID + ip or mobile carrier name + IP
and the connected bluetooth device name
when the service get killed the notification might be incorrect so I want to remove it,
in most cases it is ok, since I'm listening to connectivity events and will be awaken when a change happen
so more or less it is ok, but still the edge case is that when the service awake it does not know if a notification exist or not and what it is, so it recreate it (which mean you get an additional vibrate / sound etc for no change what so ever)
I can mitigate it a bit be keeping the state in a file but since it it not 100% that the file got written before the app got killed, I willhave cases where the service started it look at the file decide that the notification is the same (which is not - the change just move to the exact place before the crush) and present wrong status
or decide to do the extra vibrate for not reason
nir