TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Why is scaling a web application hard?

2 点作者 drubio超过 14 年前

1 comment

kls超过 14 年前
<i>However, there are two particular design choices that increase complexity when attempting to horizontally scale each tier: Decoupling and sessions.</i><p>Session is by far the deal with the devil that comes back to haunt you later in life. Introducing a stageful concept into a stateless medium was destin to have ramifications. I remember the first implementation of the concept of session in a web framework. I remember a developer that I worked with going on and on about it and I remember thinking right there that is a very dangerous pattern.<p>At our shop we do three things. One we only store the most critical information in session (if at all), we have an audit script on our source control system that generates a warning to the leads any time new access to session is developed and finally we always ensure that session can be recreated from a stateless medium. Therefore session acts like an in memory cache for us.