Messages of subject
Class not found error despite proper setup |
YoavShapira
Member since : Jan 6, 2004
Messages : 2
|
Jan 6, 2004 at 4:32 PM
I'm using Sun JDK 1.4.2 on Solaris 5.8. I have a servlet running on tomcat (5.0.16) that uses a 3rd party library (MDL's Chime Pro) to draw molecular structures. This library cannot run in headless mode, so I have to use PJA.
I've downloaded and setup PJA 2.5 beta. I've added the pja.jar to my bootclasspath, and the other runtime options (-Dawt.toolkit, -Djava.awt.graphicsenv, user.home, etc.). Yet I still get the following error at runtime when I first invoke the chime library:
java.lang.Error: Could not find class: com.eteks.java2d.PJAGraphicsEnvironment
at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:68)
at java.awt.Font.initializeFont(Font.java:308)
at java.awt.Font.<init>(Font.java:344)
at mdli.mt.metafile.windows.a.<init(Unknown Source)
...
So what am I doing wrong? My only guess is this: I set user.home to a directory that contains the font.properties that comes with the PJA toolkit, but I set java.awt.fonts to $JAVA_HOME/jre/lib/fonts. Is that OK?
Thanks,
Yoav Shapira
|
Manu
Location : Paris / France
Member since : Apr 29, 2003
Messages : 394
|
Jan 7, 2004 at 12:16 AM
Before going further, could you try a simple servlet like the one given at http://www.eteks.com/pja/en/forum/viewSubject.jsp?subjectId=51#54 (it's just a JSP file to copy) ?
If it doesn't work, could you try again PJA but with an older JDK (JDK 1.3.1 or JDK 1.4.1) ?
I would like to be sure that Sun didn't change again some of its internal configuration in its latest release of Java 1.4.2, before doing a deeper search. --- Manu (moderator/modérateur)
|
YoavShapira
Member since : Jan 6, 2004
Messages : 2
|
Jan 8, 2004 at 6:08 PM
> Before going further, could you try a simple servlet like the one given at http://www.eteks.com/pja/en/forum/viewSubject.jsp?subjectId=51#54 (it's just a JSP file to copy) ?
> If it doesn't work, could you try again PJA but with an older JDK (JDK 1.3.1 or JDK 1.4.1) ?
> I would like to be sure that Sun didn't change again some of its internal configuration in its latest release of Java 1.4.2, before doing a deeper search.
Manu, thanks for your reply (and the many others I read before posting my question). In the meanwhile I dumped PJA in favor of Xvfb, which was a breeze to set up and works flawlessly, so I'm not going back to PJA.
|
phamdinhnguyen
Location : boston. ma
Member since : Feb 6, 2004
Messages : 7
|
Feb 9, 2004 at 6:11 PM
> ... In the meanwhile I dumped PJA in favor of Xvfb, which was a breeze to set up and works flawlessly, so I'm not going back to PJA.
I'm at this crossroad myself.
Can you share the precise steps to set up Xvfb.
I'd like to communicate these steps to my Admin person.
Thanks.
[Message from Moderator : phamdinhnguyen targets AIX and not Solaris]
|
phamdinhnguyen
Location : boston. ma
Member since : Feb 6, 2004
Messages : 7
|
Feb 10, 2004 at 5:59 PM
> I'm at this crossroad myself.
> Can you share the precise steps to set up Xvfb.
Clarifications:
My OS is AIX, not Solaris.
Regardless, installation/configurations of PureJavaAWT remain the same.
My final working solution for AIX, after exhausting all possible settings, is XVFB.
If you MUST get a solution, check out this link for details:
http://publibn.boulder.ibm.com/doc_link/en_US/a_doc_lib/aixprggd/aixwnpgd/xvfb.htm#Header_363
Best luck!
|
Manu
Location : Paris / France
Member since : Apr 29, 2003
Messages : 394
|
Feb 10, 2004 at 6:07 PM
> Regardless, installation/configurations of PureJavaAWT remain the same.
Even if PJA Toolkit configuration looks the same on AIX and Solaris, believe me from the past experience of PJA users, these JVMs are different and use different font configuration (as far as I can remember, PJA Toolkit never worked on AIX with JDK 1.2). These small differences are the reason why it may not work for you on AIX inspite of your search ; there are generally less problems on Solaris. --- Manu (moderator/modérateur)
|
phamdinhnguyen
Location : boston. ma
Member since : Feb 6, 2004
Messages : 7
|
Feb 10, 2004 at 8:08 PM
In retrospect, PJA initially was my favorable choice due to its 'breeze of installation and configuration'. This was true even on AIX OS.
Its accompanied certification tools are definitely a great idea. 3 out 4 created GIFs went w/o a hiccup. Unfortunately the failure to get TEXT component works properly was a real show-stopper on AIX 43 / JDK 131.
Regaedless, PJA has the advantage that it can be isolatedly installed to only application servers that need it.
|