title: Firebase FCM has become very unstable. Looking for a solution / alternatives
body: <p>Our app with more than a million subscribers is facing huge delivery issues with FCM. It has become worse lately and the service is hardly working anymore. We are receiving errors like:</p>
  
  <pre><code> { code: 'messaging/message-rate-exceeded',
   message: 'Topic quota exceeded.' },
  codePrefix: 'messaging' }
  </code></pre>
  
  <p>We get this error a lot. And it seems to be worse during EU / US evenings. In some cases over 90% of the notifications are failing.
  We are in contact with the firebase support team, but so far there seems to be no solution. The gave us lots of information with some useful facts though:</p>
  
  <ul>
  <li>resources are shared between developers. So the max message rate can be different because of other developers taking up resources.</li>
  <li>OR queries should be converted to multiple AND queries because OR queries actually generate messages to all of user base, and then the filtering condition is applied</li>
  <li>240 messages/minute and 5,000 messages/hour to a single device.</li>
  <li>limit upstream messages at 15,000/minute per project (we don't understand this one)</li>
  <li>limit upstream messages per device at 1,000/minute</li>
  </ul>
  
  <p>They also updated their docs at <a href="https://firebase.google.com/docs/cloud-messaging/concept-options#topics_throttling" rel="noreferrer">https://firebase.google.com/docs/cloud-messaging/concept-options#topics_throttling</a> </p>
  
  <p>So we are aware of message rate limits and fanouts mechanism. In our case we have an approximate of 6000 different topic send requests per hour and on average 10k subscribers per topic. 
  A single user will never get more than 50-100 notifications per hour.
  We believe we are not hitting the limits set by FCM.</p>
  
  <p>Back in the GCM time everything worked fine. So we are quite unhappy about the current situation. The core functionality of the app is really bad right now. And a solution seems to be not there.</p>
  
  <p>We are considering switching to a SSE solution.
  There is a story about someone who succesfully moved away from FCM
  <a href="https://f-droid.org/en/2018/09/03/replacing-gcm-in-tutanota.html" rel="noreferrer">https://f-droid.org/en/2018/09/03/replacing-gcm-in-tutanota.html</a>
  But since Google has made it very difficult lately to have background processes running, I wonder what other people with similar experience did.
  Or can we still fix this situation?</p>