I am trying to use multiple certificates(.p12) in multiple thread groups. The following is the set up,
ThreadGroup1
HTTPRequest1
CSVdataconfig - cert_alias1.csv
Keystoreconfig - cert1 alias name
ThreadGroup2
HTTPRequest2
CSVdataconfig - cert_alias2.csv
Keystoreconfig - cert2 alias name
ThreadGroup3
HTTPRequest3
CSVdataconfig - cert_alias3.csv
Keystoreconfig - cert3 alias name
Have combined all three (.p12) certificates into one keystore(.jks) file using Keystore tool .
If 'Run Thread Groups consecutively'(in Test Plan) is checked , the script works fine.
If 'Run Thread Groups consecutively'(in Test Plan) is unchecked , HTTP requests fail intermittently.
PS: I am importing .jks file into SSL Manager prior to test run and providing password on the prompt. Also used keystore parameters in system.properties file.
Related
I am trying to invoke Jmeter script with user defined properties with YAML which I am able to change and execute with below configuration.
However if the test started and I need to increase the user on any thread - without stopping the test, how can I achieve that? Let's say the test was started with Thread1 value as 30 and now if I need to change it to 50 dynamically on runtime. I did not find a way myself. Please advise.
execution:
- #concurrency: ${__P(my_conc,3)} # use `my_conc` prop or default=3 if property isn't found
ramp-up: 1
hold-for: ${__P(my_hold,1)}
scenario: simple
modules:
jmeter:
properties:
my_hold: 60
scenarios:
simple:
variables:
#User DEFINED variable
Sampler1 : TestSampler1
Sampler2 : TestSampler2
script: SampleYAMLJMeter.jmx
properties:
#Thread Level variable
thread1 : 30
thread2 : 45
Add the following global JMeter properties:
modules:
jmeter:
properties:
beanshell.server.port: 9000
beanshell.server.file: ../extras/startup.bsh
Create the setconc.bsh file under .bzt/jmeter-taurus/x.x.x/lib folder and put the following code into it:
org.apache.jmeter.util.JMeterUtils.setProperty("my_conc", args[0]);
That's it, whenever you need to change the concurrency of your tests just execute the following command from the .bzt/jmeter-taurus/x.x.x/lib folder:
java -jar bshclient.jar localhost 9000 setconc.bsh 1234
replace 1234 with the actual concurrency you want to achieve
More information:
Beanshell server
How to Change JMeter´s Load During Runtime
I have following requirements to execute the performance test via Taurus.
Requirements:
1. A single jmx on multiple(distributed) jmeters
2. For every Jmeter an unique IP address to be passed at run time
3. For every Jmeter a set of unique .csv path has to be provided in .yml(as data source)
4. All Jmeters should run in parallel and report should be combined of all.
Tried with following, but unable to achieve. Let me know or share the sample .yml if any one done such kind of scenario.
execution:
- scenario:
# scenario1:
script: varTest.jmx
distributed:
- localhost:1099
variables:
host: "10"
- scenario:
# scenario2:
script: varTest.jmx
distributed:
- localhost:2010
variables:
host: "20"
In this,need to override hosts dynamically with option -o.
It doesn't contain csv datasource details, pls share the how to create a .yml for such requirement.
Thanks..
You could try something like:
---
execution:
- distributed:
- localhost:1099
scenario:
script: varTest.jmx
distributed:
variables:
host: "10"
- distributed:
- localhost:2010
scenario:
script: varTest.jmx
variables:
host: "20"
References:
Run JMeter in Distributed Mode
Running Taurus in Command Line
Taurus - Working with Multiple JMeter Tests
I am using drive_service.files().patch() method of the google python client library to update the parent folder for a particular file.
This file is a copy created with drive_service.files().copy() method, copying a base template google slide, and its permissions are updated to be accessible by anyone having the link to the file.
I am using a Service Account credentials for oauth2 authentication
Example -
Dest Folder - A
Original File - f1
Copied File - f2
Steps
1. Use - drive_service.files().copy() for copying File.
2. Use - drive_service.permissions().insert() - for adding permission -> type - "anyone", role - "writer"
3. Use - drive_service.files().patch({addParents: folderId}) - for adding parent folder
Steps 1 & 2 are executed successfully. Step 3 throws the following error -
403 - "Insufficient permissions for this file"
The same request executed by the Google API explorer tool succeeds in creating a copy.
Sample Link to the file I am trying to update the parents of, whose permission is set to be accessible by anyone
Is this a known issue? Is there any difference in requests being authenticated via Service Account credentials versus the Google user.
I placed plugin manager in "lib\ext" folder and tried to open it showed error:
java.io.IOException: Repository responded with wrong status code: 407
Jmeter version - 3.3
Plugin version - 0.16
Jmeter is invoked from command line by using the following parameters:
C:\Users\princen\Performance Testing\Software\apache-jmeter-3.3\bin\jmeter.bat -H Proxyserver -P 1234 -u princen -a ***
Parameters modified as suggested here
JVM_ARGS="-Dhttps.proxyHost=Proxyserver -Dhttps.proxyPort=1234 -Dhttp.proxyUser=princen -Dhttp.proxyPass=***" C:\Users\princen\Performance Testing\Software\apache-jmeter-3.3\bin\jmeter.bat
Above try gives the following error message
Windows cannot find "JVM_ARGS="-Dhttps.proxyHost=Proxyserver -Dhttps.proxyPort=1234 -Dhttp.proxyUser=princen -Dhttp.proxyPass=***
When I tried to changes command to the following:
C:\Users\princen\Performance Testing\Software\apache-jmeter-3.3\bin\jmeter.bat -Dhttps.proxyHost=Proxyserver -Dhttps.proxyPort=1234 -Dhttp.proxyUser=princen -Dhttp.proxyPass=***
I received an error:
java.io.IOException: Repository responded with wrong status code: 407
Can someone please correct parameters required to load the plugin manager?
Ensure you use last version of jmeter-plugins download manager.
Regarding your parameters, you're mixing different configurations, just set (for both http and https):
JVM_ARGS="-Dhttps.proxyHost=myproxy.com -Dhttps.proxyPort=8080 -Dhttps.proxyUser=john -Dhttps.proxyPass=password -Dhttp.proxyHost=myproxy.com -Dhttp.proxyPort=8080 -Dhttp.proxyUser=john -Dhttp.proxyPass=password"
Where password is your real password.
None of above methods working for me. Its really tough to work with Java(due to Loadrunner background). I added Ultimate thread alone and its working fine.
Thank you all for your inputs..
JMeter is using the official proxy configuration from Oracle (like here: https://memorynotfound.com/configure-http-proxy-settings-java/)
The problem is that the jmeter documentation is wrong about the password parameter: it should be http.proxyPassword not http.proxyPass.
Also you must use the https. properties for secured urls you want to access using the proxy. And the http. properties for non secured.
When running a test which makes use of the of the Jmeter-Plugins listener Response Times vs Threads or Active Threads Over Time remote running of the test plan produces a results file which contains missing results used to plot the actual graph, however when run locally all results are returned. E.g. when using the Response Times vs Threads:
Example of a local result:
1383659591841,59,Example 1,200,OK,Example 1 1-579,text,true,183,22,22,59
Example of a remote result:
1383659859149,43,Example 1,200,OK,Example 1 1-575,text,true,183,43
Note the last two fields are missing
I would check the script definition of the two server: maybe some configuration for the "Write results to file" controller has been changed.
Take the local jmx service and copy it to the remote server.
Also, look for differences in the "# Results file configuration" section of jmeter.properties file.
Make sure that on all of the slave/remote servers the jmeter.properties file within $JMETER_HOME/bin has the following setting
jmeter.save.saveservice.thread_counts=true
By default this is set to false (and commented out)
For more informtation:
JMeter Plugins Installation