Re: [w3c/push-api] A javascript api for sending push notifications to others (#303)

Yeah, I can see your point.

I apologize that I'm not familiar with the CORS note you mention, but I can also see it being a bit of an abuse vector. It's also kind of funny to me that in some respects, you're substituting one Websocket service for another, since our Push service for desktop is Websocket based. I mean, it's absolutely fair, and I'm not slighting your idea at all, it's just one of those "paths of least resistance" things I sometimes talk about in design meetings.

FWIW, I know that one of the bigger challenges with websockets is routing, particularly around firewalls. The internet hates long lived things, and definitely doesn't like unexpected things. (I mean, the fact that STUN is a thing and actually works is hilarious, but also why public STUN servers are a rarity.) 

And since you're gonna need a payload (the URL of the hosting service at least), you're going to have to also manage the encryption keys for all the connections. Push doesn't do broadcast. At all. For a reason. (The reason is privacy.) The way I used to tell folk to do broadcast was to say "Have the clients go check a well known, public URL." (Update the URL with whatever content (encrypted or not), use a data free push to alert the UAs to go update, each pulls when it can). That still requires a common server for your service, which I think you wanted to get away from. 

It also sounds like you're having fun with stateless computing. For that, you're gonna need some commonly shared data store. (There are "clever" ways to do it with internode communication, but trust me, go with the far simpler and more reliable common data store approach. Future you will not invent a time machine to murder you that way. Ask me how I know.)

-- 
Reply to this email directly or view it on GitHub:
https://github.com/w3c/push-api/issues/303#issuecomment-1419445150
You are receiving this because you are subscribed to this thread.

Message ID: <w3c/push-api/issues/303/1419445150@github.com>

Received on Monday, 6 February 2023 17:20:07 UTC