File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Tomcat and the fly likes JFreeChart / X11 window server error Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "JFreeChart / X11 window server error" Watch "JFreeChart / X11 window server error" New topic
Author

JFreeChart / X11 window server error

Susmitha Metlapalli
Ranch Hand

Joined: May 16, 2007
Posts: 44
Hi,

I am using JFreeChart for generating and displaying charts in jsp.

1. Copied "jfreechart-1.0.9.jar" and "jcommon-1.0.12.jar" to my application /WEB-INF/lib/ folder.

2. As it is a solaris box, i have added following to ".profile" and also executed .profile inorder to effet the changes.

JAVA_OPTS="-Djava.awt.headless=true"
export JAVA_OPTS

I am getting following errors...

Error 1:

HTTP Status 500 -

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

type Exception report

message

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

exception

javax.servlet.ServletException
org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:825)
org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:758)
org.apache.jsp.ViewChart_jsp._jspService(ViewChart_jsp.java:112)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)


root cause

java.lang.NoClassDefFoundError
org.jfree.chart.ChartFactory.createLineChart(ChartFactory.java:1163)
bsnl.chart.XYChartExample2.getChartViewer(XYChartExample2.java:78)
org.apache.jsp.ViewChart_jsp._jspService(ViewChart_jsp.java:61)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)


note The full stack trace of the root cause is available in the Apache Tomcat/5.0.28 logs.


Error 2:

HTTP Status 500 -

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

type Exception report

message

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

exception

javax.servlet.ServletException
org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:825)
org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:758)
org.apache.jsp.ViewChart_jsp._jspService(ViewChart_jsp.java:112)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)


root cause

java.lang.NoClassDefFoundError
java.lang.Class.forName0(Native Method)
java.lang.Class.forName(Class.java:141)
java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:62)
java.awt.Font.initializeFont(Font.java:308)
java.awt.Font.<init>(Font.java:344)
org.jfree.chart.axis.Axis.<clinit>(Axis.java:130)
org.jfree.chart.ChartFactory.createLineChart(ChartFactory.java:1163)
bsnl.chart.XYChartExample2.getChartViewer(XYChartExample2.java:78)
org.apache.jsp.ViewChart_jsp._jspService(ViewChart_jsp.java:61)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

Request you to suggest me...

Thanks & Regards,
Susmitha.
Susmitha Metlapalli
Ranch Hand

Joined: May 16, 2007
Posts: 44
Please help me...
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: JFreeChart / X11 window server error
 
Similar Threads
Action mapping error !!
what's the problem ?
exception in jsf
DBForms problem
JFreeChart / X11 window server error