Spring boot JSP error: NoClassDefFoundError

前端 未结 3 1555
迷失自我
迷失自我 2021-02-08 13:30

Everytime I try to run spring boot app configured with JSP I get this error:

java.lang.NoClassDefFoundError: javax/servlet/ServletContext
    at java.lang.Class.         


        
3条回答
  •  说谎
    说谎 (楼主)
    2021-02-08 13:55

    I found a better workaround for this bug.

    If you run your project using command line directly, you will lose the debug function provided by IDE. You can click the Maven Project tab, find the spring-boot:run goal, right click then select debug XXXX. By using this way you can get full debug feature that your IDE gives.

提交回复
热议问题