-
Notifications
You must be signed in to change notification settings - Fork 40.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
spring boot jsp 404 Whitelabel Error Page with 1.5.0 #14493
Comments
Given this description, I don't understand the issue here. Thanks! |
spring boot 1.4.0 + jsp, the jar of package is ok ,but spring boot 1.5.10, it is error with Whitelabel Error Page. |
Both of them could go into the method of controller, but it is error with Whitelabel Error Page in spring boot 1.5.10. So, i found that it is different between 1.4.0 and 1.5.10 in org.apache.jasper.servlet.JspServlet . |
I build that it is a package of jar package ,not a war. And i use the command of 'java -jar ....' |
We do not support JSPs with jar packaging. If you want to use JSPs you must use war packaging. Given that it's not clear that this is a bug in Spring Boot, I'm going to close this one. If it doesn't work with war packaging, please provide a sample that reproduces the problem and we can re-open the issue. |
why is it ok with spring boot 1.4.0? |
this is a simple example. I add the node in the pom :
it is ok with spring boot 1.4.0. |
I want to know the reason for that, please help me! Thanks a lot! |
@wilkinsona I add the zip of the example. please help me, thanks a lot! |
Your sample is using jar packaging which is not supported. If it's working, it's only doing so by accident. Unfortunately, I can't afford to spend time figuring out why it appears to work in your case for two reasons.
The 1.4.0 reference documentation already state that you should use war packaging if you want to use JSPs: https://docs.spring.io/spring-boot/docs/1.4.0.RELEASE/reference/htmlsingle/#boot-features-jsp-limitations. This recommendation still stands with 1.5.x and 2.0.x which are the two currently supported versions. |
@wilkinsona I'm so sorry for troubling you. but 1.4.0, it is ok with jar packaging. |
spring boot 1.4.0.RELEASE: Realpath=null, it is ok
spring boot 1.5.10.RELEASE:Realpath=/private/var/folder/....
the path is not found in my OS, so that it is 404 with Whitelabel Error Page
However, how i could solve this problem?
The text was updated successfully, but these errors were encountered: