Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/java/346.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
任务';的执行失败:compileGroovy';。javax/persistence/Entity_Java_Groovy_Grails 3.0_Intellij 15 - Fatal编程技术网

任务';的执行失败:compileGroovy';。javax/persistence/Entity

任务';的执行失败:compileGroovy';。javax/persistence/Entity,java,groovy,grails-3.0,intellij-15,Java,Groovy,Grails 3.0,Intellij 15,这是我的身材,格雷德尔 buildscript { ext { grailsVersion = project.grailsVersion } repositories { mavenLocal() maven { url "https://repo.grails.org/grails/core" } } dependencies { classpath "org.grails

这是我的身材,格雷德尔

buildscript {
    ext {
        grailsVersion = project.grailsVersion
    }
    repositories {
        mavenLocal()
        maven { url "https://repo.grails.org/grails/core" }
    }
    dependencies {        
        classpath "org.grails:grails-gradle-plugin:$grailsVersion"
        classpath 'com.bertramlabs.plugins:asset-pipeline-gradle:2.5.0'
        classpath "org.grails.plugins:hibernate:4.3.10.5"

    }
}

plugins {
    id "io.spring.dependency-management" version "0.5.2.RELEASE"

}

version "0.1"
group "testapp"

apply plugin: "spring-boot"
apply plugin: "war"
apply plugin: "asset-pipeline"
apply plugin: 'eclipse'
apply plugin: 'idea'
apply plugin: "org.grails.grails-web"
apply plugin: "org.grails.grails-gsp"

ext {
    grailsVersion = project.grailsVersion
    gradleWrapperVersion = project.gradleWrapperVersion
}

assets {
    minifyJs = true
    minifyCss = true
}

repositories {
    mavenLocal()
    maven { url "https://repo.grails.org/grails/core" }
}

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-starter-actuator"
    compile "org.springframework.boot:spring-boot-autoconfigure"
    compile "org.springframework.boot:spring-boot-starter-tomcat"
    compile "org.grails:grails-dependencies"
    compile "org.grails:grails-web-boot"

    compile "org.grails.plugins:hibernate"
    compile "org.grails.plugins:cache"
    compile "org.hibernate:hibernate-ehcache"
    compile "org.grails.plugins:scaffolding"






    runtime "org.grails.plugins:asset-pipeline"

    testCompile "org.grails:grails-plugin-testing"
    testCompile "org.grails.plugins:geb"

    // Note: It is recommended to update to a more robust driver (Chrome, Firefox etc.)
    testRuntime 'org.seleniumhq.selenium:selenium-htmlunit-driver:2.44.0'

    console "org.grails:grails-console"
}

task wrapper(type: Wrapper) {
    gradleVersion = gradleWrapperVersion
}
grails运行应用程序后出现以下错误

失败:生成失败,出现异常

  • 出了什么问题: 任务“:compileGroovy”的执行失败

    javax/persistence/Entity

  • 尝试: 使用--stacktrace选项运行以获取堆栈跟踪。使用--info或--debug运行 选项以获取更多日志输出。 |启动服务器时出错(使用--stacktrace查看完整跟踪)


什么版本的grails、groovy和JDK?您是否尝试了一个
grails clean
,然后又尝试了
grails运行app
?jdk-8u65,grails-3.1.0.RC1,intelijIdea-15。我尝试过命令行和intelijIdea,它们都是相同的错误“classnotfoundexceptionjavax/persistence/Entity”Grails版本:3.1.0.RC1 Groovy版本:2.4.5 JVM版本:1.8.066