Websockets are an all or nothing proposition

(written by lawrence krubner, however indented passages are often quotes). You can contact lawrence at: lawrence@krubner.com

Interesting:

I’m also a heavy websocket user, and agree with most points. I have previously used websockets on top of a traditional web app, and have been disappointed with the results.

My opinion now is that websockets are an all-or-nothing proposition. And I have gone all-in. My latest project has:

- websockets-only api (except a some image uploads and oauth/login)

- https-only

- single page app, central store with observable data, using a single connection servicing the whole application

- using SignalR (supports fallbacks for IE9 and old Android)

- Actor-based backend (Orleans)

This stack feels like the future to me, but I’ve had to learn a lot of new things. It’s quite different from the web development that I’ve done over the past 15 years. Overcoming the connectivity issues mentioned in the article is only the first step. Websockets need another type of backend to make sense: Actors. I’ve had many challenges with the async realtime behaviour of the system, deadlocks, etc.

But now that everything is working and I have some grip on it, I can’t imagine going back to a rest/database/cache web architecture.

Source