use of org.apache.jmeter.processor.PreProcessor in project jmeter by apache.
the class TestCompiler method saveTransactionControllerConfigs.
private void saveTransactionControllerConfigs(TransactionController tc) {
List<ConfigTestElement> configs = new ArrayList<>();
List<Controller> controllers = new ArrayList<>();
List<SampleListener> listeners = new ArrayList<>();
List<Timer> timers = new ArrayList<>();
List<Assertion> assertions = new ArrayList<>();
List<PostProcessor> posts = new ArrayList<>();
List<PreProcessor> pres = new ArrayList<>();
for (int i = stack.size(); i > 0; i--) {
addDirectParentControllers(controllers, stack.get(i - 1));
for (Object item : testTree.list(stack.subList(0, i))) {
if (item instanceof SampleListener) {
listeners.add((SampleListener) item);
}
if (item instanceof Assertion) {
assertions.add((Assertion) item);
}
}
}
SamplePackage pack = new SamplePackage(configs, listeners, timers, assertions, posts, pres, controllers);
pack.setSampler(new TransactionSampler(tc, tc.getName()));
pack.setRunningVersion(true);
transactionControllerConfigMap.put(tc, pack);
}
use of org.apache.jmeter.processor.PreProcessor in project jmeter by apache.
the class JMeterThread method runPreProcessors.
private void runPreProcessors(List<PreProcessor> preProcessors) {
for (PreProcessor ex : preProcessors) {
if (log.isDebugEnabled()) {
log.debug("Running preprocessor: {}", ((AbstractTestElement) ex).getName());
}
TestBeanHelper.prepare((TestElement) ex);
ex.process();
}
}
Aggregations