基于动态和静态分析的单体应用FaaS改造方法
作者:
作者单位:

作者简介:

通讯作者:

彭鑫,E-mail:pengxin@fudan.edu.cn

中图分类号:

TP311

基金项目:

国家重点研发计划资助(2018YFB1004803)


Dynamic and Static Analysis based FaaS Migration Approach for Monolithic Applications
Author:
Affiliation:

Fund Project:

  • 摘要
  • |
  • 图/表
  • |
  • 访问统计
  • |
  • 参考文献
  • |
  • 相似文献
  • |
  • 引证文献
  • |
  • 资源附件
  • |
  • 文章评论
    摘要:

    作为Serverless架构的一种典型形态,函数即服务(Function as a Service,简称FaaS)架构将业务抽象为细粒度的函数,并且提供弹性的自动伸缩等自动化运维功能,能够大幅降低运维成本.当前许多在线服务系统中的一些高并发、高可用、灵活多变的业务(如支付、红包等)都已经迁移到了FaaS平台上,但是大量传统单体应用还是难以利用FaaS架构的优势.针对这一问题,本文提出了一种基于动态和静态分析的单体应用FaaS改造方法.该方法针对指定的单体应用API,通过动态分析和静态分析相结合的方式识别并剥离其实现代码和依赖,然后按照函数模板完成代码重构.针对函数在高并发场景下的冷启动问题,该方法利用基于IO多路复用的主从多线程Reactor模型优化了函数模板,提高了单个函数实例的并发处理能力.基于该方法我们实现了针对Java语言的原型工具Codext,在开源Serverless平台OpenFaaS上面向4个开源单体系统进行了实验验证.

    Abstract:

    As a typical form of the Serverless architecture, the Function as a Service (FaaS) architecture abstracts the business into fine-grained functions, and provides automatic operation and maintenance functionality such as auto-scaling, which can greatly reduce the operation and maintenance costs. Some of the high concurrent, high available, and high flexible services (such as payment, red packet, etc.) in many online service systems have been migrated to the FaaS platform, but a large number of traditional monolithic applications still find it difficult to take advantage of the FaaS architecture. In order to solve this problem, a dynamic and static analysis based FaaS migration approach for monolithic applications is proposed in this paper. This approach identifies and strips the implementation code and dependencies for the specified monolithic application API by combining dynamic and static analysis, and then completes the code refactoring according to the function template. Aiming at the cold-start problem of functions in high concurrency scenario, this approach uses the master-slave multithreaded Reactor model based on IO multiplexing to optimize the function template and improve the concurrency processing capability of a single function instance. Based on this approach, we implemented Codext, a prototype tool for Java language, and carried out experimental verification on OpenFaaS, an open source Serverless platform, for four open source monolithic applications.

    参考文献
    相似文献
    引证文献
引用本文

向麒麟,彭鑫,赤坂居纱美,李博文.基于动态和静态分析的单体应用FaaS改造方法.软件学报,,():0

复制
分享
文章指标
  • 点击次数:
  • 下载次数:
  • HTML阅读次数:
  • 引用次数:
历史
  • 收稿日期:2020-12-22
  • 最后修改日期:2021-04-26
  • 录用日期:
  • 在线发布日期: 2021-12-24
  • 出版日期:
您是第位访问者
版权所有:中国科学院软件研究所 京ICP备05046678号-3
地址:北京市海淀区中关村南四街4号,邮政编码:100190
电话:010-62562563 传真:010-62562533 Email:jos@iscas.ac.cn
技术支持:北京勤云科技发展有限公司

京公网安备 11040202500063号