Grails 2.5.4 Error occurred during initialization of VM - java

I'm trying to run an application in Grails but I have a problem with the execution. I'm using grails version 2.5.4 and Java version 1.7.
I checked my enviroment variables and they turned out to be OK.
This is the error:
Error occurred during initialization of VM agent library failed to init: instrument.
Error opening zip file or JAR manifest missing : C:\Program%20Files\Grails\grails-2.5.4\lib\org.springframework\springloaded\jars\springloaded-1.2.4.RELEASE.jar
Error | Forked Grails VM exited with error
What's going on?

Related

Getting error called Could not compile settings file of (settings.gradle) while running (ionic cordova build android)

I am using Angular and Ionic to create hybrid application.
Gradle 7.4.2
Java: java 17.0.2 2022-01-18 LTS
Ionic: 5.0.0
Angular CLI: 13.2.4
Node: 16.14.0
Package Manager: npm 8.3.1
OS: win32 x64
Here is the console snippet for better understanding.
Checking Java JDK and Android SDK versions
ANDROID_SDK_ROOT=C:\SDK (recommended setting)
ANDROID_HOME=C:\SDK (DEPRECATED)
Using Android SDK: C:\SDK
Subproject Path: CordovaLib
Subproject Path: app
Starting a Gradle Daemon, 1 incompatible and 1 stopped Daemons could not be reused, use --status for details
FAILURE: Build failed with an exception.
Where:
Settings file 'C:\Users\Alok Sarkar\Desktop\WBMDMS\WBMDMS\platforms\android\settings.gradle'
What went wrong:
Could not compile settings file 'C:\Users\Alok Sarkar\Desktop\WBMDMS\WBMDMS\platforms\android\settings.gradle'.
startup failed:
General error during conversion: Unsupported class file major version 61
java.lang.IllegalArgumentException: Unsupported class file major version 61
at groovyjarjarasm.asm.ClassReader.(ClassReader.java:189)
[ERROR] An error occurred while running subprocess cordova.
cordova.cmd build android exited with exit code 1.

Heroku deploy fails

I'm using Play framework with Java 1.7.
Last time deploy:
-----> Play! app detected
-----> Installing OpenJDK 1.7... done
-----> Building Play! application...
This time deploy:
-----> Play! app detected
/app/tmp/buildpacks/85dfc1d8f48aec0b42f03a59461dc516a918eb099c9e908767a7f42ddf326e12e48c6030ff4891e5c63f08e3b760ea09dee5bbfa4ca293b152d266406bfa29b3/bin/compile:
line 31: detect_java_version: command not found
-----> Installing OpenJDK .../app/tmp/buildpacks/85dfc1d8f48aec0b42f03a59461dc516a918eb099c9e908767a7f42ddf326e12e48c6030ff4891e5c63f08e3b760ea09dee5bbfa4ca293b152d266406bfa29b3/bin/compile:
line 34: jdk_overlay: command not found
-----> Building Play! application...
So after error log
OpenJDK 64-Bit Server VM warning: ignoring option UseSplitVerifier;
support was removed in 8.0
CompilerOracle: exclude jregex/Pretokenizer.next
Listening for transport dt_socket at address: 8000
08:52:08,455 INFO ~ Starting /tmp/build_bedf10ee7c8222565973235fe2454700
08:52:10,049 INFO ~ Precompiling ...
08:53:02,606 ERROR ~
#7e83895fc
Cannot start in PROD mode with errors
Oops: UnexpectedException
An unexpected error occured caused by exception UnexpectedException: While applying class
play.classloading.enhancers.LocalvariablesNamesEnhancer on
controllers.Application
play.exceptions.UnexpectedException: While applying play.CorePlugin#aecb35a on controllers.Application
at play.plugins.PluginCollection.enhance(PluginCollection.java:556)
at play.classloading.ApplicationClasses$ApplicationClass.enhance(ApplicationClasses.java:235)
at play.classloading.ApplicationClassloader.loadApplicationClass(ApplicationClassloader.java:167)
at play.classloading.ApplicationClassloader.getAllClasses(ApplicationClassloader.java:431)
at play.Play.preCompile(Play.java:600)
at play.Play.init(Play.java:304)
at play.server.Server.main(Server.java:162)
Caused by: play.exceptions.UnexpectedException: While applying class play.classloading.enhancers.LocalvariablesNamesEnhancer
on controllers.Application
at play.CorePlugin.enhance(CorePlugin.java:302)
at play.plugins.PluginCollection.enhance(PluginCollection.java:551)
... 6 more
Caused by: java.lang.RuntimeException: java.io.IOException: invalid constant type: 18
at javassist.CtClassType.getClassFile2(CtClassType.java:203)
at javassist.CtClassType.subtypeOf(CtClassType.java:303)
at javassist.bytecode.stackmap.TypeData$TypeName.update(TypeData.java:274)
at javassist.bytecode.stackmap.TypeData$TypeName.setType(TypeData.java:203)
at javassist.bytecode.stackmap.TypeData.setType(TypeData.java:46)
at javassist.bytecode.stackmap.Tracer.doInvokeIntfMethod(Tracer.java:828)
at ja
-----> Play! app detected
How to fix it?
First of all, please note that Heroku no longer supports Play 1.x. If you can, please consider upgrading your application to Play 2.x, which is still supported.
However, the issue you describe has now been fixed. A dependency of the now deprecated Play 1.x buildpack broke backwards compatibility. Redeploying your application should work without any work from your side.

gradle bootRun works and java -jar does not

I've a "spring boot app" application.
I'm executing my software with "gradle bootRun" and It works correctly for all developers.
To make the jar or war I've used maven and currently I'm using gradle.
With both methods to generated jar or war the execution of software from this artifacts isn't working propertly in one of hundreds of use cases.
The error is:
Error: Error while starting plugin CheckGebaeudeVersicherungsSystemIoxPlugin
Error: ch/interlis/iox_j/validator/InterlisFunction
Error: ch.interlis.iox_j.validator.InterlisFunction
Error: Error while starting plugin org.interlis2.validator.plugins.IntersectsIoxPlugin
Error: ch/interlis/iox_j/validator/InterlisFunction
Error: ch.interlis.iox_j.validator.InterlisFunction
Error: Error while starting plugin org.interlis2.validator.plugins.no_overlaps_2_1_6_IoxPlugin
Error: ch/interlis/iox_j/validator/InterlisFunction
Error: ch.interlis.iox_j.validator.InterlisFunction
Error: Error while starting plugin org.interlis2.validator.plugins.no_overlaps_2_2_0_IoxPlugin
Error: ch/interlis/iox_j/validator/InterlisFunction
Error: ch.interlis.iox_j.validator.InterlisFunction
This seems to be an error of a missing dependency.
This error is not because of something on the code. In eclipse with execution and debug, all is working properly!
What's the difference in execute between "gradle bootRun"/"mvn spring-boot:run" and the execution with java commad (traditional "java -jar jar/war")?

How can I view SonarQube Web browser, Rule description and Issue Editor in Eclipse

I am using Ubuntu 14.04 lts, Os type 32-bit, SonarQube 4.5.2, Sonar-runner 2.4, java version "1.7.0_65", Eclipse Kepler.
While Analyzing SonarQube in Eclipse It shows the following Issue:
SonarQube Analysis has encountered a problem
Error during Execution of Sonar
Error during execution of Sonar
Error status [command: /usr/lib/jvm/java-7-openjdk-i386/jre/bin/java -cp /tmp/sonar-runner-impl8404187497975734722.jar org.sonar.runner.impl.BatchLauncherMain /tmp/sonar-project6286406354288770628.properties]: 1
Retrieve remote issues of project SonarTest...
Start SonarQube analysis on SonarTest...
INFO: SonarQube Server 4.5.2
Exception in thread "main" java.lang.IllegalStateException: Unable to create user cache/home/Username/.sonar/cache
at org.sonar.home.cache.FileCache.createDir(FileCache.java:156)
at org.sonar.home.cache.FileCache.<init>(FileCache.java:47)
at org.sonar.home.cache.FileCache.create(FileCache.java:53)
at org.sonar.home.cache.FileCacheBuilder.build(FileCacheBuilder.java:60)
at org.sonar.runner.impl.Jars35.<init>(Jars35.java:40)
at org.sonar.runner.impl.JarDownloader.download35(JarDownloader.java:56)
at org.sonar.runner.impl.JarDownloader.download(JarDownloader.java:40)
at org.sonar.runner.impl.BatchLauncher$1.run(BatchLauncher.java:71)
at java.security.AccessController.doPrivileged(Native Method)
at org.sonar.runner.impl.BatchLauncher.doExecute(BatchLauncher.java:69)
at org.sonar.runner.impl.BatchLauncher.execute(BatchLauncher.java:50)
at org.sonar.runner.impl.BatchLauncherMain.execute(BatchLauncherMain.java:41)
at org.sonar.runner.impl.BatchLauncherMain.main(BatchLauncherMain.java:59)
Caused by: java.io.IOException: Unable to create directory /home/Username/.sonar/cache
at org.apache.commons.io.FileUtils.forceMkdir(FileUtils.java:1748)
at org.sonar.home.cache.FileCache.createDir(FileCache.java:154)
... 12 more

Error occurred during initialization of VM (java.lang.StackOverflowError) in Android

Today I suddenly started encountering
Error occurred during initialization of VMjava/lang/NoClassDefFoundError: java/lang/ref/FinalReference
in Eclipse Indigo. I followed here and also I tried here and
now I am getting:
Error occurred during initialization of VM java.lang.StackOverflowError
I am building an Android application using Eclipse Java EE IDE.
EDIT: I don't know why it caused the problem but now I am able to run my activity by going through run-run configurations-android application-run.
Problem persist due to JVM. If you will give command like java -version. It gives same problem.
If you want to start eclipse.exe by means of the following :
E:\softwaredownload\eclipse-jee-helios-SR2-win32\eclipse>eclipse -vm "c:\Program Files\Java\jdk1.7.0_03\jre\bin\javaw.exe

Categories

Resources