我已将Grails 2.2中的小应用程序升级到Grails 3.2.3。在解决编译问题之后,一切看起来都没问题,但是bootRun失败并且没有明显的线索原因。
我的buildscript {
repositories {
maven { url "https://repo.grails.org/grails/core" }
maven { url "http://repository.jboss.com/maven2/" }
maven { url "http://repo1.maven.org/maven2/" }
maven { url "http://repo.spring.io/milestone/" }
}
dependencies {
classpath "org.grails:grails-gradle-plugin:$grailsVersion"
classpath "com.bertramlabs.plugins:asset-pipeline-gradle:2.11.6"
classpath "org.grails.plugins:hibernate5:6.0.4"
}
}
version "0.1"
group "testmonitor"
apply plugin:"eclipse"
apply plugin:"idea"
apply plugin:"war"
apply plugin:"org.grails.grails-web"
apply plugin:"org.grails.grails-gsp"
apply plugin:"asset-pipeline"
repositories {
mavenLocal()
maven { url "https://repo.grails.org/grails/core" }
maven { url "http://repository.jboss.com/maven2/" }
maven { url "http://repo1.maven.org/maven2/" }
maven { url "http://repo.spring.io/milestone/" }
}
dependencyManagement {
imports {
mavenBom "org.grails:grails-bom:$grailsVersion"
}
applyMavenExclusions false
}
dependencies {
compile "org.springframework.boot:spring-boot-starter-logging"
compile "org.springframework.boot:spring-boot-autoconfigure"
compile "org.grails:grails-core"
compile "org.springframework.boot:spring-boot-starter-actuator"
compile "org.springframework.boot:spring-boot-starter-tomcat"
compile "org.grails:grails-dependencies"
compile "org.grails:grails-web-boot"
compile "org.grails.plugins:cache"
compile "org.grails.plugins:hibernate5"
compile "org.hibernate:hibernate-core:5.1.2.Final"
compile "org.hibernate:hibernate-ehcache:5.1.2.Final"
compile 'org.grails.plugins:spring-security-core:3.1.1'
compile "org.grails.plugins:quartz:2.0.1"
compile 'org.grails:grails-datastore-rest-client'
profile "org.grails.profiles:web"
runtime "com.bertramlabs.plugins:asset-pipeline-grails:2.11.6"
runtime "com.h2database:h2"
compile 'org.apache.commons:commons-math3:3.6.1'
compile group: 'org.codehaus.groovy.modules.http-builder', name: 'http-builder', version: '0.7.1'
compile 'net.sf.opencsv:opencsv:2.3'
console "org.grails:grails-console"
runtime "com.bertramlabs.plugins:asset-pipeline-grails:2.11.6"
runtime 'mysql:mysql-connector-java:5.1.29'
testCompile "org.grails:grails-plugin-testing"
testCompile "org.grails.plugins:geb"
testRuntime "org.seleniumhq.selenium:selenium-htmlunit-driver:2.47.1"
testRuntime "net.sourceforge.htmlunit:htmlunit:2.18"
}
bootRun {
jvmArgs = ['-Dspring.output.ansi.enabled=always']
}
assets {
minifyJs = true
minifyCss = true
}
:
gradle --debug
可以下载{{1}}的日志(无法在此处查看任何问题)from Sharepoint。
我使用IntelliJ IDEA 2016.3,当我运行grails run-app时,我得到了相同的结果。我找不到log / info grails命令的任何选项。 [运行grails run-app] [1]
更新:现在grails run-app似乎没问题,但是返回了htpp 404。
答案 0 :(得分:0)
您也需要清除旧gradle缓存。请点击以下链接。我得到了几乎相同的错误。 https://stackoverflow.com/a/39462689/3711185