VMware Cloud Community
julian2
Contributor
Contributor

Java version of the HealthAnalyser and changes to the Oracle Java Licensing

Oracle changed the Java license back in 2019 so that it no longer is free for commercial use.

https://www.oracle.com/uk/java/technologies/javase/jdk-faqs.html

The VMware HealthAnalyser can be deployed as either a Java application or a virtual appliance. I usually use the appliance, but have a need to use the Java application. I've tried to use the OpenLogic compiled OpenJDK (https://www.openlogic.com/openjdk-downloads) to run the Java application, but it doesn't work.

 

C:\Users\user\Downloads\VMware VHA 5.5.4 build 18007856 App EN> java -version
openjdk version "11.0.8-internal" 2020-07-14
OpenJDK Runtime Environment (build 11.0.8-internal+0-adhoc..jdk11u)
OpenJDK 64-Bit Server VM (build 11.0.8-internal+0-adhoc..jdk11u, mixed mode)

C:\Users\user\Downloads\VMware VHA 5.5.4 build 18007856 App EN>

C:\Users\user\Downloads\VMware VHA 5.5.4 build 18007856 App EN>java -jar HealthAnalyzer.jar
WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance.
Exception in thread "main" org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'presenter' defined in file [C:\Users\user\Downloads\VMware VHA 5.5.4 build 18007856 App EN\resources\applicationContext.xml]: Bean instantiation via constructor failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.vmware.gts.launcher.presenter.ApplicationPresenter]: Constructor threw exception; nested exception is java.lang.NumberFormatException: For input string: "8-internal+0-adhoc"
at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:314)
at org.springframework.beans.factory.support.ConstructorResolver.autowireConstructor(ConstructorResolver.java:295)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireConstructor(AbstractAutowireCapableBeanFactory.java:1358)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1204)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:557)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:517)
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:323)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:321)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:202)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:882)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:878)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:550)
at org.springframework.context.support.FileSystemXmlApplicationContext.<init>(FileSystemXmlApplicationContext.java:142)
at org.springframework.context.support.FileSystemXmlApplicationContext.<init>(FileSystemXmlApplicationContext.java:95)
at com.vmware.gts.launcher.Launcher.<init>(Launcher.java:45)
at com.vmware.gts.launcher.Launcher.main(Launcher.java:34)
Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.vmware.gts.launcher.presenter.ApplicationPresenter]: Constructor threw exception; nested exception is java.lang.NumberFormatException: For input string: "8-internal+0-adhoc"
at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:217)
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:117)
at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:310)
... 16 more
Caused by: java.lang.NumberFormatException: For input string: "8-internal+0-adhoc"
at java.base/java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
at java.base/java.lang.Integer.parseInt(Integer.java:652)
at java.base/java.lang.Integer.parseInt(Integer.java:770)
at com.vmware.gts.launcher.presenter.ApplicationPresenter.isCurrentJavaVersionSupported(ApplicationPresenter.java:296)
at com.vmware.gts.launcher.presenter.ApplicationPresenter.checkMinJavaVersion(ApplicationPresenter.java:274)
at com.vmware.gts.launcher.presenter.ApplicationPresenter.<init>(ApplicationPresenter.java:90)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490)
at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:204)
... 18 more

C:\Users\user\Downloads\VMware VHA 5.5.4 build 18007856 App EN>

Any suggestions on how to get this to work would be very much appreciated. Thanks!

 

Labels (5)
Reply
0 Kudos
1 Reply
BILKAM
Contributor
Contributor

I have update the last version of HealthAnalyser 5.5.9 and since then I have errors with Unable to connect to target server.

Any suggestions ? 

Capture d’écran 12-10-2022 18.21.58.png

Reply
0 Kudos