Questions tagged [beanshell]

Lightweight scripting for Java

From the official site:

BeanShell is a small, free, embeddable Java source interpreter with object scripting language features, written in Java. BeanShell dynamically executes standard Java syntax and extends it with common scripting conveniences such as loose types, commands, and method closures like those in Perl and JavaScript

943 questions
3
votes
1 answer

How to use multiple proxy with JMeter

I have a load balancer and I want to test the performance of the load balancer. I am using Apache JMeter to test the load balancer. I need to change my IP address so that the client IP is always different. My uni doesn't allow me to add multiple IP…
Jose
  • 155
  • 2
  • 8
3
votes
1 answer

Use POJOs in JMeter BeanShell or JSR233

I have built a Java Class and exported it as JAR. I have imported it successfully in JMeter ($JMETER_HOME/lib) and I can successfully import it in a Beanshell Sampler and also in a JSR233 Sampler. I have followed several instructions like Running…
Javier Delgado
  • 2,343
  • 2
  • 17
  • 31
3
votes
3 answers

Jmeter beanshell classnotfounderror

I am trying to use beanshell on jmeter (last version), but everytime I add a beanshell processor (pre, pro or whatever), I got this error ERROR - jmeter.util.BeanShellTestElement: Cannot find BeanShell: java.lang.ClassNotFoundException:…
Danko
  • 41
  • 4
3
votes
2 answers

How to read XML file in JMeter?

I have tried: //${__FileToString(C:\\QC\\qa\\Testlink\\Jmeter\\Expected\\test.xml,ASCII,${xmlFile})}; Found error message : org.apache.jorphan.util.JMeterException: Error invoking bsh method: eval In file: inline evaluation of: ``//
Akshay Garg
  • 33
  • 1
  • 1
  • 3
3
votes
3 answers

How can I get name of HTTP Request from field Name with BeanShell?

I Need to get to variable field from http request which is called Name. If anyone could give my examples how can I get other fields such as : Path, Server name or IP using beanshell? Thank you in advance
Kac
  • 184
  • 3
  • 15
3
votes
2 answers

JMeter go back to previous sampler

I am quite new to jmeter, I am using it to load test an application. My current setup is good if running few threads at a time but gets problems when more users get connected. Here's the scenario, sample_1: request table data sample_2: set table…
Dominick Navarro
  • 752
  • 6
  • 20
3
votes
5 answers

Jmeter setting for sampler that it should not be in view results tree

I want that some beanshell samplers of my testplan should not be shown in view results tree. Is that somehow possible? Best regards, Peter
Peter
  • 1,011
  • 2
  • 16
  • 39
3
votes
2 answers

How to pass data to BeanShell sampler using BeanShell preprocessor using JMeter?

I need to read file once and its result to be processed further in sampler. My strategy is ThreadGroup--> BeanShell Preprocessor + BeanShell Sampler My preprocessor should read file once for whole Thread Group and result to be used in Sampler for…
usman
  • 1,351
  • 5
  • 23
  • 47
3
votes
1 answer

How to stop Jmeter test after specified number of threads failed

I have one Transaction controller which has one http request in my Jmeter test plan. Transaction name and url comes from CSV file. At the end total execution is divided into 5 different transactions. Testplan: Testplan -Thread Group - User…
user1169236
  • 159
  • 1
  • 2
  • 13
3
votes
3 answers

Groovy script in JMETER

I was trying to add groovy (Groovy 2.4.3) to the JMeter 2.13. I am placing all the %groovy_home%/lib/.jars in %java_home%/lib/ext/groovy-lib/.jar I added the classpath in jmeter.property file (search_paths=/lib/ext/groovy-lib) The problem is after…
Suhas Deshpande
  • 183
  • 2
  • 3
  • 15
3
votes
1 answer

JMeter - Using Variables from other BeanShell Pre/Post-Processors?

Is there a way to reference a variable from one BeanShell Pre/Post-Processor to another BeanShell Processor (they are within the same Thread Group)? If I create a String variable inside a BeanShell PreProcessor under an HTTP Request, can I then use…
Matt
  • 413
  • 1
  • 10
  • 16
3
votes
1 answer

Bean shell script in testng

i want to select multiple methods based on the name of the methods using bean shell script in testNG.xml.This is my current testng.xml
3
votes
1 answer

Beanshell equivalent for .Net

Is there anything like Beanshell, which exposes CLR classes instead of Java classes, and lets you write scripts in C# or VB.Net (or any .Net language for that matter) Should come in handy to test one-liner code snippets
Midhat
  • 17,454
  • 22
  • 87
  • 114
3
votes
2 answers

"Object constructor" Beanshell error in JMeter

I am running a JMeter test and hoping to read in some values from a CSV (due to other reasons, I cannot use the CSV Data Set Config which I normally use to read CSVs. This is due to the order in which CSVs are loaded/read within the test). …
krodmannix
  • 845
  • 10
  • 30
3
votes
2 answers

jmeter stop current iteration

I am facing the following problem: I have multiple HTTP Requests in my testplan. I want every request to be repeated 4 times if they fail. I realized that with a BeanShell Assertion, and its already working fine. My problem is, that I don't want…
Drujust
  • 33
  • 1
  • 3