TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

How Tutanota replaced Google’s FCM with their own notification system

187 pointsby grammersover 6 years ago

12 comments

yegleover 6 years ago
Is it possible for every app developer to stop using FCM? Yes, in China.<p>The result is a chaotic market. App devs will have to use multiple push machinism for different device: on Huawei phones, Huawei&#x27;s own push service is the most reliable; on other phones, you might want use SDKs from Tencent&#x2F;Baidu&#x2F;Alibaba so their app (Wechat&#x2F;Baidu search&#x2F;Taobao&#x2F;Alipay) can &quot;wake up&quot; your app to receive push. Battery life become miserable, push become unreliable. It&#x27;s to a point where the government start &quot;regulating&quot; the market (the Unified Push Alliance, <a href="http:&#x2F;&#x2F;www.chinaupa.com" rel="nofollow">http:&#x2F;&#x2F;www.chinaupa.com</a>, is lead by CAICT, a think tank of Gov of China).
评论 #17946151 未加载
Findus23over 6 years ago
This is really the chance for a great open source project. So many open source apps (Signal, Mastodon clients, riot.im, telegram-foss and more) have to do hacks to be able to deliver push notifications without GCM&#x2F;FCM<p>What if there was an open source software one could setup on a server that would provide push services for all these apps and would interact with one open source client running on android.<p>That way one would have the energy saving benefits of only handling one server connection, but the privacy benefits of a private server for oneself&#x2F;friends&#x2F;people one trusts.<p>This is definitely not easy and would require coordination between many open source projects and also additions in Android to run on a system level (maybe in lineageos and similar), but I really think it would be worth it.
评论 #17946003 未加载
评论 #17946085 未加载
评论 #17945944 未加载
xg15over 6 years ago
&gt; <i>Wouldn’t it be great if the user could just pick a “push notifications provider” in the phone settings and OS managed all these hard details by itself? So every app, which doesn’t want to be policed by the platform owner, didn’t have to invent the system anew? It could be end-to-end encrypted between the app and the app server. There’s no real technical difficulty in that, but as long as our systems are controlled by big players who do not allow this, we have to solve it by ourselves.</i><p>Fking this. ideally, this would also involve a standard API on the backend for how to send push notifications. E.g., something like:<p>1) App on phone queries OS for selected push provider.<p>2) Phone OS returns some metadata about the push provider to the app, including a a backend URL for sending messages.<p>3) App sends that URL to it&#x27;s own backend server.<p>4) When a push message should be sent, the app&#x27;s backend server invokes that URL with the message to be sent in some standardized way.<p>If - which is likely - push servies require that developers register their apps with them before use, this could be expanded by the phone OS returning a list of providers instead of just one.
评论 #17948074 未加载
Boulthover 6 years ago
People migrating from GCM to FCM need to be aware that in FCM analytics are turned on by default: <a href="https:&#x2F;&#x2F;github.com&#x2F;siacs&#x2F;Conversations&#x2F;issues&#x2F;3041" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;siacs&#x2F;Conversations&#x2F;issues&#x2F;3041</a>
评论 #17945788 未加载
emilfihlmanover 6 years ago
&gt;SSE fits our needs better than WebSocket would (it is cheaper and converges faster, because it’s not duplex). We’ve seen multiple chat apps trying using WebSocket for push notifications and it didn’t seem power efficient.<p>This is just not true unless there is some serious fuckery going on with the websocket implementation. Both require full duplex communications on the transport layer.
hawskiover 6 years ago
I&#x27;m wondering how it works with different messaging apps. I&#x27;m using mostly Facebook Messenger, because of the network effects. A few months ago I tried to use several apps to communicate with my wife. Both Signal and Wire failed to reliably send messages in under 30 minutes or so. More often then not the message would be delivered after a few hours. That&#x27;s totally unacceptable. If there are some magic settings in Android they were not properly advertised. Our phones are on quite pure 8.1 and 7 versions. So I&#x27;m back to Messenger.<p>Reading this it seems that there is a known solution to this problem. Does Mastodon offer something like private messages? Or is there a messaging app that doesn&#x27;t use FCM, but works in a way described in article?
评论 #17945828 未加载
评论 #17948812 未加载
评论 #17946351 未加载
评论 #17946812 未加载
EGregover 6 years ago
<i>Final thought: Every user should be able to choose a “Notification Provider” for every app</i><p>At Qbix, we thought deeply about this problem. Ideally, to maintain anonymity, each notification would come from some random endpoint on the cloud. But that’s not how the Internet works these days, you have to connect periodically to SOMETHING. So you can choose your own notification providers.<p>The trouble is if you have many apps, then your device is constantly connected to many servers.<p>What we settled on for now is a background process with WebSockets, but perhaps this works better. The operating systems weren’t designed for this use case and the phones aren’t optimized for it. For example, how would you do the same on iOS?<p>However, what IS possible is tunneling through the native iOS VoIP notifications support and encrypting your notifications. You can even process them on the client side with some “IFTTT” type logic. To do that for Android, however, we had to implement this background process approach. But it’s a hack.
评论 #17945933 未加载
southerndriftover 6 years ago
What&#x27;s the deal with push notifications if the modem has to be switched on every couple of minutes to keep a connection alive? I was under the impression that push notifications were implemented similar to a call handshake that only activates the phone if there is a call.<p>Are the FCM service and the iOS equivalent also IP based or can they use some lower level, more energy efficient protocols to wake up the phones?
评论 #17946320 未加载
pndyover 6 years ago
&gt; Wouldn’t it be great if the user could just pick a “push notifications provider” in the phone settings and OS managed all these hard details by itself?<p>Having the possibility of choice is a good thing but in this particular case I don&#x27;t think it would be good if 3rd party notifications providers were available. This should be an integral part of the OS, not a field for competition; knowing that Google itself can harvest data from notifications we can&#x27;t exclude the possibility that there would appear companies interested only in that activity, at the same time enticing users with pretty and simple design of notifications or whatever else.
评论 #17946362 未加载
评论 #17945733 未加载
snipemover 6 years ago
<i>Another difficulty was caused by the Doze mode, introduced in Android M. The Doze, which is turned on after a period of inactivity, among other things prevents background processes to access the network. As you can imagine, this prevents our app from receiving notifications.</i><p><i>We mitigate this problem by asking users to make an exemption from battery optimisations for our app. It worked fairly well.</i><p>This is why we were migrating to FCM from our own custom built MQTT solution that was invented back in 2012.
评论 #17946502 未加载
gustavmarwinover 6 years ago
This is a very exciting development, it&#x27;s great to see more developers take this centralisation issue seriously.<p>On this subject, many people including myself have been failing (hard) to convince Moxie that dropping FCM (or GCM or whatever the name) is the way to go for Signal, if anyone want to give a hand...<p><a href="https:&#x2F;&#x2F;www.reddit.com&#x2F;r&#x2F;signal&#x2F;comments&#x2F;9ekawn&#x2F;moxie_drop_the_gcm_requirement_already&#x2F;" rel="nofollow">https:&#x2F;&#x2F;www.reddit.com&#x2F;r&#x2F;signal&#x2F;comments&#x2F;9ekawn&#x2F;moxie_drop_t...</a><p><a href="https:&#x2F;&#x2F;github.com&#x2F;signalapp&#x2F;Signal-Android&#x2F;issues&#x2F;7638" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;signalapp&#x2F;Signal-Android&#x2F;issues&#x2F;7638</a>
azinman2over 6 years ago
Wow reading this seems like android push is a total mess (outside of FCM). Things are much simplier on the iOS side...
评论 #17946641 未加载