Blog4Java

A personal and Java blog, likely only for me

Tomcat and JSTL: sometimes I feel tired

| 0 comments

Bazinga!

tomcat 7 org.apache.jasper.JasperException: The absolute uri: http://java.sun.com/jsp/jstl/core cannot be resolved in either web.xml or the jar files deployed with this application

You can dive into our beloved stackoverflow.com to find out that Tomcat doesn’t include JSTL,not even in Tomcat 8, in spite that they have an implementation of the JSP Standard Tag Library (JSTL) specification, versions 1.0, 1.1 and 1.2.

Of course, I have the correct taglib in the JSPs (note the /jsp within the URI):

I don’t want to include the JSTL jar included in the war, because it works in GlassFish (time to move to this server, or even try WildFly). Find here some interesting instructions if it is not your case.

Thus, it’s time to copy the JSTL.jar (available almost anywhere)

In NetBeans, you can go to Services (Window -> Services), find the Servers entry, right click in Apache Tomcat 8.0.3.0 to see its properties. This is the long way to discover where Tomcat is installed. In my case: /usr/local/apache-tomcat-8.0.3.

So I copied one of the available maven dependencies that I used to have and after restarting Tomcat, everything went OK.

Author: Javier (@jbbarquero)

Java EE developer, swim addict, occasional videogames player, fan of Ben Alex and Shamus Young, and deeply in love with my wife. Sooner or later I'll dedicate a post to expand this simple introduction.

Leave a Reply

Required fields are marked *.