From Alan.Bateman at Sun.COM Wed Oct 24 01:42:10 2007 From: Alan.Bateman at Sun.COM (Alan Bateman) Date: Wed, 24 Oct 2007 09:42:10 +0100 Subject: [Fwd: [PATCH] Load currency.data via ClassLoader] Message-ID: <471F0562.3050000@sun.com> Locale related utility classes are maintained by the i18n group - right? -------------- next part -------------- An embedded message was scrubbed... From: Roman Kennke Subject: [PATCH] Load currency.data via ClassLoader Date: Wed, 24 Oct 2007 10:27:04 +0200 Size: 8921 Url: http://mail.openjdk.java.net/pipermail/i18n-dev/attachments/20071024/3f37b0ed/attachment.mht From roman.kennke at aicas.com Wed Oct 24 01:51:13 2007 From: roman.kennke at aicas.com (Roman Kennke) Date: Wed, 24 Oct 2007 10:51:13 +0200 Subject: [Fwd: [PATCH] Load currency.data via ClassLoader] In-Reply-To: <471F0562.3050000@sun.com> References: <471F0562.3050000@sun.com> Message-ID: <1193215873.6891.24.camel@mercury> Hi, Am Mittwoch, den 24.10.2007, 09:42 +0100 schrieb Alan Bateman: > Locale related utility classes are maintained by the i18n group - right? Sorry, I'm a little lost with all those groups and mailing lists. By now I should be subscribed to almost all OpenJDK lists... /Roman > E-Mail-Nachricht-Anlage ([PATCH] Load currency.data via > ClassLoader.eml) > > -------- Weitergeleitete Nachricht -------- > > Von: Roman Kennke > > An: Core-Libs-Dev > > Betreff: [PATCH] Load currency.data via ClassLoader > > Datum: Wed, 24 Oct 2007 10:27:04 +0200 > > > > Hi there, > > > > in java.util.Currency, the currency.data is loaded from $JRE_DIR/lib. > > I'm having a problem with this in the JamaicaVM, when an application is > > built into a single bundle for use on an embedded machine. There is no > > JRE installed on that machine, and this file can't be loaded. I suggest > > to fall back to loading this file via the ClassLoader. See attached > > patch. This should affect normal behaviour, and only adds the option to > > put this file in the (boot) classpath instead. What do you think? > > > > /Roman > > -- Dipl.-Inform. (FH) Roman Kennke, Software Engineer, http://kennke.org aicas Allerton Interworks Computer Automated Systems GmbH Haid-und-Neu-Stra?e 18 * D-76131 Karlsruhe * Germany http://www.aicas.com * Tel: +49-721-663 968-0 USt-Id: DE216375633, Handelsregister HRB 109481, AG Karlsruhe Gesch?ftsf?hrer: Dr. James J. Hunt From Naoto.Sato at Sun.COM Thu Oct 25 09:42:07 2007 From: Naoto.Sato at Sun.COM (Naoto Sato) Date: Thu, 25 Oct 2007 09:42:07 -0700 Subject: [Fwd: [PATCH] Load currency.data via ClassLoader] In-Reply-To: <1193215873.6891.24.camel@mercury> References: <471F0562.3050000@sun.com> <1193215873.6891.24.camel@mercury> Message-ID: <4720C75F.9080308@Sun.COM> Hi Roman, Thank you for bringing this up. Yes, it's a bit unclear but the Currency class belongs to the i18n group. As to the issue, I have a question. Under jre/lib directory, there are other files that are not read via the ClassLoader method. For example, there are data files for time zones under jre/lib/zi, which are read via FileInputStream, the same way currency.data is read. My question is how the JamaicaVM is dealing with those files? I would expect that the same issue should have been observed with those files. Thanks, Naoto Roman Kennke wrote: > Hi, > > Am Mittwoch, den 24.10.2007, 09:42 +0100 schrieb Alan Bateman: >> Locale related utility classes are maintained by the i18n group - right? > > Sorry, I'm a little lost with all those groups and mailing lists. By now > I should be subscribed to almost all OpenJDK lists... > > /Roman > >> E-Mail-Nachricht-Anlage ([PATCH] Load currency.data via >> ClassLoader.eml) >>> -------- Weitergeleitete Nachricht -------- >>> Von: Roman Kennke >>> An: Core-Libs-Dev >>> Betreff: [PATCH] Load currency.data via ClassLoader >>> Datum: Wed, 24 Oct 2007 10:27:04 +0200 >>> >>> Hi there, >>> >>> in java.util.Currency, the currency.data is loaded from $JRE_DIR/lib. >>> I'm having a problem with this in the JamaicaVM, when an application is >>> built into a single bundle for use on an embedded machine. There is no >>> JRE installed on that machine, and this file can't be loaded. I suggest >>> to fall back to loading this file via the ClassLoader. See attached >>> patch. This should affect normal behaviour, and only adds the option to >>> put this file in the (boot) classpath instead. What do you think? >>> >>> /Roman >>> -- Naoto Sato From roman.kennke at aicas.com Thu Oct 25 10:10:09 2007 From: roman.kennke at aicas.com (Roman Kennke) Date: Thu, 25 Oct 2007 19:10:09 +0200 Subject: [Fwd: [PATCH] Load currency.data via ClassLoader] In-Reply-To: <4720C75F.9080308@Sun.COM> References: <471F0562.3050000@sun.com> <1193215873.6891.24.camel@mercury> <4720C75F.9080308@Sun.COM> Message-ID: <1193332209.6586.42.camel@mercury> Hi Naoto, > As to the issue, I have a question. Under jre/lib directory, there are > other files that are not read via the ClassLoader method. For example, > there are data files for time zones under jre/lib/zi, which are read via > FileInputStream, the same way currency.data is read. My question is how > the JamaicaVM is dealing with those files? I would expect that the same > issue should have been observed with those files. Exactly. The currency data was the first that has bitten me, but I would have to go through all of them of course. But let's start with this one and take them step by step. :-) /Roman -- Dipl.-Inform. (FH) Roman Kennke, Software Engineer, http://kennke.org aicas Allerton Interworks Computer Automated Systems GmbH Haid-und-Neu-Stra?e 18 * D-76131 Karlsruhe * Germany http://www.aicas.com * Tel: +49-721-663 968-0 USt-Id: DE216375633, Handelsregister HRB 109481, AG Karlsruhe Gesch?ftsf?hrer: Dr. James J. Hunt From jeroen at sumatra.nl Thu Oct 25 21:27:03 2007 From: jeroen at sumatra.nl (Jeroen Frijters) Date: Fri, 26 Oct 2007 06:27:03 +0200 Subject: [Fwd: [PATCH] Load currency.data via ClassLoader] In-Reply-To: <4720C75F.9080308@Sun.COM> References: <471F0562.3050000@sun.com> <1193215873.6891.24.camel@mercury> <4720C75F.9080308@Sun.COM> Message-ID: Naoto Sato wrote: > Hi Roman, > > Thank you for bringing this up. Yes, it's a bit unclear but the > Currency class belongs to the i18n group. > > As to the issue, I have a question. Under jre/lib directory, there are > other files that are not read via the ClassLoader method. For example, > there are data files for time zones under jre/lib/zi, which are read > via FileInputStream, the same way currency.data is read. My question > is how the JamaicaVM is dealing with those files? I would expect that > the same issue should have been observed with those files. As another data point, in IKVM.NET I ran into this issue as well. I worked around it by virtualizing the java.home directory. This is a bit of a hack, but it works well. Regards, Jeroen From Naoto.Sato at Sun.COM Mon Oct 29 11:11:17 2007 From: Naoto.Sato at Sun.COM (Naoto Sato) Date: Mon, 29 Oct 2007 11:11:17 -0700 Subject: [Fwd: [PATCH] Load currency.data via ClassLoader] In-Reply-To: <1193332209.6586.42.camel@mercury> References: <471F0562.3050000@sun.com> <1193215873.6891.24.camel@mercury> <4720C75F.9080308@Sun.COM> <1193332209.6586.42.camel@mercury> Message-ID: <47262245.10100@Sun.COM> Hi Roman, If that's the case, I believe some of them would require not only implementation change, but also the spec change. And I am even not sure whether they are actually doable or not. I'd like to find out whether it would be practically feasible, before fixing them one by one. Thanks, Naoto Roman Kennke wrote: > Hi Naoto, > >> As to the issue, I have a question. Under jre/lib directory, there are >> other files that are not read via the ClassLoader method. For example, >> there are data files for time zones under jre/lib/zi, which are read via >> FileInputStream, the same way currency.data is read. My question is how >> the JamaicaVM is dealing with those files? I would expect that the same >> issue should have been observed with those files. > > Exactly. The currency data was the first that has bitten me, but I would > have to go through all of them of course. But let's start with this one > and take them step by step. :-) > > /Roman > -- Naoto Sato