Results 1 to 2 of 2

Thread: JSP exception on Tomcat, not on Glassfish

  1. #1
    Join Date
    Feb 2009
    Location
    Belgium
    Posts
    5

    Default JSP exception on Tomcat, not on Glassfish

    Hi,

    I've run into a problem here, where I'm probably just missing something related to tomcat.
    I've set up a simple web application with one controller and one jsp. When I deploy it to Glassfish, it all works well, but when I deploy the exactly same war to tomcat, I get an exception with following root cause:
    Code:
    java.lang.NullPointerException
    	org.apache.jsp.WEB_002dINF.jsp.welcome_jsp._jspInit(welcome_jsp.java:22)
    	org.apache.jasper.runtime.HttpJspBase.init(HttpJspBase.java:52)
    	org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:159)
    	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)
    	org.springframework.web.servlet.view.InternalResourceView.renderMergedOutputModel(InternalResourceView.java:236)
    	org.springframework.web.servlet.view.AbstractView.render(AbstractView.java:257)
    	org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:1183)
    	org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:902)
    	org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:807)
    	org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:571)
    	org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:501)
    	javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
    	javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
    When I use a simple servlet with a RequestDispatcher to the same jsp, it returns the same error.
    Do I need to do anything special configured for tomcat?

    The jsp is nothing special. Simply one for getting it to work:
    Code:
    <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
    <head>
    	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    	<title>Insert title here</title>
    </head>
    <body>
    	<h1>Welcome</h1>
    	<p>Welcome on --here comes the date--</p>
    </body>
    </html>
    I'm using the cargo plugin for maven to deploy and mvn package to make the war file.

    Any help is appreciated.

  2. #2
    Join Date
    Oct 2007
    Location
    Toronto, ON
    Posts
    90

    Default

    You may want to move the question to the Web forum, since this one is focusing on the Spring Integration (Enterprise Application Integration-oriented) project.
    Marius Bogoevici,
    Spring Integration Committer

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •