0

I have a spring project that I updated to version 3. I added Jakarta to replace Javax. When I run the application I get a Failed to load class [javax.servlet.Filter] error. Some of the post on Stack recommend lowering the version of Tomcat, but I have to keep it at 10.1.11.

When I run mvn dependency:tree -Dverbose I see that javax is being used by kogito-spring-boot-starter which is at version 1.41 which is the latest release and javax is also being used by spring-cloud-starter-security which is at the latest release 2.2.5.

I am using Maven. How would I fix this?

Aaron
  • 4,380
  • 19
  • 85
  • 141
  • This will sound kinda dumb but have you simply tried to exclude those dependencies since you are using maven and add those specific dependencies ( jakarta.servlet.Filter )? https://maven.apache.org/guides/introduction/introduction-to-optional-and-excludes-dependencies.html#dependency-exclusions As for lowering Tomcat, you are correct, Spring 6 requires Tomcat 10, 9 will not work. Let me know if this helps Aaron. – zawarudo Aug 09 '23 at 01:08

0 Answers0