Win a copy of Java Database Connections & Transactions (e-book only) this week in the JDBC forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Devaka Cooray
  • Knute Snortum
  • Paul Clapham
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Bear Bibeault
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Ron McLeod
  • Piet Souris
  • Frits Walraven
Bartenders:
  • Ganesh Patekar
  • Tim Holloway
  • salvin francis

unable to display charts in tomcat6.x  RSS feed

 
Ranch Hand
Posts: 57
Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi

on my local machine i am using tomcat6.0 with windows xp, charts(pie / bar ) in one of my application are displayed fine.
but when i push it to production server (tomcat 6.0) which is on linux , the charts are not displayed.

For generating charts i used chartDirectroy.jar classes, the error report by server is


type Exception report

message

description The server encountered an internal error () that prevented it from fulfilling this request.

exception


org.apache.jasper.JasperException: org.apache.jasper.JasperException: Unable to load class for JSP
org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:156)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:329)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:342)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:267)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)

root cause

org.apache.jasper.JasperException: Unable to load class for JSP
org.apache.jasper.JspCompilationContext.load(JspCompilationContext.java:620)
org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:144)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:329)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:342)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:267)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)

root cause

java.lang.ClassNotFoundException: org.apache.jsp.reports.getchart_jsp
java.net.URLClassLoader$1.run(URLClassLoader.java:200)
java.security.AccessController.doPrivileged(Native Method)
java.net.URLClassLoader.findClass(URLClassLoader.java:188)
org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:134)
org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:66)
org.apache.jasper.JspCompilationContext.load(JspCompilationContext.java:618)
org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:144)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:329)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:342)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:267)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
 
Bartender
Posts: 20771
124
Android Eclipse IDE Java Linux Redhat Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The immediate cause of failure is that the class "org.apache.jsp.reports.getchart_jsp" could not be found. However, that's a rather odd classname. It doesn't conform to Java standards. I'm guessing it might be a jsp that failed to compile, although the package name confuses me.

What I suspect is the REAL cause of the problem is the fact that the GUI isn't welded into the OS in Linux like it is in Windows. And, in fact, I don't have a GUI installed on any of my production servers. That's fine in most cases, but when you're generating charts and other graphics, the graphics routines borrow functions from the GUI, which in turn borrows functions from the Graphics Processor Units of a videocard.

You can still have your graphics, however, even without the GUI. You just need to configure Tomcat for headless operation.
 
kiran nyala
Ranch Hand
Posts: 57
Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ok thank you buddy..
 
A day job? In an office? My worst nightmare! Comfort me tiny ad!
how do I do my own kindle-like thing - without amazon
https://coderanch.com/t/711421/engineering/kindle-amazon
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!