zoukankan      html  css  js  c++  java
  • Jmeter-Threads(Users)

    setUp Thread Group---测试开始前的准备操作,每次测试前都会执行

    A special type of ThreadGroup that can be utilized to perform Pre-Test Actions. The behavior of these threads is exactly like a normal Thread Group element. The difference is that these type of threads execute before the test proceeds to the executing of regular Thread Groups.

    意思:和Tread Group类似,不同的是测试开始前才执行

    (比线程组少 ‘Delay Thread creation until needed’,其他一样)

    tearDown Thread Group---测试结束后的收尾操作,每次测试后都会执行

    A special type of ThreadGroup that can be utilized to perform Post-Test Actions. The behavior of these threads is exactly like a normal Thread Group element. The difference is that these type of threads execute after the test has finished executing its regular Thread Groups.

    意思:和Tread Group类似,不同的是测试完成后才执行

    PS:Teardowm Tread Group,默认情况下测试完美的结束不会运行,如果需要运行需要在Test Plan(测试计划)底部勾选Run tearDown Tread Groups after shutdown of main thraeds(运行teardown thread group在主线程之后);但是如果测试计划被停止了teardown thread group是不会被运行的。

    (比线程组少 ‘Delay Thread creation until needed’,其他一样)

    线程组

    ----------------------------------------------------------------------------------------------------

    名称:

    注释:

    在取样器错误后要执行的动作-------------------------------------------------------------

    继续:

    Start Next Tread Loop:

    停止线程:

    停止测试:

    Stop Test Now:

    线程属性----------------------------------------------------------------------------------------

    线程数:要启动的线程个数

    Ramp-Up Period(in seconds):每个线程启动的间隔时间,单位为秒

    循环次数:线程执行几次                  永远:勾选后循环不结束,不断的执行

    Delay Thread creation until needed:延迟线程启动,直到需要线程时才会创建线程;可以减少资源浪费

    调度器:勾选后调度器配置才会生效

    调度器配置-------------------------------------------------------------------------------------

    持续时间(秒):线程组运行的时间

    启动延迟(秒):线程组延迟多少秒后启动

    启动时间:启动时间

    结束时间:结束时间,会被持续时间覆盖,即持续时间没耗尽不会结束

    PS:线程属性的循环次数、永远和调度器配置的持续时间和结束时间冲突,两者满足一个条件就会把线程停止。但是JMeter不会中断等待响应的Samplers(取样器),所有结束时间可以会被延迟

  • 相关阅读:
    "Automation 服务器不能创建对象" 的解决方法
    让DataGrid拥有单击回传事件并带回指定字段的值
    SQL 和TSQL学习(一)
    数据写入XML
    DATALIST分页存储过程
    The target assembly contains no service types. You may need to adjust the Code Access Security policy of this assembly." 目标程序集不包含服务类型。可能需要调整此程序集的代码访问
    字符串转日期
    C# 日期和时间正则表达式
    js根据输入日期显示该月的最后一天的日期[转]
    JavaScript试题【解析+答案】
  • 原文地址:https://www.cnblogs.com/yanzhe/p/7723549.html
Copyright © 2011-2022 走看看