执行顺序

参考文档 https://jmeter.apache.org/usermanual/test_plan.html#executionorder https://jmeter.apache.org/usermanual/component_reference.html#logic_controllers


  1. Configuration elements
  2. Pre-Processors
  3. Timers
  4. Sampler
  5. Post-Processors (unless SampleResult is null)
  6. Assertions (unless SampleResult is null)
  7. Listeners (unless SampleResult is null)

摘要1 Please note that Timers, Assertions, Pre- and Post-Processors are only processed if there is a sampler to which they apply. Logic Controllers and Samplers are processed in the order in which they appear in the tree. Other test elements are processed according to the scope in which they are found, and the type of test element. [Within a type, elements are processed in the order in which they appear in the tree]. 摘要2 Logic Controllers let you customize the logic that JMeter uses to decide when to send requests. Logic Controllers can change the order of requests coming from their child elements.


image.png


作用域

https://jmeter.apache.org/usermanual/test_plan.html#scoping_rules https://jmeter.apache.org/usermanual/component_reference.html

摘要3 The JMeter test tree contains elements that are both hierarchical and ordered. Some elements in the test trees are strictly hierarchical (Listeners, Config Elements, Post-Processors, Pre-Processors, Assertions, Timers), and some are primarily ordered (controllers, samplers). When you create your test plan, you will create an ordered list of sample request (via Samplers) that represent a set of steps to be executed. These requests are often organized within controllers that are also ordered.

hint:阅读理解官方说明,充分理解各组件的作用域及其影响,否则执行压测时的模型将与压测计划出现严重偏差。