运行时体系结构是系统运行时刻的一个动态、结构化的抽象,描述系统当前的组成成分、各成分的状态和配置以及不同成分之间的关系.运行时体系结构与目标系统间具有动态的因果关联,即系统的变化及时体现在体系结构上,而对体系结构的修改及时影响当前系统.运行时体系结构允许开发者以读写体系结构的方式实现系统的监测和调整,是体系结构层次系统动态适应与在线演化的基础.构造运行时体系结构的关键是针对不同的目标系统和体系结构风格实现合适的基础设施,以维护二者之间的因果关联.由于目标系统和体系结构的多样性以及因果关联维护逻辑的复杂性,这一构造过程往往过于繁琐、易错、难以复用和维护.提出一种模型驱动的运行时体系结构构造方法.开发者只需针对目标系统、体系结构以及两者之间的关系分别进行建模,根据这些模型,支撑框架自动构造合法而高效的运行时体系结构基础设施.基于MOF和QVT标准建模语言定义了一组运行时体系结构建模语言,并基于通用的模型与系统间同步技术实现了相应的支撑框架.一系列实例研究表明,该方法具有广泛的适用性,并显著提高了运行时体系结构构造过程的效率与可复用性.
Runtime software architecture is a dynamic and structural abstract of the running system,which describes the elements of current system,the state of these elements,and the relation between them.Runtime architecture has a causal connection with the running system,in order for system administrators to monitor and control the system through reading and editing the architecture.The key to construct a runtime architecture is to develop the infrastructure between the target architecture and system.This is done to maintain the causal connection between them.However,because of the diversity of target systems and architectures,and the complexity of the causal connection maintaining logic between them,the development of such infrastructures is tedious,error-prone,and hard to reuse or evolve.This paper presents a model-driven approach to constructing runtime architectures.Developers describe the target system,the architecture,and the relation between them as declarative models,and the supporting framework automatically generates the runtime architecture infrastructures.The research designs the runtime architecture modeling language based on the extension of the standard MOF and QVT languages,and implements the supporting framework based on a set of general synchronization techniques between the system and architecture.A set of case studies illustrate that this approach applies to a wide range of systems and architectures and improves the efficiency and reusability of the construction of runtime models.