Reputation: 3
I'm trying to read a string which has XML and facing an unexpected token issue.
I'm using a JSR223 Sampler in JMeter and trying to read value by using
request_payload=vars.get("${requestPayload}");
I have my xml in variable requestPayload=
"<soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope">
<soap:Header><wsse:Security "
I want to read this value in JSR223 Sampler.
The error message:
Response message: javax.script.ScriptException: org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed: Script4.groovy: 1: unexpected token: http @ line 1, column 54. t("
<soap:Envelope xmlns:soap="http://www
Upvotes: 0
Views: 773
Reputation: 499
Correct syntax to overcome the error is given below:
vars.get("requestPayload");
Upvotes: 0
Reputation: 58772
Don't use ${} syntax in JSR223, Simply
vars.get("requestPayload");
Upvotes: 0