Live data from Hacker News

Push Notifications for Decentralized Services

unifiedpush.org

31–40 of 54 posts

Re: Push Notifications for Decentralized Services

#31

Earlier quoted context omitted.

> BTW I'm working on porting ntfy to Sandstorm. Oh this would be really handy, I'd love to run it on my Sandstorm server!

Awesome. One major caveat is that because of Sandstorm's draconian security (I mean this in a good way), a handful of ntfy's features won't work because they use special headers. Mastodon works so I'm assuming they use the json API. One of my tasks is to go through major services and test them. Another one is protected topics. "Users" use auth headers (there's a GET string option, but the Android app source code indi…

What would you say the main points are for sandstorm?

Is it about hosting apps on different domains and using a powerbox between them? Or is it something more? Why does sandstorm use capnproto for instance?

In our framework for instance, instead of capabilities, we implemented "invites", which people can send to each other. If an invite grants you readLevel access to a document, you'll be able to see it even before you log in and create a user account. But if you want to get the full access to write etc, you'll have to create a user account and accept the invite as that user.

https://github.com/Qbix/Streams/blob/main/classes/Streams/St...

Re: Push Notifications for Decentralized Services

#32

Earlier quoted context omitted.

But what is your email client using for notifications? If it's using intermittent/timed fetch, that runs into the latency problem (taking longer to receive notifications). Push notifications exist to solve that problem. If it's using IMAP's IDLE, MAPI's push, or JMAP's push, that's just another long-running HTTP or websocket connection. And this protocol (along with the proprietary push notif aggregation services it…

> But what is your email client using for notifications? Local notifications? I don't see the problem here with email, it seems to work well that it is great for my use case. When you're offline with push notifications only the latest notification gets sent, not the previous notifications. This seems by design for notifications. At least with E-mail I can see a history of emails that was sent to me. I just see push n…

I think you are thinking about something different. So "Push Notifications" can refer to two different things.

The user oriented term refers to on-device notifications that pop up at the top of the screen. Those are technically just normal notifications but people like to call them push notifications for various reasons.

Push notifications in the technical sense however refer to a system for remote services to notify a client that something happened rather than the client manually polling the server for new updates. It's the difference between the client asking "do you have anything new" and the server telling the client "hey pay attention you have something new". This is what we are talking about when we say push notifications.

Email clients that automatically get new emails in the background all either do so using fetch polling or push notifications. The traditional method is fetch polling at a regular interval but nowadays most email clients support push notifications. We are discussing a tool that these clients can use behind the scenes to provide these push notifications for the email client in a battery and data efficient manner.

Re: Push Notifications for Decentralized Services

#33
post #26

Earlier quoted context omitted.

> But what is your email client using for notifications? Local notifications? I don't see the problem here with email, it seems to work well that it is great for my use case. When you're offline with push notifications only the latest notification gets sent, not the previous notifications. This seems by design for notifications. At least with E-mail I can see a history of emails that was sent to me. I just see push n…

I don't know what you mean by local notifications, but if you get a notification when a mail arrives, it's most probably because your mail client uses Google or Apple's push service if you use a regular mobile device, or if you installed and configured microG. And here's your issue: your app that has nothing to do with Google relies on a centralised Google service, and depends on a proprietary library that speaks to…

> ... but if you get a notification when a mail arrives, it's most probably because your mail client uses Google or Apple's push service if you use a regular mobile device, or if you installed and configured microG.

Except it doesn't?

The Mail app on my iPhone doesn't use push notifications, fetch works well and I still get local notifications. No external push service at all.

> Alternatively, your app isn't doing this, but then it risks being unreliable and stop notifying you if the system kills your app because it's been inactive for some time to save battery, or to reclaim memory, and/or it uses more battery than it could.

You're saying a bunch of "issues" that never actually happened with me or anyone really, there is actually no issues here.

E-Mail is fine.

Re: Push Notifications for Decentralized Services

#34
> Regarding iOS, they have made some progress in adopting webpush, but it does not seem possible to push for mobile applications with it yet.

This is a key point right at the very end. It has always been much easier to implement push notifications to Android devices, even when only Web Push is implemented. Google has been the main force behind the adoption of PWAs as Native apps on devices, even by immediately showing a "Install this app?" popup when navigating to a PWA-enabled website/web app.

iOS permits "Installing to home screen" but there is no popup shown natively, nor any indication from the OS that the website you're visiting is a PWA. The user has to go through several steps to add the app to his device.

Once it is added, it's possible for the device to receive web push notifications and show them as native push notifications (IIRC), even with the app is closed, however the reliability is inconsistent. Sometimes you get them, sometimes you don't. At least that was my experience still about 6 months ago when I tried implementing web push with PWA for iOS.

I gave up trying to go the pure PWA route and instead wrapped my web app with PWABuilder into a native app, and went through the whole process of submitting to the App Store, getting APN, registering the web app in Firebase, then sending the push notifications to the native app via Firebase Messaging. Works great then, but it's a lot more work than keeping everything simply as a web app and using web push.

Re: Push Notifications for Decentralized Services

#35

Earlier quoted context omitted.

They are doing that by polling private servers, which is sometimes less efficient power-wise, and sometimes notifications are being delivered slower than in case of using Google-provided mechanism (FCM). We've been using ntfy for alerting, using our private server and running ntfy client in polling mode, and I do not see significantly increased battery usage by the ntfy client; Android 15.

So ntfy Android app polls a ntfy service. (Which is more efficient than each app polling separately) What does Google's Android library do if not also poll? Does it run a server on the phone? Does it get special signals from cell towers that most apps don't have access to?

It also polls, it just does it as part of the OS. Power saving by the OS can often interfere with apps like nfty that want a long-running background process, especially if they haven’t been opened in a while.

Re: Push Notifications for Decentralized Services

#36

> Regarding iOS, they have made some progress in adopting webpush, but it does not seem possible to push for mobile applications with it yet. This is a key point right at the very end. It has always been much easier to implement push notifications to Android devices, even when only Web Push is implemented. Google has been the main force behind the adoption of PWAs as Native apps on devices, even by immediately showin…

https://news.ycombinator.com/item?id=38430581

Web push is basically useless because Google hasn't prioritized fixing the issues causing Android to delay the notifications by 10 minutes or more. They are basically only useful for "re-engagement" spam, nothing time critical.

Re: Push Notifications for Decentralized Services

#37
post #26

Earlier quoted context omitted.

I don't know what you mean by local notifications, but if you get a notification when a mail arrives, it's most probably because your mail client uses Google or Apple's push service if you use a regular mobile device, or if you installed and configured microG. And here's your issue: your app that has nothing to do with Google relies on a centralised Google service, and depends on a proprietary library that speaks to…

> ... but if you get a notification when a mail arrives, it's most probably because your mail client uses Google or Apple's push service if you use a regular mobile device, or if you installed and configured microG. Except it doesn't? The Mail app on my iPhone doesn't use push notifications, fetch works well and I still get local notifications. No external push service at all. > Alternatively, your app isn't doing th…

How frequently is the app checking for new emails?

Re: Push Notifications for Decentralized Services

#38
post #26

Earlier quoted context omitted.

I don't know what you mean by local notifications, but if you get a notification when a mail arrives, it's most probably because your mail client uses Google or Apple's push service if you use a regular mobile device, or if you installed and configured microG. And here's your issue: your app that has nothing to do with Google relies on a centralised Google service, and depends on a proprietary library that speaks to…

> ... but if you get a notification when a mail arrives, it's most probably because your mail client uses Google or Apple's push service if you use a regular mobile device, or if you installed and configured microG. Except it doesn't? The Mail app on my iPhone doesn't use push notifications, fetch works well and I still get local notifications. No external push service at all. > Alternatively, your app isn't doing th…

> Except it doesn't?

See how I introduced your case later with "Alternatively"? You saw it since you quoted me.

Fine, your email app works well in fetch mode. It took you three roundtrips to mention your actual setup despite having been asked about it quite early and despite it being a critical element in this discussion. Omitting to mention that doing this choice, your notifications are delayed.

Fetch mode is totally a valid choice, email doesn't need to be real time for every one. It will actually save battery life from what I can read: you don't need constant polling. Of course, push notifications are for real time stuff. What costs battery life or requires a push notification service on current widespread mobile devices is timely notifications. I can't help you if you fail to see how this can be useful, even if you don't personally need this or are against the idea.

Despite a thread that started well (yeah, notifications via emails, a decentralized, open standard, why not? It's terrible for many reasons including deliverability and the fact that you need to be notified of new mails so it's a bit of a chicken and egg issue, but sure, let's discuss), you don't seem actually curious or interested in the topic at hand, preferring to stick to your original point of view, to ignore the answers from all of us and to ultimately show contempt and spite to people discussing with you here. By the way, frankly, loose the scare quotes, they are ridiculous. Of course Apple Mail's fetch mode will be reliable on iOS but that doesn't make the topic trivially solved and yes, the problem exists despite what you are stating.

You are calling something over engineered without stopping to wonder why the complexity, assuming it's useless.

Re: Push Notifications for Decentralized Services

#39

This looks very over engineered and complicated, we don't need more push notifications. Just use or improve upon email or RSS (recommended). It's anonymous, fast, privacy friendly (no device registrations or whatever), open and already decentralised so no need for anything else.

I would like all my push notifications to not rely on Google so this seems good to me.

Signal sending me an email to tell me I have a new message would be a bad system.

Post reply on HN