title: Firebase Authentication issue getGoogleApiForMethod() returned Gms
body: <p>In my current implementation of Firebase Authentication and Real Time Database (RTDB) in my new android app (using the MVP architecture). Instead of putting the AuthStateListener logics in my MainActivity View class. I placed it in the Presenter class. The Presenter class attaches or detaches the listener in response to the view lifecycle (onResume calls to attach the listener in presenter, onPause calls to detach the listener in presenter).</p>
  
  <p><strong>Issue:</strong> after the devices goes inactive (probably server closes off the connection), goes active again.  The user is still logged in (expected behavior), but unexpectedly, the logged in user can’t access Firebase RTDB anymore, and yet the RTDB doesn't throw any read/write permission denied errors. Any database read/write operation from that point on won't work, confirmed from the Firebase Console. </p>
  
  <p>The log cat repeatedly shows the following warning when this issue occurs, seems to be a back-off login attempt strategy in play?</p>
  
  <pre><code>12-10 14:09:23.671 13076-13271/appname W/BiChannelGoogleApi: [FirebaseAuth: ] getGoogleApiForMethod() returned Gms
  
  12-10 14:09:27.191 13076-13271/ appname W/BiChannelGoogleApi: [FirebaseAuth: ] getGoogleApiForMethod() returned Gms
  
  12-10 14:09:28.182 13076-13271/ appname W/BiChannelGoogleApi: [FirebaseAuth: ] getGoogleApiForMethod() returned Gms
  
  12-10 14:09:29.659 13076-13271/ appname W/BiChannelGoogleApi: [FirebaseAuth: ] getGoogleApiForMethod() returned Gms
  </code></pre>
  
  <p>The issue would be resolved if the user signed out, and then sign in and become active again. When the user is active, any NEW read/write operations would go though, but the previous ones were not persisted or retried.</p>
  
  <p>The relevant version I’m using are</p>
  
  <pre><code>// Firebase
  implementation "com.firebaseui:firebase-ui-auth:3.1.0"
  implementation "com.google.firebase:firebase-database:11.6.2"
  implementation "com.google.firebase:firebase-auth:11.6.2"
  </code></pre>
  
  <p>Is there any best practice information for implementing Firebase Auth with database within a MVP structure in an Android app?</p>