Reputation: 253
I Cant able to create Grails Application In Netbeans IDE, My IDE show me to create new Grails Application and when i click create Button It Shows Error In Console.
JAVA VERSION : 1.6
GRAILS VERSION : 2.3.7
IDE : NetBeans
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.codehaus.groovy.grails.cli.support.GrailsStarter.rootLoader(GrailsStarter.java:235)
at org.codehaus.groovy.grails.cli.support.GrailsStarter.main(GrailsStarter.java:263)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.codehaus.groovy.grails.cli.support.GrailsStarter.rootLoader(GrailsStarter.java:235)
at org.codehaus.groovy.grails.cli.support.GrailsStarter.main(GrailsStarter.java:263)
Caused by: java.lang.NoClassDefFoundError: jline/console/completer/CompletionHandler at org.codehaus.groovy.grails.cli.GrailsScriptRunner.main(GrailsScriptRunner.java:129) ... 12 more Caused by: java.lang.ClassNotFoundException: jline.console.completer.CompletionHandler at org.codehaus.groovy.tools.RootLoader.findClass(RootLoader.java:175) at java.lang.ClassLoader.loadClass(ClassLoader.java:425) at org.codehaus.groovy.tools.RootLoader.loadClass(RootLoader.java:147) at org.codehaus.groovy.grails.cli.support.GrailsRootLoader.loadClass(GrailsRootLoader.java:51) at java.lang.ClassLoader.loadClass(ClassLoader.java:358) ... 13 more
Upvotes: 0
Views: 219
Reputation: 1379
First I would recommend checking your Java version.
Although the minimum requirements for Grails framework 2.3.7 is java 1.6 as you can see in the Grails introduction web site:
Here is the main paragraph describes it:
Before installing Grails you will need as a minimum a Java Development Kit (JDK) installed version 1.6 or above. Download the appropriate JDK for your operating system, run the installer, and then set up an environment variable called JAVA_HOME pointing to the location of this installation.
I would suggest using more advance version of JAVA such as 1.7 or 1.8. Especially the 1.8 which offers vast majority of changes and improvements from the older JAVA versions.
Another thing that should be checked is your JAVA_HOME (Environment variable) value. Are you sure it points to the relevant JAVA JDK ? if not that can be a good reason to the error you have.
Personally I am using Intellij IDEA (JetBrains IDE) and it works great with the Grails Framework using the Gradle building tool.
Upvotes: 2