Is it possible to make onDataChange () not working the same way you set the listener, but instead only when the actual data changes?
No, this is not possible as you want. The firebase listener starts immediately after you authenticate and configure the eventlistener.