Enterprise software systems are increasingly integrating with diverse services to meet expanding business demands. Testing these highly interconnected systems presents a challenge due to the need for access to the connected services. Service virtualization has emerged as a widely used technique to derive service models from recorded interactions, for service response generation during system testing. Various methods have been proposed to emulate actual service behavior based on these interactions, but most fail to account for the service's state, which reduces the accuracy of service emulation and the realism of the testing environment, especially when dealing with stateful services. This paper proposes an approach to deriving service models from service interactions, which enhance the accuracy of response generation by considering service state. This is achieved by uncovering contextual dependencies among interaction messages and analyzing the relationships between message data values. The approach is evaluated using interaction traces collected from both stateful and stateless services, and the results reveal notable enhancements in accuracy and efficiency over existing approaches in service response generation.
翻译:企业软件系统日益集成多样化服务以满足不断扩展的业务需求。测试这类高度互联系统面临挑战,主要原因在于需要访问所连接的服务。服务虚拟化已成为一种广泛应用的技术,通过从记录的交互中推导服务模型,在系统测试期间生成服务响应。现有研究提出了多种基于交互记录模拟实际服务行为的方法,但大多未考虑服务状态,这降低了服务仿真的准确性和测试环境的真实性,尤其在处理有状态服务时更为明显。本文提出一种从服务交互中推导服务模型的方法,通过考虑服务状态提升响应生成的准确性。该方法通过揭示交互消息间的上下文依赖关系,并分析消息数据值之间的关联来实现。我们使用从有状态和无状态服务收集的交互轨迹对该方法进行评估,结果表明在服务响应生成方面,其准确性和效率较现有方法均有显著提升。