Giter Club home page Giter Club logo

spring-petclinic's Introduction

This is a fork of https://github.com/spring-projects/spring-petclinic.git to show a Thymeleaf issue in Spring Boot 3 running in Open Liberty.

Run

mvn clean liberty:run

and start the application in your browser using http://localhost:9080/

This will trigger the following stack trace:

Exception thrown by application class 'org.springframework.web.servlet.FrameworkServlet.processRequest:1022'
jakarta.servlet.ServletException: Request processing failed: java.lang.IllegalArgumentException: Cannot build an application for a request which servlet context does not match with the application that it is being built for.
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1022)
at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:903)
at jakarta.servlet.http.HttpServlet.service(HttpServlet.java:527)
at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:885)
at jakarta.servlet.http.HttpServlet.service(HttpServlet.java:614)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1260)
at [internal classes]
at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:51)
at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:203)
at [internal classes]
at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:100)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116)
at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:203)
at [internal classes]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:101)
at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:203)
at [internal classes]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:101)
at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:203)
at [internal classes]
at org.springframework.boot.web.servlet.support.ErrorPageFilter.forwardToErrorPage(ErrorPageFilter.java:189)
at org.springframework.boot.web.servlet.support.ErrorPageFilter.handleException(ErrorPageFilter.java:174)
at org.springframework.boot.web.servlet.support.ErrorPageFilter.doFilter(ErrorPageFilter.java:141)
at org.springframework.boot.web.servlet.support.ErrorPageFilter$1.doFilterInternal(ErrorPageFilter.java:99)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116)
at org.springframework.boot.web.servlet.support.ErrorPageFilter.doFilter(ErrorPageFilter.java:117)
at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:203)
at [internal classes]
at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116)
at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:203)
at [internal classes]
Caused by: java.lang.IllegalArgumentException: Cannot build an application for a request which servlet context does not match with the application that it is being built for.
at org.thymeleaf.util.Validate.isTrue(Validate.java:79)
at org.thymeleaf.web.servlet.JakartaServletWebApplication.buildExchange(JakartaServletWebApplication.java:64)
at org.thymeleaf.spring6.view.ThymeleafView.renderFragment(ThymeleafView.java:204)
at org.thymeleaf.spring6.view.ThymeleafView.render(ThymeleafView.java:192)
at org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:1431)
at org.springframework.web.servlet.DispatcherServlet.processDispatchResult(DispatcherServlet.java:1167)
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1106)
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:979)
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1014)
... 31 more

Reported in thymeleaf/thymeleaf#990.

spring-petclinic's People

Contributors

arey avatar snicoll avatar dsyer avatar verydapeng avatar cyrille-leclerc avatar gordonad avatar crydust avatar oscr avatar tduchateau avatar trepel avatar patbaumgartner avatar trisberg avatar sdeleuze avatar boykoalex avatar win777 avatar bijomutta avatar odrotbohm avatar jdubois avatar freemansoft avatar eskibear avatar xerx593 avatar liouxiao avatar doggy8088 avatar tgrall avatar spring-operator avatar rstoyanchev avatar roxspring avatar martinlippert avatar cruftex avatar nroi avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.