Two apps one process
5 points by andersmurphy
5 points by andersmurphy
When did an app (short for "application") become "a domain, a database and some routes?" (Me looks at Photoshop running locally on my computer ... )
A desktop app still has the concept of routes, will have a sqlite database, and effectively has a domain (to handle deeplinks). Especially one as complex as photoshop. I used to be an android/iOS native developer.
So am I wrong?
What are the routes, database, and domain / deeplinks for Calculator?
You obviously don't have to have these things. But, at a certain level of feature richness they become useful.
"a certain level of feature richness" presupposes both what an app does and how it does it. There are many large classes of apps that both "don't have to have these things" and that having these things would be torturing abstractions. (e.g. multi-document interfaces, canvases, simulations, …)
This article would really benefit from Some numbers. As it is, it advocates for adding constraints, significantly reducing isolation between web servers and complicating deployment, all without presenting any concrete benefits, which are likely to be borderline irrelevant for most apps and servers.
So currently. It can handle 1000+ concurrent users per core at 10FPS (so 10k SSE events per second) generating 3mb of html uncompress per user (most apps don't have 300kb html per page). Each connection has a zstd compressor with 512kb window. So small changes result to 14-30bytes over the wire. Each render for each user does around 25 database queries. Handles much more if less is changing, these numbers are from a worst case cache thrash load test.
Writes are batched. So can scale to 50-100k TPS per core (sqlite is single writer but you can have different apps writers run on different cores if you need to).
This whole adventure mostly started because it scales well and the irony is most apps don't have that many users. So what to do with that performance.