计算机科学 ›› 2025, Vol. 52 ›› Issue (9): 170-177.doi: 10.11896/jsjkx.250300031
谌燃照1, 李哲雄1, 顾琳3, 钟梁4, 曾德泽1,2
CHEN Ranzhao1, LI Zhexiong1, GU Lin3, ZHONG Liang4, ZENG Deze1,2
摘要: 容器技术因具备轻量化、易于部署和高可用等优势,在边缘服务器无感知计算平台中得到了广泛使用。然而,随着应用对低延迟需求的增长,容器的冷启动所引发的高时延问题逐渐成为系统性能的瓶颈。WebAssembly(Wasm)凭借其轻量级沙箱特性和毫秒级启动能力,成为容器技术在某些场景下的重要补充方案。然而,Wasm的计算性能相较容器存在劣势,尤其在需要处理函数间的复杂依赖关系时,Wasm和容器的固有优缺点使得函数部署方式和部署位置的决策变得十分困难。为解决该问题,构建了基于函数依赖关系的服务器无感知计算模型,将Wasm与容器混合部署问题转换为非线性整数规划问题。该问题随后被证明是一个NP-hard问题。为此,设计了长时延敏感的加权带宽贪心调度算法(Long-Latency-Sensitive Weighted Bandwidth Greedy Scheduling Algorithm,LLS-WBG),根据函数依赖以及前驱函数最长完成时间,加权计算服务器带宽,以优化资源利用并降低任务尾时延。基于真实世界数据的实验结果表明,在边缘计算场景下,与先进算法相比,所提出的算法能够使应用完成时间减少44.45%。
中图分类号:
[1]AKHTAR N,RAZA A,ISHAKIAN V,et al.Cose:Configuring Serverless Functions using Statistical Learning[C]//Procee-dings of the IEEE Conference on Computer Communications.IEEE,2020:129-138. [2]Google.gVisor[EB/OL].[2024-10-21].https://gvisor.dev/. [3]FUERST A,SHARMA P.FaaSCache:Keeping Serverless Computing Alive with Greedy-Dual Caching[C]//Proceedings of ACM International Conference on Architectural Support for Programming Languages and Operating Systems.2021:386-400. [4]LIU X,WEN J,CHEN Z,et al.FaaSLight:General Application-Level Cold-Start Latency Optimization for Function-as-a-Service in Serverless Computing[J].ACM Transactions on Software Engineering and Methodology,2023,32(5):1-29. [5]OAKES E,YANG L,ZHOU D,et al.SOCK:Rapid Task Provisioning with Serverless-Optimized Containers[C]//Proceedings of USENIX Annual Technical Conference(USENIX ATC 18).2018:57-70. [6]SHAHRAD M,BALKIND J,WENTZLAFF D.ArchitecturalImplications of Function-as-a-Service Computing[C]//Procee-dings of the Annual IEEE/ACM International Symposium on Microarchitecture.2019:1063-1075. [7]SHAHRAD M,FONSECA R,GOIRI I,et al.Serverless in the wild:Characterizing and Optimizing the Serverless Workload at a Large Cloud Provider[C]//Proceedings of USENIX Annual Technical Conference(USENIX ATC 20).2020:205-218. [8]Amazon Web Services.AWS Lambda[EB/OL].[2024-09-11].https://aws.amazon.com/cn/lambda/. [9]Microsoft.Cloud computing services | Microsoft Azure[EB/OL].[2024-09-11].https://azure.microsoft.com/en-us. [10]Apache Software Foundation.Apache/OpenWhisk- ApacheOpenWhisk is an open source serverless cloud platform[EB/OL].[2024-12-25].https://github.com/apache/openwhisk. [11]HALL A,RAMACHANDRAN U.An Execution Model forServerless Functions at the Edge[C]//Proceedings of the International Conference on Internet of Things Design and Implementation.2019:225-236. [12]SHILLAKER S,PIETZUCH P.FaaSm:Lightweight Isolationfor Efficient Stateful Serverless Computing[C]//Proceedings of USENIX Annual Technical Conference(ATC 20).2020:419-433. [13]SPIES B,MOCK M.An Evaluation of WebAssembly in Non-Web Environments[C]//Proceedings of XLVII Latin American Computing Conference(CLEI).IEEE,2021:1-10. [14]Fermyon Technologies.Writing Spin applications[EB/OL].[2024-12-20].https://developer.fermyon.com/spin/v2/writing-apps. [15]DE PALMA G,GIALLORENZO S,MAURO J,et al.Funless:Functions-as-a-Service for Private Edge Cloud Systems[J].ar-Xiv:2405.21009,2024. [16]KJORVEZIROSKI V,FILIPOSKA S.WebAssembly Orchestration in the Context of Serverless Computing[J].Journal of Network and Systems Management,2023,31(3):62. [17]LONG J,TAI H Y,HSIEH S T,et al.A Lightweight Design for Serverless Function as a Service[J].IEEE Software,2020,38(1):75-80. [18]KJORVEZIROSKI V,FILIPOSKA S.WebAssembly as an Enabler for Next Generation Serverless Computing[J].Journal of Grid Computing,2023,21(3):34. [19]JANGDA A,POWERS B,BERGER E D,et al.Not soFast:Analyzing the Performance of WebAssembly vs.Native Code[C]//Proceedings of USENIX Annual Technical Conference(USENIX ATC 19).2019:107-120. [20]MENDKI P.Evaluating WebAssembly Enabled Serverless Approach for Edge Computing[C]//2020 IEEE Cloud Summit.IEEE,2020:161-166. [21]KADUSALE I,GALA G,FOHLER G. WASM and Containers for Real-Time Serverless Edge Computing[J].JRWRTC,2024,2024:11-15. [22]GACKSTATTER P,FRANGOUDIS P A,DUSTDAR S.Pu-shing Serverless to the Edge with WebAssembly Runtimes[C]//Proceedings of IEEE International Symposium on Cluster,Cloud and Internet Computing(CCGrid).IEEE,2022:140-149. [23]VAHIDINIA P,FARAHANI B,ALIEE F S.Mitigating ColdStart Problem in Serverless Computing:A Reinforcement Learning Approach[J].IEEE Internet of Things Journal,2023,10(5):3917-3927. [24]LEE S,YOON D,YEO S,et al.Mitigating Cold Start Problem in Serverless Computing with Function Fusion[J].Sensors,2021,21(24):8416. [25]SILVA P,FIREMAN D,PEREIRA T E.Prebaking Functions to Warm the Serverless Cold Start[C]//Proceedings of the 21st International Middleware Conference.2020:1-13. [26]GADEPALLI P K,MCBRIDE S,PEACH G,et al.Sledge:AServerless-First,Light-Weight Wasm Runtime for the Edge[C]//Proceedings of International Middleware Conference.2020:265-279. [27]BRUCKER P.Scheduling algorithms[J].Journal-OperationalResearch Society,1999,50:774-774. [28]LI Z,ZENG D,CHEN R.WebAssembly or Container? Joint Optimization of Microservice Consolidation and Deployment towards Cost Efficient Edge-End Consortium[C]//2024 IEEE/ACM 32nd International Symposium on Quality of Service(IWQoS).IEEE,2024:1-10. |
|