I want to record HTTPS using JMeter, but I want not to use JMeter GUI, only using command line/background service
I found similar answer but without relevant/accepted/upvoted answer
I want to use JMeter recording as a background service, is it possible? if not what are the alternatives?
If you trust only to accepted answers then you might be surprised a little bit when you see the number of upvotes on not accepted answers like this one. Given the answer hasn't been flagged/removed there is a chance it's valid and my expectation is that you should try it and upvote if it works and downvote in the opposite case.
If you tried the answer already but it doesn't fit your needs here is another one: any command-line network sniffer tool should be able of capturing the traffic and filtering it to SSL/TLS, for example tcpdump. Once you get .har or .pcap file with the traffic you can either use online [.har]5/[.pcap]6/etc. converter to JMeter or just paste captured request(s) payload(s) into the HTTP Raw Request sampler.
Related
Is it possible to extend Jmeter http script test recorder?
Would like to edit recorded requests automatically instead of doing it manually.
JMeter is an open source software distributed under Apache License 2.0 so you can add whatever functionality you need.
JMeter source code is available via Git and SVN repositories and you can find the official manual on extending JMeter at How to Write a plugin for JMeter
If you'll create something very useful for others I believe it would be a good idea to contribute it back, send a message to Apache JMeter Developer for further instructions on how you can add your code to JMeter.
If your idea of "automatic editing" is about adding missing automated correlation and you need the functionality right away you can consider and alternative recording service instead of JMeter's built-in proxy, check out How to Cut Your JMeter Scripting Time by 80% guide for details.
Of course it is possible. Look at this one
What's the best strategy when doing data correlation with jmeter? I have some ideas/questions, that go along these lines: usage of automatic correlation solutions (http://jmeter.512774.n5.nabble.com/automatic-correlation-for-jmeter-td5531399.html), usage of post processing extractors that best suite the need, for example regexp for http headers, xpath exp for HTML, if using xpath, get assistance by using Firebug or similar plugins, usage of xpath vs css&jquery, don't correlate data that isn't checked on the server, for example, if http referer is not controlled, it would be a waiste of time to correlate it, ... and such, but I would like to hear from more experienced people.
JMeter doesn't have autocorrelation. However you have tools like JCorrelate to accomplish the same. JMX Enhancers have some good tools that can help you cut your JMeter scripting time by 95%. Vist www.jmxenhancer.com for more details.
On the other hand, Blazemeter also have Smart JMX in their plugin which gives us autocorrelated scripts.
There is no auto-correlation for JMeter. HP Loadrunner has this functionality however it often fails.
XPath vs CSS/JQuery:
if your page has a very complex DOM and low number of styles - go for CSS
if DOM of your page is simple and styles number is high - go for XPath
If you simulating a real user using real browser - JMeter test should replicate it as close as possible, so make sure that you have:
HTTP Cookie Manager
HTTP Cache Manager
HTTP Header Manager
HTTP Request Defaults configured to:
Retrieve all embedded resources
Use concurrent pool of 2-5 threads for it
Filter out any external domains via "URLs must match" input
I don't know if this question makes much sense but i would like to know if load testing can be done on different IE versions. For instance my product supports IE 8, 9 , 10.... Please clarify more on this.
Thanks.
When we do load testing, we are more interested in knowing the server performance. Not the client's browser performance.
JMeter itself acts like a browser. It sends the Http request & once it gets the response, it can display it like a browser(it does not execute javascript files though. It makes sense because javascript is going to be executed in client's machine.)
So, for your question, JMeter is not a tool for your requirement. You may have a look at the httpwatch which shows the page load time for the browser.
This only makes sense if
You build pages dynamically based upon browser type and version
If your load for your exceptional condition on page generation, which is typically early versions of IE, is significant
Simulating different browser versions is not always a requirement is performance testing, but could be needed in specific case. Do it if it really makes sense to do.
There are commercial tools which can easily simulate the different browser types/versions like LoadRunner, Microsoft Visual Studio etc. If you are going to use open source, trying mimicing the scenarios by providing browser details/properties in user agents header etc., just like the actual browser sends. You can capture this by checking the request headers from the browser (press F12 on chrome and see network)
The only thing you can do with JMeter is adding a HTTP Header Manager to send different User-Agent header value for each Internet Explorer versions. You can refer Understanding user-agent strings guide to see user agent values for different IE versions, however I don't think it will provide the full picture as JMeter doesn't actually "render" page.
So I would go the following way:
Use JMeter to put your server under expected load
Use one Selenium instance per Internet Explorer version to perform real browser testing of the system when it's under JMeter's load to measure performance differences.
Rather a hard to nail down question, but basically I'm wondering what the best way (and not "what's your opinion" but "which will most adequately meet the requirement i shall set forth) is to open a stream connection from a client side webpage to a server such that either can send data to the other without polling? I'm thinking the term for this is HTTP binding vs. HTTP Polling. The context here is a chat application - i'd like a streamed connection so that the browser isn't constantly pushing requests out. The client end here is KnockoutJS and jQuery. I'd like to be able to have the data pushed back and forth be JSON (or at least manipulatable by jQuery and Knockout's toJSON). The server end - not quite sure what it is going to be, but i'll probably be running on a linux server, so anything compatible with that works fine.
If there's any more details i can provide, just let me know - i'm sure i left some obvious detail out. Also, i'm aware there's probably a duplicate question on this, so if your answer is as good as closing for a dupe and putting in a link, that's great.
Thanks!
I think what you're looking for is referred to as Comet. The basic idea is to keep HTTP requests open for longer periods of time so that the server can send data to the client as it comes in, rather than the client having to continually poll the server for new data. There are multiple ways to implement it. This Wikipedia article is a good start for more info.
This MIX 2011 video discusses the long polling technique (although the suggestion in the video is that web sockets will be a better solution with future browsers).
Is it possible to somehow mimic the slower download speeds of my website, as if it is hosted on a web server, but from my localhost?
It's hard to test things like Ajax loading icons when the content loads so quick from your local machine so I think this could help me out a lot?
I was wondering if there was a tool that you could use for this or if you'd need to use javascript to add setTimeout or setInterval code?
If you are using Windows, then download the Fiddler tool Fiddler.
This will setup a HTTP proxy that you can use for testing HTTP headers and view all the HTTP traffic within the PC and browser. You can then use the Rules > Performance > Simulate Modem Speeds option to slow the browser's HTTP connection.
There is also a Fiddler Switch plug-in for Firefox available to toggle the Fiddler proxy.
First of all, please never mangle your code with if ( DEBUG ) workSlowly(); statements. You will get bitten by this practice, and it will hurt.
Second of all, use one of the traffic throttling solutions which have already been posted here. I'm going to add a Java-based solution: Sloppy. It's dead easy to set up and runs everywhere where Java runs.
This question may help you out.
Personally, I add something like this at the top of my library file or whatever file always gets included:
if(DEBUG) {
sleep(2);
}
The above is PHP, but most languages are going to have something similar.
If you're on a *nix platform, you could alter the 'nice' level to basically make your process an afterthought behind most others until you achieve a level of 'lag' that is satisfactory to your needs.
One option is (if You are on linux, but other unix system have similar tools) Traffic shaping (google for 'HTB', 'qdics' and 'tc' command)
Second option will be apache_mod_cband module, this is also probably easer to get going.
You could try Charles. It's cross platform - I use it and it works really well.
http://www.charlesproxy.com/
On windows you can use Proxomitron or you can install fiddler (for ie). Both let you set the download speed.
If you use Fiddler 2, you can install this Add-On: Fiddler - Connection Simulator.
It gives you a nice UI to setup Bandwith and different simulation kinds.