Live data from Hacker News

Server-Sent Events: an alternative to WebSockets

germano.dev

131–140 of 266 posts

Re: Server-Sent Events: an alternative to WebSockets

#131
post #120
post #114

Earlier quoted context omitted.

I respect your right to license you product however you want, but please don't call that open source.

Open-source also means the source is open, what you are looking for is free and honestly nothing is free... if you have a better term I'm open for suggestions. But really open-source (as in free) is the misnomer here, it should be called free open-source, or FOSS as some correctly name it.

I've seen these referred to as "Source-available licenses". This would cover things like Mongo's SSPL.

The bare reality is that it's just a commercial license.

Re: Server-Sent Events: an alternative to WebSockets

#132
post #80

Earlier quoted context omitted.

> Browsers also limit the number of websocket connections True but the limit for websockets these days is in the hundreds, as opposed to 6 for regular HTTP requests.

https://stackoverflow.com/questions/26003756/is-there-a-limi... It appears to be 30 per domain, not “hundreds”, at least as of the time this answer was written. I didn’t see anything more recent that contradicted this. In practice, this is unlikely to be problematic unless you’re using multiple websockets per page, but the limit of 6 TCP connections is even less likely to be a problem if you’re using HTTP/2, since th…

It’s 255 for Chrome and has been since 2015, 200 for Firefox since longer than that.

https://chromium.googlesource.com/chromium/src/net/+/259a070...

Agree that it should be much less of a problem with HTTP/2 than HTTP/1.1.

Re: Server-Sent Events: an alternative to WebSockets

#134
post #6
post #4

I can’t find any downsides of SSE presented. My experience is that they’re nice in theory but the devils in the details. The biggest issue being that you basically need http/2 to make them practical.

Absolutely not, HTTP/1.1 is the way to make SSE fly: https://github.com/tinspin/rupy/wiki/Comet-Stream Old page, search for "event-stream"... Comet-stream is a collection of techniques of which SSE is one. My experience is that SSE goes through anti-viruses better!

Take this for what it's worth, but I see you share rupy on pretty much every thread that mentions WebSockets, and I click on the link pretty much every time, and I still have basically no idea what it is. Documentation probably isn't your priority at the moment, but even just a couple paragraphs could go a long way.

Re: Server-Sent Events: an alternative to WebSockets

#135

This seems fairly cool, and I appreciate the write up, but god I hate it so much when people write code samples that try and be fancy and use non-code-characters in their code samples. Clarity is much more important then aesthetics when it comes to code examples, if Im trying to understand something I've never seen before, having a bunch of extra non-existant symbols does not help.

Which characters, the funky '≠'? I've seen those pop up a few other times recently, which makes me wonder if there's some editor extension that just came out that maps != and !==

They're ligatures.

https://github.com/tonsky/FiraCode

Re: Server-Sent Events: an alternative to WebSockets

#136
post #67

Earlier quoted context omitted.

Sure but then HTTP/3 is still binary and it's in flux meaning most routers don't play nice with it yet and since HTTP/1.1 works great for 99.9% of the usecases I would say it's a complete waste of time, unless you have some new agenda to push. Really people should try and build great things on the protocols we have instead of always trying to re-discover the wheel, note: NOT the same as re-inventing the wheel: http:/…

HTTP/3 is E2E encrypted and built on UDP. What does “most routers don’t play nice with it yet” mean in that context? Do you mean middleware boxes/routers rather than end user routers?

It means they don't actually understand networking, but think they do.

Re: Server-Sent Events: an alternative to WebSockets

#139
post #128
post #120

Earlier quoted context omitted.

Open-source also means the source is open, what you are looking for is free and honestly nothing is free... if you have a better term I'm open for suggestions. But really open-source (as in free) is the misnomer here, it should be called free open-source, or FOSS as some correctly name it.

That battle has been fought already, and the accepted term is "source available", not "open source". (And gnu adds Free or "libre" software, which is software licence in a way that tries to ensure the "four freedoms" for all downstream users of software - such as freedom zero - the right to run software (no need for eg: cryptographic signature/trusted software - without a way for the user to define trust).

Ok, fixed it elsewhere and in my brain... :/ Thx! Can't edit the comment though.

Re: Server-Sent Events: an alternative to WebSockets

#140

Did research on SSE a short while ago. Found out that the mimetype "text/event-stream" was blocked by a couple of anti-virus products. So that was a no-go for us.

I was using SSE when they'd just launched (almost a decade ago now) and never faced any AV issues.

Is that still the case now? How big and broad an audience do you have?

My experience, now a bit dated, is that long polling is the only thing that will work 100% of the time.

Post reply on HN