Gradle giving ClassNotFoundException while building Grails project -
i trying use gradle-grails-plugin build existing (small) grails project. should work? relationship between dependencies in build.gradle , ones specified in buildconfig.groovy?
in event, have 2 projects, topmost build.gradle file in parent directory , looks like:
buildscript { repositories { jcenter() } dependencies { classpath "org.grails:grails-gradle-plugin:2.2.0.rc1" } } task wrapper(type: wrapper) { gradleversion = '2.3' } and build.gradle in grails project looks like:
apply plugin: "grails" repositories { grails.central() //creates maven repo grails central repository (core libraries , plugins) } grails { grailsversion = '2.4.4' groovyversion = '2.3.9' springloadedversion '1.2.0.release' } dependencies { bootstrap "org.grails.plugins:tomcat:7.0.55.3" compile 'org.grails.plugins:asset-pipeline:3.0.1' compile 'org.grails.plugins:scaffolding:2.1.2' compile 'org.grails.plugins:cache:1.1.8' runtime 'org.grails.plugins:hibernate4:4.3.1.1' runtime 'org.grails.plugins:database-migration:1.3.8' runtime 'org.grails.plugins:jquery:1.11.0' } however, when run ./gradlew war, back:
caused by: java.long.classnotfoundexception: grails.artefact.service can shed light on this? there practically no references via google, seems grails 3.x class? also, using java 1.7.
class grails.artefact.service indeed accessible v3.0 of grails framework - can seen here.
with following statement grailsversion = '2.4.4' v2.4.4 specified used , looks ok. spoils build following dependencies entry:
compile 'org.grails.plugins:asset-pipeline:3.0.1' in package there class asset/pipeline/grails/assetprocessorservice imports mentioned grails.artefact.service isn't loaded @ runtime (probably because of v2.4.4 used).
unfortunately can't suggest solution apart trivial excluding dependency. not grails developer nor have set environment up.
hopes helps somehow.
Comments
Post a Comment