I am creating recordings for a company website for performance tests. Normally this works fine though on occasion when starting a new test recording, HTTP Test Script Recorder will not record anything but returns the following error in the browser:
I have been using jmeter for a while now so I know the setup for HTTP Test Script Recorder is ok.
Clearing browser history, running in public or private mode doesn't help. Re-issuing jmeter proxy cert makes no difference either, the same for deleting proxyserver.jks.
Having experienced this before, I know that after a few days HTTP Test Script Recorder will start working again.
Happens for both jmeter v4 & v5.
I can think only of one situation when it can happen:
You have a JMeter test running in background (or a thread which failed to stop for some reason)
You're trying to record something at the same time
So
Make sure that nothing is running at the moment (you should see 0/0 in upper right corner of JMeter GUI)
Start clean recording session, to wit restart JMeter and create the test plan using Recording Template feature (From main menu choose File -> Templates -> Recording and click "Create"
Just in case be aware that you can also record your mobile application traffic using cloud-based proxy service, as a bonus you will get possibility to export recorded scripts in SmartJMX mode with automated detection and correlation of the dynamic parameters. Check out How to Cut Your JMeter Scripting Time by 80% article for more details if interested.
The issue you see is most probably a bug probably introduced by:
https://bz.apache.org/bugzilla/show_bug.cgi?id=57962
During recording, JMeter variables are null so we end up using an Unmodifiable version of them because of this:
https://github.com/apache/jmeter/blob/trunk/src/core/org/apache/jmeter/threads/JMeterContext.java#L88
I suggest you open a bug here, providing as much information as possible:
https://jmeter.apache.org/issues.html
Provide:
How you reproduce it
The jmeter.log with the stacktrace (not as an image)
The workaround is to avoid running a test and recording after that.
Edit on 3 december 2018:
You reported a bug:
https://bz.apache.org/bugzilla/show_bug.cgi?id=62916
The reproducer is:
Start a distributed test where Controller is in GUI mode and a jmeter-server
Once test is finished, start a Recording using HTTP(S) Test Script Recorder
Hit a URL, you'll get the issue
The bug has been fixed today, it will be available in JMeter 5.1 and is already available in:
https://ci.apache.org/projects/jmeter/nightlies/
Related
I am new to jmeter. Creating a simple script seems easy via browser actions recording. Can that be done without launching the jmeter IDE?
As per latest stable JMeter version 5.4.1 it's not possible to start HTTP(S) Test Script Recorder without starting JMeter GUI
If you cannot do this for any reason the options are in:
Use JMeter Chrome Extension
Use your browser developer tools to record your test request into a .HAR file, once done you can:
either use online conversion tool to convert .har file into a JMeter script
or manually create JMeter's HTTP Request samplers by looking into requests details in the browser developer tools. If you cannot launch JMeter GUI at this stage as well you can consider using Taurus automation framework which allows creation of JMeter test plans using YAML syntax
You need to start the JMeter proxy for recording the test and it is not possible to start the proxy through available options.
There is a number of ways available for building test plans including the HTTP(S) Test Script Recorder.
Ten different ways to build JMeter Test Plans
The recording feature can be used even for complex scripts. You will have to use/add JMeter components and configure them once the recording is done to achieve the desired user actions.
I am facing this problem, and I suspect it is security related.
I am using Jmeter corelation recorder to record my scripts for testing,
I tried recording a search transaction in my application which is a document management system and as soon as I search(after Login) , it throws an error, while when I run the functionality manually it runs well.
Should I try forcing Jmeter to use my local proxy for recording or even playback(I have developed the script with Blazemeter extension as the Jmeter proxy recording was not working) ? The script however fails to playback the search transaction, server returns a 500 error.
I also see that Blazemeter extension has no problem recording the search transaction, which makes me suspect, that probably a security certificate is missing when I try recording via Jmeter proxy.
Correlation recorder doesn't do any magic when it comes to identifying dynamic elements and coming up with proper regular expressions to handle them, you still need to do it manually prior to starting recording.
With regards to JMeter recording failing: yes, you need to import the JMeter's certificate into the browser, this way JMeter will be able to intercept and decrypt HTTPS traffic, see HTTPS recording and certificates chapter of JMeter's documentation on HTTP(S) Test Script Recorder for more details.
If you add View Results Tree listener and see the responses, most probably your login fails somewhere somehow hence search fails due to your virtual user fails to login.
So make sure that
JMeter sends the same network requests as the browser does
all dynamic values are correlated
HTTP Cookie Manager is added to your test plan
given all above criteria are implemented you shouldn't experience any problems.
There is a 3rd-party solution: BlazeMeter Proxy Recorder which seems to be capable of automatically detecting and correlating dynamic parameters, if you're new to this concept - even if it won't resolve your problem fully at least it will give you some clue.
I am now trying to use Apache JMeter HTTP(S) Test Script Recorder, but I have a difficult problem!
I've done the following Settings in JMeter .
enter image description here
And I configured the proxy in firefox.
Then I recorded a simple script.
But when I replayed the script, it didn't work, and I got the following tips:
enter image description here
What should I do? Please give me some advice!Thanks!
I don't fully understand two things:
Why you are asking Badboy-related question in JMeter forum?
How it can be convenient to use 2 separate tools while JMeter has its own HTTP(S) Test Script Recorder?
So please retry recording using JMeter's Proxy Server and if the issue persists - come back here so we could take a look into the issue.
There is one more alternative solution for JMeter tests recording which used to work under any conditions: JMeter Chrome Extension, you can consider it as a fallback solution.
No one will ever read this or benefit from it, but just in case....
Right click your test plan and select Add > Listener > View Results Tree.
Re-run your script and read what's in the results tree.
While recording a workflow through JMeter proxy, I am not able to click some items(like buttons), which otherwise are available when the website is getting loaded without JMeter proxy.
Now, needless to say, i have to click those buttons to perform certain activities essential as a part of the workflow whose performance I want to measure.
I am quite new to JMeter, so not sure how to proceed with the problem. Is there any Proxy settings i should change?
When I am checking the website source there is no difference between the page getting loaded via proxy and the page without it.
Please let me know if additional info is required. Thanks in advance!!!
Check jmeter.log file (usually lives in JMeter's "bin" folder or folder, you launched JMeter from if it's different) for anything suspicious. Log file should be the first place to look into as JMeter basically writes anything there.
You can increase verbosity if required by adding the next line to user.properties file (again lives in "bin" folder of your JMeter installation)
log_level.jmeter.protocol.http.proxy=DEBUG
Try cleaning your browser history, it's better to delete everything, especially cache.
Try re-installing JMeter certificate. See Installing the JMeter CA certificate for HTTPS recording chapter of the HTTP(S) Test Script Recorder (was: HTTP Proxy Server ) for instructions
If above steps won't help and you're absolutely sure you're doing everything right you can try raising a JMeter issue
Also be aware of JMeter Chrome Extension which is an alternative way of recording a JMeter test which doesn't require proxy server.
I am currently using the jar of my selenium test suite to integrate with JMeter but, the problem which I am facing is that JMeter is opening the Firefox session equals to the number of threads which I specify because of that, my system gets unresponsive.
Does any one knows how to suppress multiple browser session to open on system without affecting the load testing?
It is normal each thread open his own browser... Maybe you can use phantomJS driver but ut will use memory too... Maybe not use this way and use recording controller to record scenario an play it directly with jmeter that is the stress test way the other not test the performance... You can use chrome headless too but cost memory too.. Another solution start new thread only when first thread us finish... I think with versiin 45 of firefox (only version working with jmeter) and jmeter 3.3 firefox not possible headless... Google an phantomJS yes possible.
The best solution use recorder controller.. Record a case and play it... Jmeter will use internal browser "system" low cost to achieve it dont forget that jmeter is stress test tool... You can use to do other action but not efficiently...