Java程序动态更新技术研究
发布时间:2018-05-26 15:50
本文选题:动态软件更新 + Java虚拟机 ; 参考:《南京大学》2017年博士论文
【摘要】:软件已无处不在,人们也日益依赖于软件系统提供的不间断服务。然而,软件系统常需更新以修复缺陷、改进性能和增加功能。传统的软件更新需要停止正在运行的软件系统,部署新版本并重启运行。这种因软件更新而导致的服务中断可能会带来诸多不便,甚至生命财产损失。动态软件更新技术旨在不终止正在运行的系统而将其在线地升级到新版本。当前既有的动态软件更新技术存在诸多局限,特别是:(1)为高度优化的软件运行环境引入动态更新支持会带来难以接受的运行时额外开销,(2)对高度复杂的运行时状态的转换可能带来较长时间的服务中断,(3)人工开发用于转换程序运行时状态的动态更新补丁难度大,质量难以保证,(4)软件系统开发时通常不会考虑动态更新,因而缺少抵抗由于不恰当的动态软件更新而导致的运行时错误的能力。针对这些问题和挑战,本文从高效的动态软件更新实现机制、自动化的运行时对象状态转换方法以及动态更新错误自动恢复技术三个方面系统研究了Java程序动态更新支撑技术,并在工业级的Java虚拟机上实现了上述技术,得到一个高效、易用、可靠的Java程序动态软件更新系统Javelus。具体而言,本文的主要工作如下:1.提出了一种高效的延时Java程序动态更新实施机制。该机制以按需更新的方式实现对象状态的版本转换,从而大大降低了更新过程的程序中断时间,同时通过细粒度的类型分析实现了多种优化,保证了动态软件更新前、后运行时的低额外开销。2.提出了一种基于程序和执行合成的自动对象状态转换方法。该方法避免直接操纵对象内部封装的具体数据结构,而是根据对象当前的状态合成一个能生成该状态的方法执行历史,然后将该方法执行历史中的旧版本方法替换为对应的新版本方法,再通过重新执行该方法历史,生成所需的新版本对象状态。3.提出了一种基于错误处理器合成的自动错误恢复技术。该技术利用程序内部自身抵抗错误的能力来将程序从由不恰当的动态更新导致的运行时错误中恢复。在运行时错误发生时,该技术通过虚拟机截获错误,自动地生成多个备选错误处理器,同时利用按需创造的测试沙盒来选择最有可能成功的错误处理器来进行错误恢复。4.基于工业界广泛使用的HotSpot Java虚拟机实现了上述机制、方法和技术,得到一个Java程序动态更新系统Javelus 。该系统实现较完整,支持各种类型的程序修改,可以无缝集成到当前主流的开发和运行环境中。实验评估结果表明,较之既有系统,Javelus显著提高了动态软件更新的高效性、易用性和可靠性。
[Abstract]:Software has become ubiquitous, and people are increasingly dependent on uninterrupted services provided by software systems. However, software systems often need to be updated to repair defects, improve performance and add functionality. Traditional software updates need to stop running software systems, deploy new versions and launch the service. It can bring a lot of inconvenience, even loss of life and property. Dynamic software update technology is designed to not terminate the running system and upgrade it online to a new version. There are many limitations of existing dynamic software update technology, especially: (1) it is difficult to introduce dynamic update support for highly optimized software transportation environment. The extra overhead of running time, (2) the transformation of highly complex runtime state may bring a long time service interruption. (3) the dynamic update patch for the state of the transformation program is difficult to ensure, and the quality is difficult to guarantee. (4) the development of the software system usually does not consider the dynamic update, so the lack of resistance is not appropriate. In view of these problems and challenges, this paper systematically studies the dynamic update support technology of Java program from three aspects of the efficient dynamic software update implementation mechanism, automatic runtime object state conversion method and dynamic update error automatic recovery technology, and at the industrial level. The Java virtual machine implements the above technology, and obtains an efficient, easy to use, reliable Java program dynamic software update system Javelus.. The main work of this paper is as follows: 1. a high efficient dynamic update implementation mechanism of time delay Java program is proposed. It greatly reduces the interruption time of the program in the update process, and implements a variety of optimizations through the fine-grained type analysis. Before the dynamic software is updated, the low overhead of the post operation.2. puts forward an automatic object state conversion method based on program and execution synthesis. This method avoids the direct manipulation of the internal encapsulation of the object. The specific data structure is based on the current state of the object to synthesize a method that can generate the state, and then replace the old version of the method in the history of the method to the corresponding new version method. Then, by reexecuting the history of the method, a new version of the new version of the object state.3. is generated and a kind of error processing is proposed. An automatic error recovery technique that uses the ability of the program to resist errors within the program to restore the program from a runtime error caused by an inappropriate dynamic update. When the runtime error occurs, the technology intercepts errors through the virtual machine, automatically generates multiple alternative error processors, and uses the demand to create the error. Test sandbox to select the most likely success error processor for error recovery.4. based on the HotSpot Java virtual machine widely used in industry, methods and techniques to get a Java program dynamic update system Javelus. The system is more complete, supports various types of program modification, and can be integrated seamlessly. To the current mainstream development and operation environment, the experimental evaluation results show that, compared with the existing system, Javelus significantly improves the efficiency, usability and reliability of dynamic software update.
【学位授予单位】:南京大学
【学位级别】:博士
【学位授予年份】:2017
【分类号】:TP312.2
,
本文编号:1937827
本文链接:https://www.wllwen.com/shoufeilunwen/xxkjbs/1937827.html