On my debian server today I run into a problem with the encoding of XSL templates running on a GlassFish server. The problem was that German characters where not displayed correctly.
After a long time of searching, I figured out that the reason for that problem was not my MySQL database, nor my GlassFish installation. It was simply the missing German language support on my linux debian.
You can test the installed locales with the following command:
In my case only 'en_US.utf8' was listed.
In debian you can simply add the german language support by changing the file /etc/locale.gen. Simply uncomment the lines:
and run the command:
After restarting my GlassFish server the xsl transformation works fine with german characters.
The command "locale -a" now displays the following locale: