简体   繁体   中英

Grails Webflow2.0.0 error

I am using Grails 2.0.0 and I tried to download webflow 2.0.0 but I am getting only webflow 2.0.0-RELEASE as a zip folder or as a jar file.Are both webflow 2.0.0 and webflow 2.0.0-RELEASE the same?

I even got grails-webflow-2.0.3 jar file also. I also tried with webflow 1.3.8 which I got from grails official website. I tried changing the name of the plugin in the compile statement in Build.Config each time and ran and am ending up with this kind error each time :

Error WARNING: Specified dependency definition compile(:org.springframework.webflow-2.0.0.RELEASE) is invalid! Skipping..

what shall i do?

Given below is my BuildConfig.groovy file :

grails.servlet.version = "2.5" // Change depending on target container 
compliance (2.5 or 3.0)
grails.project.class.dir = "target/classes"
grails.project.test.class.dir = "target/test-classes"
grails.project.test.reports.dir = "target/test-reports"
grails.project.target.level = 1.6
grails.project.source.level = 1.6
//grails.project.war.file = "target/${appName}-${appVersion}.war"
grails.project.dependency.resolution = {
// inherit Grails' default dependencies
inherits("global") {
    // uncomment to disable ehcache
    // excludes 'ehcache'
}
log "warn" // log level of Ivy resolver, either 'error', 'warn', 'info', 
'debug' or 'verbose'
checksums true // Whether to verify checksums on resolve
repositories {
inherits true // Whether to inherit repository definitions from 
plugins
    grailsPlugins()
    grailsHome()
    grailsCentral()
    mavenCentral()
    // uncomment these to enable remote dependency resolution 
from public Maven repositories
    mavenCentral()
    mavenRepo 
"http://repository.springsource.com/maven/bundles/release"
    mavenRepo 
"http://repository.springsource.com/maven/bundles/external"
    mavenRepo 
"http://repository.springsource.com/maven/libraries/release"
    mavenRepo 
"http://repository.springsource.com/maven/libraries/external"
    mavenLocal()
    mavenRepo "http://snapshots.repository.codehaus.org"
    mavenRepo "http://repository.codehaus.org"
    mavenRepo "http://download.java.net/maven/2/"
    mavenRepo "http://repository.jboss.com/maven2/"
}
dependencies {
    // specify dependencies here under either 'build', 'compile', 
'runtime', 'test' or 'provided' scopes eg.
    // runtime 'mysql:mysql-connector-java:5.1.16'
}
plugins {
    runtime ":hibernate:$grailsVersion"
    runtime ":jquery:1.7.1"
    runtime ":resources:1.1.5"
   compile ":webflow:2.0.0"
 // compile ":spring-security-core:1.2.7.3"
    build ":tomcat:$grailsVersion"
}
}

The right way to add webflow is to put the dependecy in BuildConfig.groovy

 ...
 plugins { 
     ...
     compile ":webflow:2.0.0"
     ...
 }
 ...

Don't download or add it manually

Or try replace your repositories with this

repositories {
        inherits true
        grailsPlugins()
        grailsHome()
        grailsCentral()
        mavenLocal()
        mavenCentral()
        mavenRepo name: "Grails Snapshots", root:"http://snapshots.repository.codehaus.org/"
        mavenRepo name: "Spring Milestone", root:"http://maven.springframework.org/milestone/"
        mavenRepo name: "Spring Milestone", root:"http://maven.springframework.org/milestone/"
        ebr()       
        mavenRepo "http://repository.codehaus.org"
        mavenRepo "http://download.java.net/maven/2/"
        mavenRepo "http://repository.jboss.com/maven2/"
        mavenRepo "http://repository.springsource.com/maven/bundles/release"
        mavenRepo "http://repository.springsource.com/maven/bundles/external"
        mavenRepo "http://repository.springsource.com/maven/libraries/release"
        mavenRepo "http://repository.springsource.com/maven/libraries/external"
    }

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM