I was using room in my android project, everything was working fine until one day I found Room doesn't insert data in db immediately.
How I reproduced it
When I run command appdatabase.getUserDao().insert(user) and after 2 seconds when i remove my battery from my phone and export db after that What I found is data is not inserted in db. that is 100% sure because my team has reproduced it multiple times. it seems instead of directly store into db it caches data for some time.
Is there any solution for it Where data will directly store in db instead it caches?