You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jmeter.apache.org by Roger Abelenda <ra...@gmail.com> on 2024/03/13 21:25:22 UTC
JMeter 5.6 Backwards Compatibility Defaul Encoding
Hello,
First of all thank you all for keeping jmeter alive and thriving with new features, doing changes, updates, planning for new versions, constantly looking for ways to improve. In particular to Vladimir who seems to be the one investing more time in the latest releases.
Now, to the main matter of this email:
In JMeter 5.6.1 (a patch version) the default encoding for http samplers has been changed from the OS default one to UTF-8. Here is the pr: https://github.com/apache/jmeter/pull/6010
I have seen, and some people have mentioned to me as well, test plans starting to fail due to relying in OS encoding and the server, and request, being sensitive to such cases.
Shouldn't we consider this a non backwards compatible change, since existing test plans stop working and need to change to be able to use JMeter 5.6.1?
I agree that in the long term the default one should be UTF-8, and in general should always be a good practice to set the proper encoding instead of relying in OS defaults which are brittle.
Should we consider rolling back this change and release a patch version with such change, and plan for JMeter 6 (that I have seen has started to be discussed) to use UTF-8 as default encoding?
I would like again to thank everyone for the great work, and I hope I can help in some other way than reporting issues not in the best time (before the release is done).
Regards
Re: JMeter 5.6 Backwards Compatibility Defaul Encoding
Posted by Vladimir Sitnikov <si...@gmail.com>.
Thank you for the kind words.
>In JMeter 5.6.1 (a patch version) the default encoding for http samplers
has been changed from the OS default one to UTF-8. Here is the pr:
https://github.com/apache/jmeter/pull/6010
Sorry if it sounds like a dumb question, but could you please clarify what
exact issue you have?
For instance: "while doing X I expect Y but get Z".
The change in PR6010 was mostly for "filenames" and "parameter names".
It almost never makes sense in using "local encoding" for "file name",
especially when standards say the default should be UTF-8.
For instance, here's the sample:
https://github.com/apache/jmeter/pull/6010/files#diff-f4ed3a459e14e38c22c8567f45dfb56a0f9844cb10d8e9ba8eaa3536c7859600L935
Previously, JMeter sent the file as "?_param", and after the change it
improves to "安_param"
Of course, you might consider "bug fixed" as "breakage of the backward
compatibility", however, well, we need to fix bugs eventually.
---
As a side note, there was JEP 400: UTF-8 by Default in Java 18+, see
https://openjdk.org/jeps/400
That means, modern Java uses UTF-8 instead of "platform default" encoding.
> I hope I can help in some other way than reporting issues not in the best
time (before the release is done).
Even though issues after the release might look as "not in the best time",
as we can never have 100% test coverage.
It does help when somebody tests the released versions.
Vladimir