《2019年探索Serverless中的前端开发模式.pdf》由会员分享,可在线阅读,更多相关《2019年探索Serverless中的前端开发模式.pdf(44页珍藏版)》请在三个皮匠报告上搜索。
1、探索 Serverless 中的前端开发模式阿里云 前端工程师目录1.前端开发在 Serverless 时代的演进2.不同 Serverless 服务中的前端解决方案3.基于 Serverless 的前端开发模式4.Serverless 开发最佳实践5.总结与展望1.前端开发在 Serverless 时代的演进前端开发模式的演进基于模板渲染的动态页面基于AJAX的前后端分离基于 Node.js的前端工程化基于Node.js 的全栈开发Serverless?Serverless computing refers to the concept of building and running app
2、lications that do not require server management.无服务器计算是指构建和运行不需要服务器管理的应用程序的概念。CNCF什么是 Serverless前端早已与 Serverless 产生了联系CDN对象存储API 服务Serverless=FaaS+BaaSServerless 的特点事件驱动Event Driven无状态Stateless无运维NoOps低成本Lowcost2.Serverless 服务中的前端解决方案Serverless 服务中的前端解决方案应用场景小程序IoTComputePlatformFaaS函数计算LambdaCloud
3、RunAzure Functions基础设施Web IDEFC IDEFrameworkalicloud/funserverlessawsfcliCLInowapex开发工具不同 Serverless 服务的对比特征阿里云函数计算AWS LambdaAzure Functions支持语言Node.js/Python/PHP/Java/C#Node.js/Java/Go/PowerShell/C#/Python/RubyNode.js/C#/F#/Java/Python触发器OSS/API 网关/HTTP/CDN/日志/定时任务/RDS/表格存储/MNS/Datahub/IoTS3/Dynamo
4、DB/SNS/SES/SQS/Cognito/CloudFormation/CloudWatch/Timer/Alexa/API Gateway/IoT/CloudFrontBlob Storage/Cosmos DB/Event Grid/Event Hubs/HTTP&Webhooks/Timer/Queue storage/Service Bus边缘计算IoT EdgeCloudFrontIoT EdgeHTTP(S)调用API 网关/HTTP 触发器API 网关HTTP 触发器函数组支持不支持不支持开发工具fun/fcli/Web IDEAWS SAM CLI/Cloud9 IDEAz
5、ure CLI价格100万次免费,之后 1.33/百万次400,000GB-s免费,之后0.00011108/GB-s100万次免费,之后 0.2$/百万次400,000 GB-s免费,之后$0.00001667/GB-s100万次免费,之后 0.2$/百万次400,000 GB-s免费,之后$0.000016/GB-s3.基于 Serverless 的前端开发模式Serverless 开发流程设计服务端开发前端开发服务端部署前后端联调测试上线运维传统开发流程(前端工程师、后端工程师、运维工程师)设计应用开发测试上线Serverless 开发流程(前端工程师)Serverless 实践基于 S
6、erverless 的 BFF(Backend For Frontend)基于 Serverless 的服务端渲染基于 Serverless 的小程序开发基于 Serverless 的 BFF(Backend For Frontend)传统 BFF(Backend For Frontend)架构https:/ BFF(Backend For Frontend)的痛点重复开发难避免运维成本难降低入口分散难管理基于 Serverless 的 BFF 架构基于 Serverless 的服务端渲染传统服务端渲染性能要求高运