3 ms·
I used to do this a lot. It may look a little clunky, but there is a piece of software called JMeter (https://jmeter.apache.org/ https://jmeter.apache.org/) th
by i_like_apis 4y ago
I used to do this a lot.
It may look a little clunky, but there is a piece of software called JMeter (https://jmeter.apache.org/ https://jmeter.apache.org/) that is capable of doing just about anything you would want to do in a load test - modeling any request behavior, distributed traffic, awesome reports, etc.
10/10 recommend.
- drewcoo 4y agoJMeter is old and crusty and not at all friendly to work with. But I used it for years because it was really about the best we had. Today I don't wish it on anyone. Ruby JMeter finally made JMeter easier to manage, but I haven't worked in a Ruby shop for years, and I'm not going to force everyone to learn Ruby just to do some load testing. https://github.com/flood-io/ruby-jmeter https://github.com/flood-io/ruby-jmeter Then along came k6. It's developer-friendly and I've seen people actually enjoy using it. I recommend anyone considering JMeter also take a look at k6. They do a better job of selling it than I do: https://k6.io https://k6.io I am also Gatling-curious. Seems like an option for anyone in the JVM ecosystem. https://gatling.io https://gatling.io
- brabel 4y agoLooks like K6 is basically Gatling but with a JS-based DSL while Gatling uses Scala (or anything JVM-based like Java/Groovy/Kotlin)... there's also Locust[1] which is Python-based. What I really wanted was an interactive tool, like old LoadUI used to do (Wikipedia, nicely, still has the old screenshots which show how cool it used to look: https://en.wikipedia.org/wiki/LoadUI https://en.wikipedia.org/wiki/LoadUI)... because until you run tests, you just don't know what kind of load you can throw at the server (and whether you're hitting CPU/Memory/Bandwitdth limits instead of server limits). Visual Components were written in a scripting DSL (Groovy based) and dynamically loaded so you could change the code even while the test ran... really awesome stuff, a bit like coding in Lisp with a visual facade on top. Based on existing tools, it should be relatively easy to build something like that and I am surprised there seems to be nothing of the kind. I've always wanted to do it myself, maybe one day if no one else finally tackles the problem. [1] https://docs.locust.io/en/stable/ https://docs.locust.io/en/stable/
- i_like_apis 4y agoDisagree. Old? I guess, but that doesn’t mean bad … it has recent feature development and is currently maintained. Crusty is not an adjective I would use, which seems like more ageism. It’s not an amazing GUI, but it’s very powerful. It will do whatever you want. It's quite flexible and easy to define what I need it to do, to store and load configuration, and it has very meaningful reports. All of these things are pretty easy. A one-size-fits all paid service could give you 3-click interactions and glossy charts, but at the cost of control and understanding what's really going on, and you're more likely to have wrong assumptions about what's happening. Summary: load testing is just complicated enough that it requires effort, thought, and a good toolset. Also K6 may be good or whatever, but it is a paid service. JMeter is free.
- nerdponx 4y agoMy problem with JMeter (and load testing in general) is that all the recommended tools are extremely powerful if you know what you're doing, but provide little guidance if you aren't already an expert. I would love an old school "wizard" app that generates a sensible JMeter config for me. I've just been using the Apache Benchmark "ab" tool with mostly-default settings for now.
- i_like_apis 4y agoA wizard is an interesting idea. As for learning load testing, it's mostly medium-easy in terms of effort and understanding required; it requires a little bit of effort to know what you're doing. Also a bit of scientific common sense and maybe some knowledge of statistics helps. I think any of these are probably good. https://www.amazon.com/s?k=jmeter https://www.amazon.com/s?k=jmeter I read a Packt or Apress one that had more than enough on how to use it. I don't remember which one though.
- yabones 4y agoJmeter does have a proxy mode that records your traffic and saves it to a working config. From there you can tweak timings, add variables, loops, etc. It's a decent starting place if you have no experience with building load testing plans. https://jmeter.apache.org/usermanual/jmeter_proxy_step_by_step.html https://jmeter.apache.org/usermanual/jmeter_proxy_step_by_st...
- tbrownaw 4y agoA while back, I had to get scaling numbers for something that did multipage forms where individual pages might refresh themselves from the server depending on what dropdowns you picked, might pull option lists if certain questions were visible, etc. I ended up using Selenium on a giant pile of cloud VMs, because the $$$$/run looked cheaper than my wild guess about the dev time for a more efficient tool. Do you know of any guides or general overviews for using JMeter (Or Gatling or such) for this, or maybe for determining the appropriate degree to categorize and randomize sessions (some of those option listings were pretty expensive, and it wouldn't have been good to just skip them)? From my brief look at the time, it seemed that it'd be a major pain and I'd have to figure out any script logic on my own without a whole lot in the way of pre-written guides.
- i_like_apis 4y agoAh yes, selenium is definitely too much overhead for load testing. You will get much better cost, performance and control with jmeter. There’s also much less to develop once you know how to use it. You can also play back recorded sessions and parameterize variables if you want to design traffic in the browser. There are a handful of great technical manuals in the way of books about JMeter. Search Amazon for jmeter and you will find some current ones. I read one and it was really helpful, just can’t remember which. They all look pretty good though.