I have a web application running in embedded Tomcat. If I run my TomcatRunner and access a JSP page, I get the following error:
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
I tried every similar error on StackOverflow and Google, but nothing work. Any idea?
My goal is Tomcat 9.0.35, (Servlet 4.0, JSP 2.3, EL 3.0)
my configuration:
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<version>4.0.1</version>
</dependency>
<dependency>
<groupId>javax.servlet.jsp</groupId>
<artifactId>javax.servlet.jsp-api</artifactId>
<version>2.3.3</version>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>jstl</artifactId>
<version>1.2</version>
</dependency>
<dependency>
<groupId>javax.servlet.jsp.jstl</groupId>
<artifactId>jstl-api</artifactId>
<version>1.2</version>
</dependency>
(no taglib/standard)
In my JSP: <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
In web.xml:
<?xml version="1.0" encoding="UTF-8"?>
<web-app
xmlns="http://xmlns.jcp.org/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_4_0.xsd"
version="4.0">
...
</web-app>
After mvn clean package, I see target/.../WEB-INF/lib/jstl-1.2.jar ... but calling the JSP will lead in this error: 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 (I also tried the 'provided' mode without success)
Do you see any error ? do you have any demo application with JSP 2.3 and Tomcat 9.x embedded ? do you know how to trace jstl*jar search by Tomcat ?
Thanks for any help