Hi,
I have set up a JMETER script to load test a Vaadin/Spring based application.
I used a very informative Web Dev Day presentation by Anastasia Smirnova as the basis for my JMETER script and it has worked very well.
My application has a login page and once logged in you can do various things.
My test scenario is well defined and works perfectly when simulating 10/20/30/n users using JMETER thread group.
My only issue is when I try to add a “loop” count. By that I mean I want to repeat the same script again in the same JMETER test.
When I do this, I get the following error at the start of the second iteration. A test iteration only takes a few seconds to complete.
30-17:16:32.267 [http-nio-8075-exec-19]
WARN c.v.f.s.c.UidlRequestHandler.synchronizedHandleRequest - Invalid security key received from 192.168.X.XXX
30-17:16:32.273 [http-nio-8075-exec-18]
DEBUG c.S.s.s.CustomRequestCache.getMatchingRequest - saved request doesn't match
30-17:16:32.277 [http-nio-8075-exec-18]
ERROR c.v.f.s.c.UidlRequestHandler.synchronizedHandleRequest - Error writing JSON to response
elemental.json.JsonException: Missing value
at elemental.json.impl.JsonTokenizer.getValueForLiteral(JsonTokenizer.java:292) ~[gwt-elemental-2.8.2.vaadin2.jar:2.8.2.vaadin2]
at elemental.json.impl.JsonTokenizer.nextValue(JsonTokenizer.java:177) ~[gwt-elemental-2.8.2.vaadin2.jar:2.8.2.vaadin2]
at elemental.json.impl.JsonTokenizer.parseObject(JsonTokenizer.java:231) ~[gwt-elemental-2.8.2.vaadin2.jar:2.8.2.vaadin2]
at elemental.json.impl.JsonTokenizer.nextValue(JsonTokenizer.java:173) ~[gwt-elemental-2.8.2.vaadin2.jar:2.8.2.vaadin2]
My JMETER script extracts the Security Key twice ( once for the login page and once for the rest of the application)
2020-06-30 17:16:32,748 INFO o.a.j.u.BeanShellTestElement: Security Key (Pre Login) = b811b32f-58e4-4ca9-b8e6-08f7732639dd
2020-06-30 17:16:33,044 INFO o.a.j.u.BeanShellTestElement: Security Key (Post Login)= 621bc80a-d66e-4abe-94ab-cc735a62ef79
I can resolve the problem by
(a) putting a pause at the end of the JMETER script of 1 minute using a “Flow Control Action”
(b) while my script is paused, I invalidate the session on Tomcat using the tomcat manager
Now, once the script pause expires, the second iteration runs without a problem.
Can anyone give me an idea as to what might be happening here?
Is there a relationship between a Vaadin Session and the Vaadin Security Key?
Grateful for any suggestions or even things to look at.
John.