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
2
votes
1 answer

accessing file from jmeter beanshell sample using filepath

I'm trying to access one file from beanshell sampler. However it shows me error as below : Encounter "(C:"at line 9, column 2) file path name is C:/Test/test.txt. It seems i can't use C:/ drive in beanshell sampler? please let me know how can I…
goutthee
  • 329
  • 4
  • 14
2
votes
1 answer

How can I disable writing BeanShell log row in JMeter report (summary.csv file)?

I have some JMeter script with BeanShell Sampler: After run we can see BeanShell Sampler log in 'summary.csv': How can I disable writing of BeanShell Sampler log into 'summary.csv'?
Misha Mikus
  • 163
  • 1
  • 13
2
votes
2 answers

JMeter Script Path missing "\" so not working?

I am trying to use the beanshell script posted here to get the path of the jmx that is being run in my jmeter test - Access to JMeter script path It is working and if I log the output of the path when set by beanshell or view the variables with the…
Karl
  • 599
  • 7
  • 27
2
votes
3 answers

How to add rendezvous point in jmeter

I have a scenario in which I want to hit first request with 3000 users and wait for all the users to come at a point and hit the second request at a same time. How can this be achievable in jmeter.
Nikhil
  • 393
  • 1
  • 6
  • 25
2
votes
2 answers

In Hybris , How we can import product from database and store the product attribute value in csv file using Beanshell

I want to import product with attribute value Price , description and store in csv file using Beanshell script .
2
votes
2 answers

JMeter Beanshell Integer Error

i have problem with Integer in JMeter Beanshell Sampler/Pre/Post processor. I have some array of values, and i want to use each value of this array to set JMeterProperty for next use. GOAL> have some N rows from query. For Example UPSTREAM column…
2
votes
1 answer

Jmeter: Is it possible to run a particular thread group after all the other thread group gets completed

In JMeter, I have a requirement where I want to run a particular thread group after all the other thread groups complete their run, I know the tearDown thread group has the similar behavior but unfortunately, the logic has to be part of my regular…
2
votes
2 answers

Jmeter: How to control a http sampler request in a thread group to run only once among 100 threads

I've a thread group to run for 100+ users with-in that there is a need to execute a particular http request only once for all the threads. I know the "Once only Controller" but it execute the child samplers once per thread that is why it doesn't…
S Thakur
  • 45
  • 1
  • 7
2
votes
1 answer

regular expression extractor template values in beanshell post processor

I have extracted valeus from response using regular expression extractor and defined template as $1$,$2$, i now want to use those values in beanshell post processor. How do i do that. I am unable to fetch those valeus in my beanshell editor. How…
Yuvraj
  • 79
  • 1
  • 2
  • 10
2
votes
1 answer

How to let XPathExtractor extract xml element only if Http response code is 200?

In my JMeter test plan, I have a HttpRequest, I want to extract the link from its response only if the response code is 200. I can add an XPathExtractor post processor under HttpRequest and it works. But I want to have an IfCondition first so that…
user1532146
  • 184
  • 2
  • 14
2
votes
1 answer

Next line from csv file in Jmeter beanshell script

I'm trying to make a BeanShell script within JMeter to create an XML message and save it as a variable (and then have a SOAP sampler send the message of course, but that's not really the point). Within the script, I have a loop that randomly creates…
2
votes
3 answers

Using Ivy to download/install ant-contrib, bsf, beanshell, commons-logging

I am building a project using Ant and Ivy. The build.xml file depends on ant-contrib, bean scripting framework, beanshell, and commons-logging. Ant searches for libraries in several places, including ${user.home}/.ant/lib. Is there any way in the…
Ralph
  • 31,584
  • 38
  • 145
  • 282
2
votes
1 answer

Jmeter - Accessing Regex Array Variables In Beanshell

I have problems picking up variables set by the Regular Expression Extractor in a Beanshell. I have an HTTP Request sampler which returns a list of 50 numbers in random form (4, 2, 1, 3....50, 45) which I have extracted via regEx. Now I want to get…
2
votes
1 answer

BeanShell error message in android studio

I am a beginner in java , I was making a simple calculator app in Android Studio using Beanshell . When I run the project , It works fine only on my emulator . For real devices , this app can be installed only . When I try to run , the app crashes…
000
  • 405
  • 5
  • 20
2
votes
2 answers

Dynamically change JDBC config in Jmeter

I need to make sure,whether table has data or not ,based on the environment,say for example i have two two database,one is development another one is production like given below. Production host1 dbuser1 dbpassword1 dburl Tablename :…
Vasanth
  • 474
  • 2
  • 9
  • 31