4 ms·
Not only is it a "default option" that is making the web less decentralized, it is also way overkill for something as simple as this. Make sure nginx serves cac
by capableweb 5y ago
Not only is it a "default option" that is making the web less decentralized, it is also way overkill for something as simple as this. Make sure nginx serves cached content (right headers) instead of reading the content from disk and maybe, just maybe, throw in a static cache like varnish in front.
For the times my websites hit the frontpage of HN, a simple nginx instance (without any cache in front like Varnish) on a $5/month Digital Ocean server was enough to handle things.
- majewsky 5y agoSame for my site: https://xyrillian.de/thoughts/posts/latency-matters-aftermath.html https://xyrillian.de/thoughts/posts/latency-matters-aftermat...
- brundolf 5y agoYou don't even need nginx; I've got a single Node process on a Heroku "hobby" node serving my site, and it's weathered several front-page visits peaking at 15 requests per second without problems. The important thing is the static-rendering (assuming it applies for your site's content)
- mst 5y agoHaving a blog post of mine get posted to HN (many years ago) was how I discovered I'd accidentally introduced a bug into my web server config that meant the app server behind it was serving the static assets as well as the dynamic stuff. It entered a state of wedgitude quite rapidly when traffic ramped up.
- robertlagrant 5y ago> making the web less decentralized In this case, this is not a virtue. Using a CDN is option, reversible and is likely to spread your content out to be much less centralised than anything hand rolled.
- capableweb 5y agoExcept when 20% of the web does that the web as a whole become less decentralized, while your files might still be further spread apart in the world. What I was thinking about was the web as a whole, not my specific files.
- robertlagrant 5y agoCourse it's decentralised. Decentralised is about technologies, not about which provider you pick to run your decentralised technologies for you.
- catern 5y ago>that is making the web less decentralized Sadly I don't see any alternative. The need for CDNs is a direct result of the structure of the internet and modern HTTP. We could imagine alternative infrastructures - decentralized transparent network-layer caching so that the network itself caches data and responds to requests with cached results - but the end-to-end structure of TCP and HTTPS make that impossible, for better or for worse. So we have to use CDNs.