Grails 3.x更新-bootRun失败 [英] Grails 3.x update - bootRun failed

查看:75
本文介绍了Grails 3.x更新-bootRun失败的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经将小型应用程序从Grails 2.2升级到了Grails 3.2.3.解决编译问题后,一切看起来都很好,但是bootRun失败了,没有明显的原因.

I have upgraded small application from Grails 2.2 to Grails 3.2.3. After resolving compilation issues everything looks OK, but bootRun is failing and there is no obvious clue why.

我的build.gradle:

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的日志(不能在此处看到任何问题)可以下载

A log with gradle --debug (cant see any issue here) can be downloaded from Sharepoint.

我使用IntelliJ IDEA 2016.3,当我运行grails run-app时,我得到的结果是相同的.我找不到任何记录log/info grails命令的选项. [运行grails run-app] [1]

I use IntelliJ IDEA 2016.3, when I run grails run-app I am getting the same result. I can not find any option to log/info grails command. [running grails run-app][1]

更新:现在 grails运行应用程序似乎可以,但返回htpp 404

UPDATE: now grails run-app seems OK, but htpp 404 is returned.

推荐答案

,您还需要清除旧的gradle缓存.请点击以下链接.我遇到了几乎相同的错误. https://stackoverflow.com/a/39462689/3711185

you need to clear the old gradle cache too. follow the below link. I was getting almost same errors. https://stackoverflow.com/a/39462689/3711185

这篇关于Grails 3.x更新-bootRun失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆