got MissingPropertException from Jmeter while using addArgument for http Request sampler

32 Views Asked by At

i am trying to do a load test for a registration scenario, and i am completely new to the jmeter. with some help from gpt i did a scripting in JSR332 sampler to dynamically create username and email till the count of thread group, so each time a new username and email will be created and i can pass the username and email with default password, but i am getting error from it, Consider i have 2 thread groups

enter image description hereenter image description hereenter image description hereenter image description here

1

There are 1 best solutions below

0
Ivan G On

In your script you use registration object but you don't instantiate it anywhere.

Given you don't understand what does the code do I would suggest asking the person or LLM who provided you this code to fix this going forward.

As an exception I provide you the hint so at least just this error will go away, you will need to add the next line before first access to the registration object:

def registration = new org.apache.jmeter.config.Arguments()