How to Easily Load Test Vaadin Web Applications
Vaadin is great open-source web framework for developing rich internet applications. It is no secret, however, that running performance tests against Vaadin applications is rather complicated. Fortunately, there is one simple solution.
To put it briefly, in Vaadin the main issue is a big number of dynamic values which need to be correlated for every virtual user in the load test.
Although it is possible to find some workarounds to this issue, none of them is suitable for use in production environment. Facing this problem ourselves we developed a special Vaadin module right inside SmartMeter.io.
If you want to load test Vaadin application, all you have to do is download SmartMeter.io and use it to record and run load test. And that’s it.
How does it work?
The Vaadin module within SmartMeter.io automatically correlates all Vaadin dynamic values such as security keys (CSRF tokens), UI ids, sync ids and most annoying connector ids. Beyond that, it also adds validation assertions to be sure that the script is working as expected.
The best part is there is no configuration necessary, it all works out-of-the-box! Just download SmartMeter.io and record your test scenario with our Recorder.
Example Vaadin load test
Vaadin module was tested against Vaadin 7 and Vaadin 8. At this moment only the JSON message format is supported. See the official documentation for more details about load testing Vaadin.
Below you can see how the recorded test looks:
-
Automatically added response extractors for sync ID, security key, UI id and a bunch of connector IDs:
-
An example of connector ID extractor:
And this is the correlated request body:
{"csrfToken":"${vaadin.securityKey_5}","rpc":
[["${vaadin.cid.106}","cz.csob.vaadin7.framework.addons.general.shared.wolfiepopupextension.PopupExtensionServerRpc","setOpen",
[false]]],"syncId":${vaadin.syncId}}
Got you interested? You can try it for yourself. It's free.
Do you find this feature helpful? Let us know in comments.