Performance Testing In JMETER - performance

While doing performance testing using Jmeter for a script, the viewstate captured while recording the script and the Runtime viewstate (i.e obtained after running the script in Jmeter) for a particular transaction does not match. Hence, could anyone suggest any solution to resolve this issue and capture the viewstate?

Viewstate changes so you need to use the regular expression extractor to get this value from the previous page and pass to current. You can find some information on how to do this here:
http://wiki.apache.org/jmeter/JMeterTesting/ASPNETViewState
Another thread from the SQA forum:
http://www.sqaforums.com/showflat.php?Number=608116

Once upon a time I worked on JMeter. I really don't remember if I faced the issue. But, I have captured my learning here. You can probably take a look. Would be happy if it helps you.

Related

jmeter with BI4 .2 SP6

I have recorded script through Blaze meter and tried executing thru jmeter after adding com.sun.faces and bttoken. I have tried adding sEntry but unfortunately I didn't find the key.
Issue: It is not performing refresh report activity because I was monitoring in the backed sessions.
Looking into BI4 Web Intelligence Performance Test with JMeter article it should be strEntry and the relevant Regular Expression Extractor configuration would be something like
Actually you can use another approach to recording JMeter tests which can export recorded scripts in "SmartJMX" mode with automatic detection and correlation of the dynamic data, it might help you to come up with the properly correlated version of the load test with the minimal efforts. Check out How to Cut Your JMeter Scripting Time by 80% article for more details.
If you need further help on manual correlation consider including previous sampler response and the next request details into your question

50% samples for same requests failing while execution of Jmeter script

I am executing Jmeter script and 50% samples for same request are failing. I am not sure why this is happening. Can someone help me to understand if this due to our server issue or because of my Jmeter script.
Edited: I found out that some samples are not able to extract regex from previous sample due to which failure is occurred. Now I wanted to know why some samples can extract regex and some cannot?
Thanks everyone for you help. Issue is resolved when I updated user-agent in header manager for that particular request.

How do I perform a complete Load Test process with JMeter?

I am new to using JMeter and have developed a basic test plan with HTTP Sampler and a few listeners. Please run me through the entire process of how I can start after opening JMeter ?
There's no right answer for this, it depends what you're wanting to achieve. I'd suggest starting with the best practices: http://jmeter.apache.org/usermanual/best-practices.html
And also look at building a web test plan: http://jmeter.apache.org/usermanual/build-web-test-plan.html
I would look at the Graphs Generator listener - https://jmeter-plugins.org/wiki/GraphsGeneratorListener/ - use these graphs to make sure you're making the number of transactions that you would expect in your tests.
Basically - the documentation is your friend. I took time to read what each controller, listener and sampler was doing and decided how to implement these myself. There was some trial and error. JMeter is an easy tool to pick up and use but there's a LOT of depth to it.
In addition to Ali1874 answer, I would suggest looking into how to run JMeter tests using command line. You can find more information at http://jmeter.apache.org/usermanual/get-started.html#non_gui. With regards to reporting JMeter is able to produce nice HTML reports when using -e -o options http://jmeter.apache.org/usermanual/generating-dashboard.html#report_after_load_test.
Also, with regards to Jmeter test plans, in my previous company we used to parameterize number of threads required, servers and other elements. In general structure looked like the one at the example test plan.
We had different user defined variables elements for different environments for faster test tuning. Also, we used bzm – Weighted switch controller (https://github.com/Blazemeter/jmeter-bzm-plugins) to distribute load among endpoints by including HTTP requests from Test Fragment element so that we would not have to duplicate requests allowing to manage them more easily. You can check out full plan at here (https://github.com/gretard/testing/blob/master/00-jmeter/results/samplePlan.jmx). Please bear in mind that test plan uses bzm – Weighted switch controller plugin and jpgc - Standard Set plugin which you can install by using Plugins manager (https://jmeter-plugins.org/wiki/PluginsManager/).
Hope this will help.

Load Testing asp.nt core app

I have an asp.net project ,which I want to load test with around 100 users at a time , can someone plz tell me how can I do this. I tried jMeter but it seems very difficult to understand as because I m doing this first time..Thanks In Advance
First of all, you need to create test script. You can do this manually in Jmeter GUI, or you can use Recording controller or something like SmartMeter's Recorder
After that, you should have recorded script and you can edit it. Add some neede correlations, special variables, prepared data and so.
Before running the test, change number of threads to 100, setup rump-up time and you can start your test.
I suggest you to try some tutorials about load testing and Jmeter, eg.
Tutorials point
SmartMeter's quickguide
Blazemeter's tutorial

can we have any jmeter control over the threads?

can we have any control over the threads?
Consider i have 10 threads and i have provided my test data in .csv file. so can I control on threads like which thread should pick which data and may be some delay for few of the threads?
Also, can someone suggest me some book or online content wherein i can have information on internals of JMeter. Like when we run test plan, what all things are happening on memory side, reading of different properties files, receiving response, how threads internally works, etc.
Thanks,
Abhishek
JMeter is a very flexible and powerful tool. In theory, anything is possible it all depends on what your testing goals are. Even things not supported by JMeter can be coded in Java and easily integrated with a Java Sampler. Your question indicates you have not spent a lot of time experimenting with the tool, but hopefully my answer jump-starts that process for you.
JMeter has a lot of control features that can be used in conjunction with CSV data to control the flow of a thread. For example, use the CSV data to correctly enter the right block of a Switch Controller, validate an If Controller, or control the number of loops in a Loop Controller. Be sure you read the entire Getting Started Guide and familiarize yourself with the Component Reference Guide
In terms of how things work internally, your best bet is to build the JMeter project from source in an IDE like Eclipse. You can then step through the entire program in as much detail as you want.
Tutorial: Build JMeter from Source
Also, the /bin/jmeter file has a decent number of comments about how to properly configure JVM memory for a JMeter process.
You probably want to install at least the most basic JMeter Plugin Package.
Lastly, if you need one thread to control the behavior of another thread you can use FIFO Queues or set JVM properties via Beanshell which are global and not unique to a thread like runtime variables.
props.put("key","value");

Resources