I'm having trouble parameterizing a URL in Jmeter (v 2.3.2).
I have a logfile of URLs, read with a CSV Data Set, and a second file of
parameter values read with a second CSV Data Set. I want to replace a parameter
("mac_address") in the URL with the value from the second file. I.e., I want to
convert http://localhost/info?macAddress=00%3A19%3Aa6%3A10%3A89%3Ade& to
/info?macAddress=${mac_address}&
I'm using an HTTP Request path of
${__regexFunction(.*//[^/]*(.*)acAddress=[0-9a-fA-F%]*(.*),$1$acAddress=${mac_address}$2$,1,,${url},mac_url,url)}
to both remove the "http://localhost" from the url and to replace the
mac-address parameter. Alas, I'm getting the mac_address at the end of the url,
not in the middle.
A Debug Sampler shows:
url=http://localhost/SM_WS/rest/customer/info?accountNumber=12340019A61089DE&macAddress=00%3A19%3Aa6%3A10%3A89%3Ad
e&name=spam
mac_url=/SM_WS/rest/customer/info?accountNumber=12340019A61089DE&m&name=spamacAddress=00%3A00%3A39%3Abc%3A16%3A5e
mac_url_g0=http://localhost/SM_WS/rest/customer/info?accountNumber=12340019A61089DE&macAddress=00%3A19%3Aa6%3A10%3A89%3Ade&name=spam
mac_url_g1=/SM_WS/rest/customer/info?accountNumber=12340019A61089DE&m
mac_url_g2=&name=spam
mac_url_matchNr=1
Am I doing something wrong, or is this a bug in JMeter?