[ http://issues.apache.org/jira/browse/BEEHIVE-1032?page=comments#action_12361833 ]
Jin Kudo commented on BEEHIVE-1032: ----------------------------------- Thanks for your information about Tomcat request encoding configurations. So it should be cofigured correctly for handling multibytes data by Tomcat as you said. And I understood why current test recorder has strange code for handling incoming data. WLS also has same default encoding (ISO-8859-1). But I believe it should be changed to handle correctly by Tomcat side by the server side configuration which you provided and test recorder of servlet side don't consider any encoding just handle it as correct Unicode Stirng. So my suggestion on step1 is just do not anything by test recorder servlet side. I think if the Tomcat server isn't coinfigured correctly for handling UTF-8 and client send the multibytes UTF-8 data, the test recorder can handle the UTF-8 data by this out of the box solution, but other servlet which assume the correct String object is passed, cannot handle the multibytes string correctly. For quick testing, try to send the UTF-8 data and back it to client and record it by test recorder, the request data stored to xml file correctly but response data isn't stored to xml file correctly. After changing the server configuration to handle UTF-8, the result become to request data is wrong and response data is correct. So currently I apply the patch (do not anything in test recorder servlet side) and configure the server handle request encoding as UTF-8, then both request and response data was stored correctly if jvm itself is running as UTF-8 encoding. And even if we remain the current out of the box solution (convert incoming String as like a bytes array and convert it to Unicode String using ISO-8859-1 encoding), my suggestion for fix on Step 2 is still required. That is different issue and is exactly independent from request encoding. If the test recorder store data to xml file with UTF-8 encoding prologue name, it should be store the data as UTF-8 as fixed value. Currently the test recorder store the data using file.encoding, that cause to create wrong xml file. > TestRecorder handle request encoding > ------------------------------------ > > Key: BEEHIVE-1032 > URL: http://issues.apache.org/jira/browse/BEEHIVE-1032 > Project: Beehive > Type: Test > Components: NetUI > Versions: V1 > Reporter: Jin Kudo > Attachments: step1_patch.txt > > Currently the test recorder always handle the request encoding as ISO-8859-1. > That is cause to none ASCII characters can't be stored in the recording data > file correctly. Request encoding determination is not so easy, but I suggest > as the reasonable solution testrecorder use the platform encoding as request > encoding rather than fixed ISO-8859-1 value. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira
