June 25, 2003

jre version craziness

i've just now officially lost track of the number of G11N "quirks" related to jre versions and java implementations (ie OS). it seems many encoding, timezones, etc. "quirks" are related to jre version and/or OS. being a novice with java, its one of the last things i look at, hey java's monolithic and portable right? for instance (just because it fresh) one quick way to enable a particular encoding server-wide is supposed to be via jvm arguments "-Dfile.encoding=xxxx" where xxxx is the encoding you want to use. officially (ie via sun bug parade) this isn't supposed to work, as file.encoding is supposed to be read/only. that said, its an often suggested workaround on the java i18n forums for this sort of stuff (or where a library doesn't support encoding switches like some JDBC drivers). in practice though, its a bit hit and miss (or trial by error), depending on jre and os. for example, for jdk1.3.1_07 file.encoding is read/only; j2sdk1.4.1_02 is read/write; jre1.3 on linux doesn't work; jre1.3 works fine. so if you run into any sort of voodoo like G11N issue, perhaps the jre version for your server's OS is the real cause. so how did i figure this all out? i didn't. it was those bug hounds from hell at mm who did (damon cooper, hiroshi okugawa, jim schley et al). my g11n hat's off to them.

0 Comments:

Post a Comment

<< Home