3
我的gradle构建像这样春天启动的JSP没有得到呈现
buildscript {
repositories {
maven { url "http://repo.spring.io/libs-milestone" }
mavenLocal()
}
dependencies {
classpath("org.springframework.boot:spring-boot-gradle-plugin:1.0.0.RC5")
}
}
configurations {
jasper
}
apply plugin: 'java'
apply plugin: 'eclipse'
apply plugin: 'idea'
apply plugin: 'spring-boot'
apply plugin: 'war'
war {
baseName = 'foo-serving-web-content'
version = '0.1.1'
}
repositories {
mavenCentral()
maven { url "http://repo.spring.io/libs-milestone" }
}
dependencies {
compile("org.springframework:spring-webmvc:4.0.0.M2")
compile("org.springframework.boot:spring-boot-starter-web")
compile("javax.servlet:javax.servlet-api:3.1.0")
compile("javax.servlet:jstl:1.1.2")
testCompile("junit:junit")
}
task wrapper(type: Wrapper) {
gradleVersion = '1.11'
}
现在就是我的JSP没有得到渲染,只是普通的个XML。 我发现这篇文章有人有问题,但他们正在使用maven。
JSP file not rendering in Spring Boot web application
是有什么错我的build.gradle?
我的build.gradle看起来像现在这样 http://pastie.org/8982991 现在越来越 “HTTP状态500 - 绝对ü ri:http://java.sun.com/jsp/jstl/core无法在web.xml或使用此应用程序部署的jar文件中解析“ –
我认为我们不支持servlet 3.1,而您的jstl看起来很老。在没有显式版本的情况下尝试这些依赖关系,并让Boot插件为您解决它们。 –
谢谢戴夫,它工作得很好。 –