实时软件开发技术的研究与实现
详细信息    本馆镜像全文|  推荐本文 |  |   获取CNKI官网全文
摘要
随着实时系统应用领域的不断扩大,系统的复杂度也越来越大,导致软件的规模也越来越大了,这就对实时软件开发的工程化方向提出了新的要求。
     在实时计算中,系统的正确性不仅仅依赖于计算的逻辑结果而且依赖于结果产生的时间。这决定了实时系统中需要处理的问题会比通用系统中更多,也更需要系统有更高的能力去满足要求。
     针对实时系统设计中出现的问题,本文全面分析并系统地阐述了多种实时系统的性能评价方法、工作原理和设计方法。在系统的分析设计过程中,把当前和软件工程结合的UML方法引入到实时系统的分析和设计中,希望能给我们现在的实时系统设计带来点新的设计思想。
     首先,本文从实时系统的性能评价方法入手,介绍了实时系统设计中自上而下的一种分析方法,使得设计人员可以更好的在软件和硬件间做到平衡。
     然后指出了实时系统设计中,需要注意的一些重要问题,并提出了相应的设计方法,包括任务的分配和调度方法,实时通讯技术和容错技术。并讨论了一个实时程序设计语言及其工具应该所有的特征。
     进一步,为了让实时软件的开发更好的符合软件工程的思想,提出了实时系统用UML进行系统设计和建模的方法和过程,并用UML描述了关口表计费采集系统的需求、分析和设计。在系统中,为了增加Socket连接请求的有效性和数据存储的瓶颈问题,在数据库服务器中使用了Socket连接池和数据库连结池,以减少这两个问题对系统造成的影响。为了保持系统的高可靠性,在整个系统中使用了守护狗模式,对通讯服务器使用了主备保护模式,并对数据库服务器进行了集群。对数据库服务器进行集群带来的另一个好处是,解决了数据库服务器的负载均衡问题。通讯服务器还支持数据的磁盘备份,以允许数据传输的延迟服务,来消除数据库服务器端Socket请求数的瞬间过载对数据传输服务造成的影响。
     在文章的最后,总结了本次研究工作的缺点和不足,提出了日后需要改进和完善的地方。
The complex of system becomes increased when the application area of real-time system expands, thus the scale of the software becomes larger and larger. So it brings new requirement in software development in real-time system.
    The correct of the system depends on not only the logic result computed but also the time the computation spent. Thus it needs to handle more issues and hold more sufficient ability in real-time system than in general system.
    It expatiates working principle in real-time system and a number of ways to evaluate performance, to design the system. It brings the development method of UML which is combined with software engineering, and hopes that it will bring a new design idea to the way in designing real-time system.
    This article begins to discuss the performance evaluation in real-time system to tell us a method to analysis of real-time system in top-down, and thus we can make a balance between software and hardware.
    Then it presents some important issues we should be noticed, and makes the corresponding methods to design including task assignment and scheduling, real-time communication and fault-tolerance techniques, and discuss the characteristic that a real-time language and tools should hold.
    And, it presents the way in designing and modeling system with UML in real-time for that it can meet the concept of software engineering better. It also describes the requirement, analysis and design of Meter-fee collection System with UML. Socket connect-pool and database connect-pool are used in the system for increasing the validity of socket connection-request and the speed of data storage. And there are the watch-dog pattern used in the system, the master-salve pattern used in the communication servers and the cluster used in the database servers for the high reliability to the system. The cluster technology also is a solution for load-equilibrium for all the database servers. Support disk-store for data when the instant overload of socket-request happened and the data-transit service can be delayed.
    The defect in the research and work are summarized lastly, and presents the improvement which can be done in the future.
引文
[1] C.M.Krishna, and Kang G..Shin: Real-time Systems, The McGraw-Hill Companies,Inc. 1997
    [2] C.Y.Park, and A.Shaw: "Experiments with a Program Timing Tool Based on Source-Level Timing Schema," IEEE Computer, Vol.24, No.5, May 1991
    [3] 王志平、熊光泽:“实时调度算法研究,”电子科技大学学报,第29卷,第2期,2000年4月
    [4] 刘怀、胡继峰:“实时系统的多任务调度,”计算机工程,第28卷,第3期,Vol.28,No3
    [5] 王芸、谢俊清、沈卓炜、顾冠群:“实时CORBA技术综述,”东南法学学报(自然科学版),第32卷,第3期,2002年5月
    [6] N. C. Audsley, A. Burns, M. F. Richardson, and A. J. Wellings. "Hard Real-Time Scheduling: The Deadline Monotonic Approach," Proceedings of the 8th IEEE Workshop on Real-Time Operating Systems, pages 133-137, 1991.
    [7] Audsley, N.C. (1990). Deadline Monotonic Scheduling. YCS 146, Dept. of Comp.Sci., Univ. of York.
    [8] Lehoczky, J.P., L. Sha, and Y. Ding. (1989). TheRate-Monotonic Scheduling Algorithm:Exact Characterization and Average Case Behaviour. Proc IEEE Real-Time Sys.Symp., pp. 166-171.
    [9] Leung, J.Y.T., and J. Whitehead. (1982). On the Complexity of Fixed-Priority Schedulingof Periodic, Real-Time Tasks. Perf.Eval.(Netherlands), 2, pp. 237-250.
    [10] Baruah.S.K., A.K.Mok, and L.E.Rosier: "Preemptively Scheduling Hard-Real-Time Sporadic Tasks on One Processor," Proc.IEEE Real-Time Systems Symp., pp. 182-190, IEEE, Los Alamitos, CA, 1990
    [11] Liu, C.L. and J.W. Layland. (1973). Scheduling Algorithms for Multiprogramming in a Hard Real-Time Environment, J. ACM, 20, pp.40-61.
    [12] Lehoczky, J.P.: "Fixed Priority Scheduling of Perodic Task Sets with Arbitrary Deadlines," Proc, IEEE Real-Time Systems Syrup., pp.201-210, IEEE, Los Alamitos, CA, 1990
    [13] Gay, F.A., and M.L.Ketelson: "Performance Evaluation for Gracefully Degrading Systems," Proc. 7th IEEE int'l Syrup. on Fault-Tolerant Computing, pp.51-58, IEEE, Los Alamitos, CA, 1979.
    [14] Shin,K.G., C.M.Krishna: "New Performance Measures for Design and Analysis of Real-Time Multiprocessors," Journal of Computer Science and Engineering Systems 1:179-192, 1986
    [15] 刘钰峰,李仁发,莫铁强和孙婷:“实时操作系统仿真环境的UML建模,”系统仿真学报,第14卷,第6期,2002年6月
    [16] Alan A. Bertossi, Andrea Fusiello, Luigi Vincenzo Maneini:" Fault-Tolerant Deadline-Monotonic Algorithm for Scheduling Hard-Real-Time Tasks," 11th International Parallel Processing Symposium (IPPS'97), April 01-05, 1997 Geneva,
    
    SWITZERLAND
    [17] Zhang Zhanjun Yang Xueliang Han Chengde: "Key Issues of Resource Management in Distributed Multimedia Computer Systems"
    [18] James Rumbaugh, Ivar Jacobson, and Grady Booch: The Unified Modeling Language Refrence Manual
    [19] 蒋慧,吴礼发和陈卫卫:“时代新潮流UML Programming Guide设计核心技术,”北京希望电子出版社,2001年1月
    [20] Bruce Powel Douglass: "Designing Real-Time Systems with UML-Part Ⅰ," http://www.embedded.com
    [21] Bruce Powel Douglass: "Designing Real-Time Systems with UML-Part Ⅲ," http://www.embedded.com
    [22] Bruce Powel Douglass: "Designing Real-Time Systems with UML-Part Ⅲ," http://www.embedded.com
    [23] 于潇洋:“Linux集群技术,”http://www. huihoo. com
    [24] 杜成章:“典型容错设计及比较,”信息产业部电子第28研究所,http://www.ccw.com.cn
    [25] 张宇飞、卢燕青:“实时系统软件分析和设计方法综述,”2000年07月28日 http://www.ccidnet.com
    [26] Kwei-Jay Lin: "Scheduling and System Issues on Real-Time Computing (Part Ⅱ)," Department of Electrical & Computer Engineering University of California Irvine, CA 92697
    [27] Grow, R.M.: "A Timed-Token Protocol for Local Area Networks," Electro '82: Token Access Protocols, Paper 17/3, 1983
    [28] Ulm,J.N.: "A Timed Token Ring Local Area Network and its Performance Characteristics," Proc. 7th Conference on Local Computer Networks, pp.50-56, IEEE, Piscataway, NJ, 1982
    [29] Avizienis,A., and J.P.J.Kelly: "Fault-Tolerance by Design Diversity," IEEE Computer 17:67-80, 1984
    [30] UML Notation Guide Version 1.1, September, 1997. Rational Corp, et. al. As submitted to the OMG.
    [31] UML Semantics Version 1.1, September, 1997. Rational Corp, et. al. As submitted to the OMG.