JSP Exception after making JAR

Hi,

I'm getting this exception while I package my java class files and properties files as a jar and put it in library. I'm using struts framework which extensively uses tiles. After packaging I dont have any files in the classes directory but all the files are in the library.

while I debug it goes to Action classes and it executes JSPs so it was able to refer classes properly. But failes in some taglibs.

Any help would apprieciated.

ServletException in:/layout/channelpage_enhanced.jsp] null' javax.servlet.ServletException at org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:843) at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:776) at org.apache.jsp.layout.channelpage_005fenhanced_jsp._jspService(channelpage_005fenhanced_jsp.java:1373) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:334) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:672) at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:574) at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:499) at org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.java:966) at org.apache.jasper.runtime.PageContextImpl.include(PageContextImpl.java:602) at org.apache.struts.tiles.TilesUtilImpl.doInclude(TilesUtilImpl.java:137) at org.apache.struts.tiles.TilesUtil.doInclude(TilesUtil.java:177) at org.apache.struts.taglib.tiles.InsertTag.doInclude(InsertTag.java:756) at org.apache.struts.taglib.tiles.InsertTag$InsertHandler.doEndTag(InsertTag.java:881) at org.apache.struts.taglib.tiles.InsertTag.doEndTag(InsertTag.java:473) at org.apache.jsp.layout.standard_005ftemplate_jsp._jspService(standard_005ftemplate_jsp.java:867) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:334) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:672) at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:463) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:398) at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:301) at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1069) at org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcessor.java:274) at

[3545 byte] By [tethysonea] at [2007-11-26 15:58:29]
# 1

Instead of building your class files into a jar you might want to consider building the entire web application into a war file for deployment. I do this even for deployment to my local test server just to keep things more similar between my local server and the deployment server.

This is an excerpt from my ant build

<target name="build.war">

<echo message="Building the war file for the web application"/>

<war

destfile="${p.app.jar.dir}/appname/WarFile.war"

webxml="${web.module.web-inf.dir}/web.xml">

<fileset dir="${web.module.resource.dir}">

<include name="*.*"/>

</fileset>

<classes dir="${web.module.classes.dir}"/>

<fileset dir="${p.app.jar.dir}/appname">

<include name="*.jar"/>

</fileset>

<fileset dir="${web.module.web-inf.dir}">

<include name="*.*"/>

</fileset>

<manifest>

<attribute name="Class-Path" value="Service-client.jar"/>

</manifest>

</war>

</target>

Just a thought your milage may of course vary.

PS.

puckstopper31a at 2007-7-8 22:19:34 > top of Java-index,Java Essentials,Java Programming...
# 2
Actually the aim was to create a JAR and use it as an API that is shared among multiple projects...I have the option of WAR deployment but want to give this a shot.
tethysonea at 2007-7-8 22:19:34 > top of Java-index,Java Essentials,Java Programming...