网格服务容器是服务网格中的基础模块,负责屏蔽资源的异构性并和网格服务的运行提供支持,大多数网格服务容器均采用基于线程的并发机制来处理用户请求,在性能和可伸缩性上都存在局限,采用分级事件驱动架构SEDA (Staged Event Driven Architecture),通过划分阶段Stage的方式解除耦合,在阶段之间采用事件进行异步消息通信,结合非阻塞的I/O机制设计实现了一个事件驱动的网格服务容器,并从吞吐量、平均响应时间等方面和基于线程的服务容器进行了比较,结果表明事件驱动架构的确能在性能和可伸缩性方面带来效益,异步通信方式有效的减少了系统中的同步阻塞,带来更好的并发性。
The grid service container is a fundamental component in a service grid, which is responsible for shielding resource heterogeneity and hosting grid application services. Most current grid service container implementations adopt thread-based concurrency approach to process concurrent user requests, which has limitations in terms of performance and scalability. An event-driven architecture called SEDA ( staged event driven architecture) was adopted to improve the performance of concurrent processing and scalability. It results in decoupling architecture with demarcation stages between which events asynchronous communicate and in which the non-blocking I/O mechanism can be adopted naturally. The early implementation experience and some optimistic performance evaluation results were presented, which show that the event-driven architecture can indeed raise the performance like throughput and latency and get better scalability by the asynchronous message mechanism and the reduction of the system synchronous obstruction.