java.lang.NoSuchMethodError with jspExample & my applica

User c226609425

22-08-2005 13:31:28

Pbm : java.lang.Exception: java.lang.NoSuchMethodError


chemaxon.marvin.skecth.swing.SketchPanel.getEditor()


Lchemaxon/marvin/skecth/j;











Hello,





I had an application with JChem and MSkecth which functioned well.


But since I carried out modifications on the server, an error appeared with MSkecth.


To see whether that came from the pages JSP which I also recently modified or not,


I reinstalled quickly the example provides with JChem and I have the same error.


So that must come from my configuration, but where ?





The configuration of the server is below :











Download --> The latest version of JChem








I/Environnment





Windows XP Pro SP2





CLASSPATH --> C:\Program Files\MySQL-Connector-Java\mysql-connector-java-3.1.7\mysql-connector-java-3.1.7\mysql-connector-java-3.1.7-bin.jar;%JAVA_HOME%\lib\tools.jar;C:\Program Files\Java\j2sdk1.4.2_08\bin;C:\Program Files\Java\javamail1.3.2\javamail-1.3.2\mail.jar;C:\Program Files\Java\jaf\jaf-1.0.2\activation.jar;%JCHEMHOME%\lib\jchem.jar;


or


CLASSPATH --> C:\Program Files\MySQL-Connector-Java\mysql-connector-java-3.1.7\mysql-connector-java-3.1.7\mysql-connector-java-3.1.7-bin.jar;%JAVA_HOME%\lib\tools.jar;C:\Program Files\Java\j2sdk1.4.2_08\bin;C:\Program Files\Java\javamail1.3.2\javamail-1.3.2\mail.jar;C:\Program Files\Java\jaf\jaf-1.0.2\activation.jar;





PATH --> %SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\Program Files\ATI Technologies\ATI Control Panel;C:\Program Files\MySQL\MySQL Server 4.1\bin;C:\Program Files\WinSCP3\;%JAVA_HOME%\bin;C:\Program Files\Vim\vim63\;C:\SFU\Perl\bin\;C:\SFU\common\;C:\Bioinformatics\corina;%UMR7081%





JCHEMHOME --> C:\TEMP\jchem





TOMCAT_HOME --> C:\Program Files\Apache Software Foundation\Tomcat 5.0











II/Version java





java -version --> 1.5.0_02








III/Files in <TOMCAT_HOME>








1/In /shared/lib





batik-core.jar jchem.jar chart.jar dom4j.jar








2/In /conf/server.xml





<Context path="/jchem" docBase="C:\TEMP\jchem" reloadable="true" >








NB : Please excuse me for the orthography faults.

ChemAxon a3d59b832c

23-08-2005 09:44:33

Hello,





I guess the problem is with the spelling of the package name:
Quote:
chemaxon.marvin.skecth
should be spelled:
Quote:
chemaxon.marvin.sketch
Best regards,





Szabolcs

ChemAxon 9c0afc9aaf

23-08-2005 12:24:45

Hi,





This error message is a typical sign of conflicting class versions.





As I understand this error message comes from the applet, right ?





As a rule, you should never include any ChemAxon jar files into your system CLASSPATH.





Please also try to clear the class loader cache in the Java Console.





Best regards,





Szilard

User c226609425

23-08-2005 13:47:06

Hello all the team and thank you of your assistance.





First of all, I have to carry out one copy-paste environment variables except the first three lines. The word "Skecth" was actually in reality good written. (Sorry).





Then, you were right the message comes from the applet and it was necessary that I empty the classloader cache in the java console.


That solved this problem well but of new appeared:








1/ With the old versions of the JChem tables, the error according to appears with the loading of the structures with the viewer (viewer of the latest version that we can download and with jsp1_x examples).





"java.lang.ClassNotFoundException: chemaxon.marvin.view.swing.modules.GridBagView


at sun.applet.AppletClassLoader.findClass(Unknown Source)


at java.lang.ClassLoader.loadClass(Unknown Source)


at sun.applet.AppletClassLoader.loadClass(Unknown Source)


at java.lang.ClassLoader.loadClass(Unknown Source)


at java.lang.ClassLoader.loadClassInternal(Unknown Source)


at java.lang.Class.forName0(Native Method)


at java.lang.Class.forName(Unknown Source)


at chemaxon.marvin.util.MarvinModule.load(Unknown Source)


at chemaxon.marvin.view.swing.ViewPanel.F(Unknown Source)


at chemaxon.marvin.common.swing.MolPanel.init(Unknown Source)


at chemaxon.marvin.common.swing.MolPanel.init(Unknown Source)


at JMView.init(Unknown Source)


at sun.applet.AppletPanel.run(Unknown Source)


at java.lang.Thread.run(Unknown Source)


Caused by: java.io.IOException: open HTTP connection failed.


at sun.applet.AppletClassLoader.getBytes(Unknown Source)


at sun.applet.AppletClassLoader.access$100(Unknown Source)


at sun.applet.AppletClassLoader$1.run(Unknown Source)


at java.security.AccessController.doPrivileged(Native Method)





"








2/ With the new version of JChem and a table creates with the latter jcman.bat ( provides with this version ), the following message however appears :


(the table is editexample)





"The structure table contains newer data version that this program version can handle. Please use a later version.





JChem version : 3.0.10


JVM : Sun Microsystems Inc. 1.4.2_08


OS : x86 Windows XP 5.1





Stack trace:


------------





chemaxon.jchem.db.DatabaseSearchException: The structure table contains newer data version that this program version can handle. Please use a later version.


at chemaxon.jchem.db.JChemSearch.initTable(JChemSearch.java:2335)


at chemaxon.jchem.db.JChemSearch.init(JChemSearch.java:2525)


at chemaxon.jchem.db.JChemSearch.search1(JChemSearch.java:1961)


at chemaxon.jchem.db.JChemSearch.search(JChemSearch.java:1862)


at chemaxon.jchem.db.JChemSearch.access$1200(JChemSearch.java:71)


at chemaxon.jchem.db.JChemSearch$SearchThread.run(JChemSearch.java:372)





"





Thank you in advance

ChemAxon 9c0afc9aaf

23-08-2005 14:31:07

Hi,





1: Please remove any ChemAxon jar files or classes from your CLASSPATH, and also delete the cache of the browser and restart the web server.





2: This is written by an older version of JChem (3.0.10) as it cannot search on a table created by a newer version of JChem (3.0.14 maybe ?).


You have probably forgot to change the jchem.jar in the shared/lib directory of Tomcat. Please restart Tomcat after changing the jar file.





Best regards,





Szilard

User c226609425

23-08-2005 16:17:12

Hi





One more time, you are right.


The problem came from an old jchem.jar that java loads.


Although the jchem.jar of the shared/lib was most recent, that which was charged was another more older located in a prohibited repertory (than I used to test small applications).





Thank you very much.