Incompatible JVM in GGTS (Eclipse) and JAVA 1.8

前端 未结 10 2317
说谎
说谎 2020-11-27 18:48

Having some problem with running a grails application in GGTS (eclipse) due to upgrade to Java 1.8.

The stack starts with:

Mar 05, 2015 3:51:31 PM          


        
相关标签:
10条回答
  • 2020-11-27 19:15

    From https://github.com/spring-projects/spring-loaded/issues/98 and worked to me

    wget repo.spring.io/libs-snapshot-local/org/springframework/springloaded/1.2.3.BUILD-SNAPSHOT/springloaded-1.2.3.BUILD-SNAPSHOT.jar -O ~/.gvm/grails/2.4.4/lib/org.springframework/springloaded/jars/springloaded-1.2.1.RELEASE.jar

    0 讨论(0)
  • 2020-11-27 19:20

    Root cause, work-arounds and news on fixes here: https://github.com/spring-projects/spring-loaded/issues/98

    0 讨论(0)
  • 2020-11-27 19:20

    I am running Grails 2.4.3 and also had problems moving from jdk1.8.0_31 to jdk1.8.0_40 and had to go back to jdk1.8.0_31

    Loading Grails 2.4.3
    ...
    SEVERE: Problems copying method. Incompatible JVM?
    java.lang.reflect.InvocationTargetException
    ...
    Caused by: java.lang.IllegalArgumentException: Can not copy a non-root Method
    at java.lang.reflect.Method.copy(Method.java:151)
    
    0 讨论(0)
  • 2020-11-27 19:21

    I updated my springloaded jar to version 1.2.4.BUILD-SNAPSHOT (from 1.2.1) and that resolved the issue. (Latest version can be found in the Spring repo)

    1. Go to your local Grails lib directory to find springloaded jar. For me that was /usr/local/Cellar/grails/2.4.4/libexec/lib/org.springframework/springloaded/jars/
    2. remove existing 1.2.1 jars (I removed pom file, too, but not necessary)
    3. download latest springloaded jar and place into the jars subdir: wget http://repo.spring.io/libs-snapshot-local/org/springframework/springloaded/1.2.4.BUILD-SNAPSHOT/springloaded-1.2.4.BUILD-SNAPSHOT.jar

    After doing that, everything works. (Clues used from previous answer: https://github.com/spring-projects/spring-loaded/issues/98)

    0 讨论(0)
  • 2020-11-27 19:21

    Step 1 : Download this jar

    step 2 : put it into the grails folder: grails-2.4.1/lib/org.springframework/springloaded/jars

    should be enough , restart IDE

    0 讨论(0)
  • 2020-11-27 19:23

    Two Step To Make it Work

    1. Download JDK Lower Version: Install jdk1.8.0_25 from link http://www.oracle.com/technetwork/java/javase/downloads/java-archive-javase8-2177648.html#jdk-8u25-oth-JPR. It's the lower version of JDK as grails dont support higher version. Maybe They'll include this in latest version soon.

    2. Set Up Environment Variables: Don't forget to change the Enviromental variables for jdk, you have to just edit Path Variables and JavaHome Variable from "C:\Program Files\Java\jdk1.8.0_'LatestVersion'" to "C:\Program Files\Java\jdk1.8.0_25" .

    0 讨论(0)
提交回复
热议问题