grails-spring-batch
grails-spring-batch copied to clipboard
Compilation error (Grails 2.5 compatibility )
Hi,
I have a compilation at startup. I added the following in BuildConfig.groovy file: * compile ':spring-batch:2.0.0'* Then, when I start My Grails Application ( 2.5.0 ), I have the following error :
"C:\Program Files\Java\jdk1.7.0_51\bin\java" -Dvisualvm.id=28765075634478 -Dgrails.home=E:\logiciels\grails-2.5.0\grails-2.5.0 -Dbase.dir=E:\projet\toolprod\fichiers_install\toolprod "-Dtools.jar=C:\Program Files\Java\jdk1.7.0_51\lib\tools.jar" -Dgroovy.starter.conf=E:\logiciels\grails-2.5.0\grails-2.5.0/conf/groovy-starter.conf -Xmx768M -Xms768M -XX:MaxPermSize=256m -XX:PermSize=256m -Djline.WindowsTerminal.directConsole=false -Didea.launcher.port=7535 "-Didea.launcher.bin.path=C:\Program Files (x86)\JetBrains\IntelliJ IDEA 12.1.7\bin" -Dfile.encoding=UTF-8 -classpath "E:\logiciels\grails-2.5.0\grails-2.5.0\lib\org.codehaus.groovy\groovy-all\jars\groovy-all-2.4.3.jar;E:\logiciels\grails-2.5.0\grails-2.5.0\dist\grails-bootstrap-2.5.0.jar;C:\Program Files (x86)\JetBrains\IntelliJ IDEA 12.1.7\lib\idea_rt.jar" com.intellij.rt.execution.application.AppMain org.codehaus.groovy.grails.cli.support.GrailsStarter --main org.codehaus.groovy.grails.cli.GrailsScriptRunner --conf E:\logiciels\grails-2.5.0\grails-2.5.0/conf/groovy-starter.conf run-app
|Loading Grails 2.5.0
|Configuring classpath
.
|Environment set to development
.................................
|Packaging Grails application
|Installing zip spring-batch-2.0.0.zip...
...
|Installed plugin spring-batch-2.0.0
...............
|Installing zip platform-core-1.0.RC6.zip...
...
|Installed plugin platform-core-1.0.RC6
Note: E:\projet\toolprod\fichiers_install\toolprod\target\work\plugins\scaffolding-2.1.2\src\java\org\codehaus\groovy\grails\scaffolding\AbstractGrailsTemplateGenerator.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
[groovyc] org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed:
[groovyc] E:\projet\toolprod\fichiers_install\toolprod\target\work\plugins\spring-batch-2.0.0\grails-app\services\grails\plugins\springbatch\SpringBatchService.groovy: 248: Method 'onApplicationEvent' from class 'grails.plugins.springbatch.SpringBatchService' does not override method from its superclass or interfaces but is annotated with @Override.
[groovyc] @ line 248, column 2.
[groovyc] @Override
[groovyc] ^
[groovyc]
[groovyc] 1 error
.Error
|
Compilation error: startup failed:
E:\projet\toolprod\fichiers_install\toolprod\target\work\plugins\spring-batch-2.0.0\grails-app\services\grails\plugins\springbatch\SpringBatchService.groovy: 248: Method 'onApplicationEvent' from class 'grails.plugins.springbatch.SpringBatchService' does not override method from its superclass or interfaces but is annotated with @Override.
@ line 248, column 2.
@Override
^
1 error
Any idea ?
The issue is due to the version of Grails you are using. Using the master branch of this plugin should get the application to compile, but I don't know how much is functional. I use the plugin with Grails 2.2.4 primarily.
Thanks for your answer. Are they plan for use it whith Grails 2.5.0 ?
I don't have a timeline for that at the moment.
FYI, I have this working in production for Grails 2.5.5. The project seems fairly dead so maybe you could make me a contributor and I can continue to maintain for now?
I don't have permissions to add anybody, but, if you submit a pull request, I'll approve it.
I'm using Grails 2.4.4 Version and getting the same error
@longwa I have seen that you have commited changes which should make plugin work with Grails > 2.5 Could you create a new release, please?