Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Compilation exeption

 
schneider jean-marie
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello !

I have developed a java application and it work fine on my own server where is installed Tomcat (this server is not the develpment machine). When I call the index.php with my browser I can see the expected result (as well if I do the deployment with the war file or if I upload the file of the application.
As my application work fine I uploaded the files on my remote site (here I can only upload the files, I can't use the war file) which use also Tomcat. But when I call the URL I have the following error :
exception
org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: 11 in the jsp file: /index.jsp
Generated servlet error:
[javac] Compiling 1 source file

/usr/local/jakarta-tomcat4.1/work/Standalone/chemical-sourcing.com/Marvinb/index_jsp.java:7: package chemaxon.calculations does not exist
import chemaxon.calculations.ElementalAnalyser;

But the chemaxon library is in the lib folder as on my own server ?

What I am doing wrong ?
Thanks you for your help,
Jean-Marie
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
But the chemaxon library is in the lib folder as on my own server ?


Can you post the directory structure for the entire web app?
There is more than one "lib" directory in a Tomcat installation.

The location of the lib directory (and several others) is also important.
 
schneider jean-marie
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you for your reply !
The directory is as follow :
+ Marvinb
_______index.jsp
_____+ META-INF
________ contex.xml
_____+ WEB-INF
_______+ class
_______+ lib
__________ marvin.jar


jean-Marie
[ May 25, 2005: Message edited by: schneider jean-marie ]
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That looks correct to me.

Were you able to restart Tomcat or reload your application after uploading the files?

Is it possible that the jar file was corrupted during upload?
(I'm guessing not. You would usually see a java.util.zip exception in that case)

On your local machine, do the classes from the jar file also exist in under the classes directory?
 
schneider jean-marie
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No all of the classes are in the jar file.
I have not the possibility to restart Tomcat : the server is not mine.

I upload twice the jar file, so I think that my problem is not comming from this...
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65223
95
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have not the possibility to restart Tomcat


You can upload the jar file as many times as you'd like, but it will not take effect until the web app can be reloaded. The brute force approach is to restart the server, but if you an convice the owner of the server to set up the Tomcat manager for your context, you will be able to stop and start the web app itself without requiring a server restart.
 
schneider jean-marie
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
but if you an convice the owner of the server to set up the Tomcat manager for your context, you will be able to stop and start the web app itself without requiring a server restart.
What are you saying is very interresting. I am not aware for that. All time I restart my Tomcat server.
Can you give me the way to restart the application itself ?

Thanks again !
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65223
95
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Since this is Tomcat-specific, moving to that forum.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65223
95
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Tomcat comes with a web app manager application which should be configured for the default host. If you are putting your web app in the default host, you should be able to hit the following URL:

http://yourserver/manager/html/list

and get the manager control panel. You will need to have the server owner set you up as a Tomcat user with the "manager" role.

If you have set up your web app in a virtual host, you can add the manager app to that host by adding the following context declaration to the host declaration in server.xml. Here's an example from an OS X/Tomcat 5.0.25 setup:



Of course, you would need to adjust the path as suitable for your own installation.
[ May 25, 2005: Message edited by: Bear Bibeault ]
 
schneider jean-marie
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you for this very interresting answer. Now I have to know if I can do that !

Jean-Marie
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic