title: FirebaseInstanceIdService is deprecated
body: <p>Hope all of you aware of this class, used to get notification token whenever firebase notification token got refreshed we get the refreshed token from this class, From following method.</p>
  <pre><code>@Override
  public void onTokenRefresh() {
      // Get updated InstanceID token.
      String refreshedToken = FirebaseInstanceId.getInstance().getToken();
      Log.d(TAG, &quot;Refreshed token: &quot; + refreshedToken);
  }
  </code></pre>
  <p>To use this as i want to implement FCM, I extended MyClass from <code>FirebaseInstanceIdService</code></p>
  <p>But, Showing that <strong>FirebaseInstanceIdService is deprecated</strong></p>
  <p>Does anybody know this?,
  What method or class i should use instead of this to get refreshed token as this is deprecated.</p>
  <p>I'm using : <code>implementation 'com.google.firebase:firebase-messaging:17.1.0'</code></p>
  <p>I checked the document for same there is nothing mentioned about this. : <a href="https://firebase.google.com/docs/reference/android/com/google/firebase/messaging/FirebaseMessagingService" rel="nofollow noreferrer">FCM SETUP DOCUMENT</a></p>
  <hr />
  <p><strong>UPDATE</strong></p>
  <p><strong>This issue has been Fixed.</strong></p>
  <p>As Google deprecated the <code>FirebaseInstanceService</code>,</p>
  <p>I asked the question to find the way and i get to know that We can get the Token from <strong>FirebaseMessagingService</strong>,</p>
  <p>As before, when i asked the Question Documents were not updated but Now Google docs updated so for more info, Refer this google doc : <a href="https://firebase.google.com/docs/reference/android/com/google/firebase/messaging/FirebaseMessagingService" rel="nofollow noreferrer">FirebaseMessagingService</a></p>
  <p><strong>OLD From : FirebaseInstanceService  (Deprecated)</strong></p>
  <pre><code>@Override
  public void onTokenRefresh() {
      // Get updated InstanceID token.
      String refreshedToken = FirebaseInstanceId.getInstance().getToken();
      Log.d(TAG, &quot;Refreshed token: &quot; + refreshedToken);
  }
  </code></pre>
  <p><strong>NEW From : FirebaseMessagingService</strong></p>
  <pre><code>@Override
  public void onNewToken(String s) {
      super.onNewToken(s);
      Log.d(&quot;NEW_TOKEN&quot;,s);
  }
  </code></pre>