AlexLeung
AlexLeung

Reputation: 117

Grails 3.1 and spring-security-core:3.0.3

When I try to use

grails s2-quickstart com.kanabang secUser secRole

it show the following in the console.

Error |
Error occurred running Grails CLI: Failed to parse template script (your template may contain an error or be trying to use expressions not currently supported): startup failed:
GStringTemplateScript1.groovy: -1: unable to resolve class org.springframework.beans.factory.annotation.Autowired
 @ line -1, column -1.
1 error

cannot create the bean.

my dependencies

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"

    compile 'org.grails.plugins:spring-security-core:3.0.3'
    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"
}

Is it a bug or wrong config.?

note that:I am using intellij 15.

Upvotes: 2

Views: 291

Answers (1)

AlexLeung
AlexLeung

Reputation: 117

after some testing.

I try to use mingw64 to build the application.

It is successfully create the domain classes.

Before doing this. i need to add the grails_home in the path.

I thank this is the key point.

Upvotes: 1

Related Questions