- Building Serverless Web Applications
- Diego Zanon
- 187字
- 2021-07-15 17:31:23
Cost model
Suppose that you have built an online store with serverless. The average user will make some requests to see a few products and a few more requests to decide whether they will buy something or not. In serverless, a single unit of code has a predictable time to execute for a given input. After collecting some data, you can predict how much a single user costs on average, and this unit cost will remain almost constant as your application grows in usage.
Knowing how much a single user costs and keeping this number fixed is very important for a startup. It helps to decide how much you need to charge for a service or earn through ads or sales to have a profit.
In a traditional infrastructure, you need to make payments in advance, and scaling your application means increasing your capacity in steps. So, calculating the unit cost of a user is a more difficult task and it's a variable number.
In the following diagram, the left-hand side shows traditional infrastructures with stepped costs and the right-hand side depicts serverless infrastructures with linear costs:

- Android應(yīng)用程序開發(fā)與典型案例
- 軟件界面交互設(shè)計(jì)基礎(chǔ)
- SAS數(shù)據(jù)統(tǒng)計(jì)分析與編程實(shí)踐
- Drupal 8 Module Development
- KnockoutJS Starter
- Android系統(tǒng)原理及開發(fā)要點(diǎn)詳解
- Mastering Unity 2D Game Development(Second Edition)
- 零基礎(chǔ)輕松學(xué)C++:青少年趣味編程(全彩版)
- 3ds Max 2018從入門到精通
- 金融商業(yè)數(shù)據(jù)分析:基于Python和SAS
- Ubuntu Server Cookbook
- CryENGINE Game Programming with C++,C#,and Lua
- Implementing Domain:Specific Languages with Xtext and Xtend
- JavaScript設(shè)計(jì)模式與開發(fā)實(shí)踐
- GO語言編程從入門到實(shí)踐