Hi, I get out of memory error when I run jibx binding for more number of classes. I have set gradle jvm arge to high value -Xmx1024m.
But since I am executing the jibx bind as an ant task ( i presume this works similar to javaexec task ) , would it possible to specify memory arguments to the ant task seperately ?
project.ant works in-process so in order to get it more memory you need to set more memory to Gradle (for example, via gradle.properties file and org.gradle.jvmargs=…)
If you want to execute ant process in a forked mode I think that the only reasonable solution is an exec task that calls out to ‘ant’.
There is no flag for running any ant task from gradle in forked mode and the binding compiler does not support running in forked mode I think. I would suggest to use an gradle JavaExec task to run the binding compiler. This can look like this:
task compileBindings(type: JavaExec){
classpath = path/to/jibx-bind.jar
main = "org.jibx.binding.Compile"
arguments "/path/to/your/binding.xml"
maxHeapSize = "1024m" // adjust as necessary
}