zoukankan      html  css  js  c++  java
  • [原创]什么是性能测试?

    [原创]什么是性能测试?

    以下是Wikipedia中的解释:

    Performance testing
    From Wikipedia, the free encyclopedia

    Jump to: navigation, search

    http://en.wikipedia.org/wiki/Performance_testing

    Performance Testing covers a broad range of engineering or functional evaluations where a material, product, system, or person is not specified by detailed material or component specifications: rather, emphasis is on the final measurable performance characteristics.

    Performance testing can refer to the assessment of the performance of a human examinee. For example, a behind-the-wheel driving test is a performance test of whether a person is able to perform the functions of a competent driver of an automobile.

    In the computer industry, software performance testing is used to determine the speed or effectiveness of a computer, network, software program or device. This process can involve quantitative tests done in a lab, such as measuring the response time or the number of MIPS (millions of instructions per second) at which a system functions. Qualitative attributes such as reliability, scalability and interoperability may also be evaluated. Performance testing is often done in conjunction with stress testing.

    为什么要进行性能测试呢?

    性能测试的目的是验证软件系统是否能够达到用户提出的性能指标,并发现应用程序中中存在的性能瓶颈,如:如资源争用或运行速度慢的代码。然后通过性能调优,达到优化系统的目的。

    性能测试的目标是什么?

    以下是Robert W. Buchanan, Jr 的《The Art of Testing Network Systems(John Wiley & Sons, Inc., 1996) 中对此有详细描述。

    性能测试目标

    性能测试目标例子

    度量最终用户的响应时间

    完成一个业务流程需要多长时间?
    如:10用户同时登录,多长时间服务器可以返回数据!

    定义最佳硬件配置

    哪一种硬件配置可以提供最佳性能?

    检查可靠性

    系统无错误或无故障运行的难度或时间长度是多少?

    查看硬件或软件升级

    升级对性能或可靠性有何影响?

    评估新产品

    应选择哪些服务器硬件或软件?

    度量系统容量

    在性能没有显著下降的情况下,系统能够处理多大的负载?

    确定瓶颈

    什么因素导致响应时间延长?

    在实施性能测试过程中,应制定性能测试目标来。为了提供评估基准,应明确区分可接受和不可接受测试结果的标准。

    例如:

    比较模糊的性能测试目标:新产品要上线,请选择web服务器的硬件。

    明确的性能测试目标:新产品要上线,在一台 HP 服务器和一台 NEC 服务器上运行同一个300 个虚拟用户。当 300 个用户同时浏览 Web 应用程序页面时,确定哪一种硬件的响应时间更短。

     

    性能测试应贯穿于整个软件产品生命周期中,以下是与各阶段相关联的关系:

    产品计划和设计

    产品开发

    产品部署

    产品上线生

    产品升级

     
     
     

    评估新产品

    度量响应时间

    检查可靠性

    度量响应时间

    检查硬件或软件升级

     

    度量响应时间

    检查最佳硬件配置

    度量响应时间

    确定瓶颈

    度量系统容量

     

     

    检查硬件或软件升级

    度量系统容量

     

     

     

     

    检查可靠性

     

     

     

     

    如果你明确了具体的性能目标后,可以开始进行测试,确定应用程序是否满足这些要求。通常性能测试假定这些应用程序稳定、可靠地运行。因此,在性能测试中应最大限度的减少影响性能测试的条件。例如,代码中的错误可以导致出现性能问题,甚至掩盖性能问题。所以要精确地比较不同性能测试的结果,应用程序必须正确地工作。如果调整过程修改了组件的实现,则重新测试应用程序的功能尤其重要。应用程序必须通过功能性测试后才可以测试性能。除了应用程序更改外,硬件、网络通信量、软件配置、系统服务等诸多方面也会发生意外的更改。控制应用程序更改很重要。

  • 相关阅读:
    ContextLoaderListener和Spring MVC中的DispatcherServlet学习 随手记
    Linux目录详解
    9---PIP 管理工具的使用
    8. Python自定义模块humansize
    1. Hyper上的CentOS 6.5 网络配置
    Python基础学习8---list列表的操作
    Python基础学习6---存储器
    Python基础学习3---数据结构
    Python基础学习2---模块
    Python基础学习1---函数
  • 原文地址:https://www.cnblogs.com/mayingbao/p/374070.html
Copyright © 2011-2022 走看看