Running through lots of files and response is also in thousands. How do I save the json response with names similar to the name of files I sent as request? Is there any way? For example if I read a file with name"arnold.json" I want to take the response and write it to a file with name: "arnold_response.json"(something like this) The response I am getting looks like this:
{
"resourceType": "Bundle",
"id": "235-253-235-235-235",
"type": "transaction-response",
"link": [
{
"relation": "self",
"url": "https://someurl.com"
}
],
"entry": [
{
"response": {
"status": "201 Created",
"location": "Player/aerear",
"etag": "1",
"lastModified": "2020"
}
}
]
}
image of how my setup looks: https://ibb.co/MB46z6z
You can add a JSR223 Listener and use the following code there:
where:
varsstands for JMeterVariablesprevstands for the previous SampleResultMore information: Top 8 JMeter Java Classes You Should Be Using with Groovy