0

While load testing with JMeter I am attempting to send 1000 requests in one second. The issue is that I need to send the access token aquired from each previous login. While doing so I am getting the following error:

java.net.URISyntaxException: Illegal character in path at index 67: https://greenback-api.com/api/subscribers/getSavings/${USER_ID}?access_token=${AUTH_TOKEN}

Typical under a low load JMETER has no problem transforming the variables into a valid url likeso:

api.com/api/subscribers/getSavings/4?access_token=443hrr4938rh9ghreughughtrugtrgt4

Is there a way to force JMETER to render the url variables before issuing a get request even under a high load?

Joseph Persico
  • 602
  • 7
  • 20

1 Answers1

1

It looks like sometimes ${USER_ID} and ${AUTH_TOKEN} are not returned by login (or whatever sets them). As a result JMeter will use the expression ${...} as is. And the characters {} are indeed invalid for URI (they have to be encoded).

Another option is that ${USER_ID} or ${AUTH_TOKEN} really contain some characters invalid for URI and that need to be encoded.

So you may need to

  1. URL Encode your ${AUTH_TOKEN} (and possibly ${USER_ID})
  2. Make stricter checking upon login completion (and any other operations that fill ${USER_ID} or ${AUTH_TOKEN}) to make sure they don't proceed to the following operations if the value was not returned.
Community
  • 1
  • 1
timbre timbre
  • 12,648
  • 10
  • 46
  • 77