I was trying to use jmeter to test our new Arabic web search engine, but things were not working well until I found out that the arabic "arguments" that are in utf8 were not encoded correctly. the URLEncoder/URLDecoder (in jdk's older than 1.4) use the default system encoding. jdk1.4 supports new versions of this methods that take two parameters: String to be encoded and the encoding to use for encoding. I just didn't have time to figure out which source file to edit to make the needed changes.
I don't know what to do with this one. I would think JMeter should use the local encoding. You are putting in utf-8 codes to simulate Arabic characters because you are on a non-arabic machine? If JMeter used utf-8 rather than the local encoding, wouldn't that also create problems for some people? The only other option is to give people a choice of encodings in the GUI... I'm just not sure how to resolve your problem that will also work for everyone else.
This comments may or may not be applicable since this bug is already several months old. I've run in to this problem with my application in the past. The way i got around the problem is to set file.encoding system property to ISO8859_1 (because jdk makes that assumption).
Can someone be more specific on what this bug is about? Provide a way to reproduce it, explain what the expected results are, and where actual results deviate from them? I'll currently reduce severity from Blocker to Normal (can't be a blocker if it's been open for so long!), and I'll close as INVALID if we don't get more info in a week or so. (Of course it can always be reopened).
If you have a web app which expects the client requests to be in a specific character encoding (e.g. it is an arabic web site and the servlet expects the requests to be utf-8) you need a way to tell JMeter which encoding to use to simulate clients using that encoding. The solution would be to provide a way to set the character encoding to be used by an http request (text field or combo box for example). But this would also require a full switch to J2SE 1.4, because there is no way to set the character set for url encoding in earlier java releases.
I'm using JMeter against a utf-8 website with alot of Japanese content. Using the latest tar ball (20/05/2003) this doesn't work. The posted values aren't encoded correctly. Thus I've temporarily altered the following file(in my source) until I can find or do a more complete solution: "org.apache.jmeter.protocol.http.util.EncoderCache.java" I changed: encodedValue = URLEncoder.encode(k); To: try{ encodedValue = URLEncoder.encode(k, "utf8"); } catch (UnsupportedEncodingException e) { System.out.println("Don't support utf8 encoding??"); e.printStackTrace(); } Yes - I know my exception handling here is bad :-p
This issue has been migrated to GitHub: https://github.com/apache/jmeter/issues/847