Jmeter - error message "500/unexpected alert open" - jmeter

I can't close an alert with Jmeter on my website.
Jmeter return me the following message : "500/unexpected alert open".
I tried a lot of methods and I investigated a lot on internet, but I haven't found a solution :(
please, help...

JMeter is not a browser, as such it doesn't interpret client javascript as Selenium does it.
So you need to understand what Javascript does in terms of request(s) going to server and reproduce this with HTTP Request

Finally I have found a solution to my problem with the following command :
WDS.browser.executeScript('window.onbeforeunload = null;')

Related

What does "ERR_HTTP2_PING_FAILED" mean in Chrome error code?

That error message logged to the chrome console from a long-pending request after around 15 minutes.
It looks client-side error because server processing still worked.
I did not find any article related to this error message.
can any buddy let me know how to solve this issue?
According to the chromium source I think it means that a spdy ping timed out.
...
{net::ERR_EMPTY_RESPONSE, "http.response.empty"},
{net::ERR_HTTP2_PING_FAILED, "spdy.ping_failed"},
{net::ERR_HTTP2_PROTOCOL_ERROR, "spdy.protocol"},
...
Source https://chromium.googlesource.com/chromium/src/+/lkgr/components/domain_reliability/util.cc#48
Chrome sends such pings before and after a request.
Source https://groups.google.com/d/msg/spdy-dev/HFjAbFRd-N0/p-Edt-lneGsJ

Script issue in J Meter while recording script using 'BAD BOY' tool

Chrome Settings
HI All - I am new to J meter and i am continuously getting the script error while recording the script using bad boy tool.
I tried with the changing the chrome settings as above:
but still am getting the same script error.
I hope when you normal browse the application then your are not getting the error.
So, if you are recording and getting pop-up but you can proceed further then record your action and suppress the javascript error from Preference>Automatically handle>Javascript Error Dialogs.
You can also disable recording javascript request from Preferences>Recording option. Since, jmeter work on request and response and not GUI level so javascript is not supported. It does not actually parse/execute JavaScript coming with the loaded page.
Also, try the option you have shown to disable script in IE browser and then try with chrome.
Hope this helps.

handling dynamic pop-up error message in jmeter

I have a Jmeter script for an application for which i get pop up error message intermittently. Where as in jmeter we only come to know that flow got terminated by some failure.But we wont come to know the occurrence of Error pop -up message.
My requirement is if we encounter pop up error i want to write to an external file saying that ,the current page got failed due to pop-up error message.
If we can write the error message it's really great. I'm as of now not getting idea to achieve this.
Please can anyone help me in this. or can provide any hint to do R&D.
Thankyou in advance.
Updated the question with screen shot of error message.
As per JMeter project main page:
JMeter is not a browser, it works at protocol level. As far as web-services and remote services are concerned, JMeter looks like a browser (or rather, multiple browsers); however JMeter does not perform all the actions supported by browsers. In particular, JMeter does not execute the Javascript found in HTML pages. Nor does it render the HTML pages as a browser does (it's possible to view the response as HTML etc., but the timings are not included in any samples, and only one sample in one thread is ever displayed at a time).
Looking into your screenshot, it is a form of JavaScript popup, most likely window.alert so there is no way to detect it via JMeter.
You can add i.e. Response Assertion to your test in order to introduce some pass/fail criteria, i.e. if you were in the middle of some transaction when the error occurred it should not finish successfully resulting in missing expected entry in the web page (or database), so you can conditionally fail relevant sampler(s) in this case. See How to Use JMeter Assertions in Three Easy Steps to learn more about the concept.
Alternatively you can use WebDriver Sampler plugin which provides JMeter integration with Selenium browser automation framework which drives a real browser, so you will be able to capture this popups and record the page titles/take screenshots, check out IsAlertPresent() class for more information.
you must get this error response in your jmeter request response.simple answer.Have a regex to extract.

JMeter REST Response is blank

I have searched extensively for the solution of this problem but did not get enough information. I am testing a GET request in REST API and although Sample Result is OK, I do not get any response in Response data tab. A screenshot is attached.
I am getting this error - ERROR - jmeter.protocol.http.sampler.HTTPJavaImpl: readResponse: java.util.zip.ZipException: Not in GZIP format
I have no java code. I know my REST API result is huge. (search result). Please suggest how do I get around this problem?
Thank you
Error
I remember facing this issue! Changing the implementation to java/HttpClient4/3.1 in the HTTP requests will work.

How do I avoid the "java.util.zip.ZipException: Not in GZIP format" error while using JMeter 2.12

I'm trying to record my interactions with a SAAS website using JMeter 2.12. I get the following error trace as soon as I try to login:
java.util.zip.ZipException: Not in GZIP format
at java.util.zip.GZIPInputStream.readHeader(Unknown Source)
at java.util.zip.GZIPInputStream.(Unknown Source)
at java.util.zip.GZIPInputStream.(Unknown Source)
at org.apache.http.client.entity.GzipDecompressingEntity.decorate(GzipDecompressingEntity.java:56)
at org.apache.http.client.entity.DecompressingEntity.getDecompressingStream(DecompressingEntity.java:68)
at org.apache.http.client.entity.DecompressingEntity.getContent(DecompressingEntity.java:82)
at org.apache.http.client.entity.GzipDecompressingEntity.getContent(GzipDecompressingEntity.java:41)
at org.apache.http.conn.BasicManagedEntity.getContent(BasicManagedEntity.java:89)
at org.apache.jmeter.protocol.http.sampler.HTTPHC4Impl.sample(HTTPHC4Impl.java:348)
at org.apache.jmeter.protocol.http.sampler.HTTPSamplerProxy.sample(HTTPSamplerProxy.java:74)
at org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1141)
at org.apache.jmeter.protocol.http.proxy.Proxy.run(Proxy.java:236)
Blockquote
I searched for the solution and found one in BugZilla: Bug 51918 where it says to turn off the concurrent download. I tried that by unchecking the "Retrieve All Embedded Resources" option in the 'HTTP Requests Defaults'- but still getting the error and cannot proceed.
Can anyone please help? Thanks a lot!
--Ishti
Ok, I think I got an answer. Thanks to Bhargav in his post where he basically told to change the 'HTTP sampler settings' (in the HTTP test script recorder) to 'Java'. I tried that and it's not giving me the error anymore. I can proceed. Thanks!
I got into this problem in JMETER this week. The solution that worked for me in current version is.
In the header manager add:
Accept-Encoding: gzip;q=0,deflate,sdch
The server will send you a response that JMETER can handle.
I got this error on a Web application (Genexus WebApp) when it sent me an HTTP 403 error code with invalid encoding.
So to troubleshoot the problem I use two approaches:
First, turn on the log level to DEBUG, and enable the Log Viewer:
With this we can see the current payload in the Viewer:
Another alternative is to set the accept-encoding to identity, to receive the payload uncompressed.
So after that, I figured out the problem was my request (invalid params)

Resources