I'm upgrading Spring from 4.2.9 to 4.3.0 My rendering services are down after the upgrade. There is absolutely no code changes with respect to this upgrade. But my services is not getting up.
Spring Version: 4.3.0.RELEASE Hibernate Version: 3.6.10.Final Java Version: 1.8
2024-01-19 16:06:05,691 ERROR [com.services.rendering.RenderingServiceDaemon] [main] CRITICAL: unable to start rendering service. Exiting - org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'moduleDirector': Invocation of init method failed; nested exception is java.lang.UnsupportedOperationException: unexpected call to public native int java.lang.Object.hashCode() at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeInitialization(InitDestroyAnnotationBeanPostProcessor.java:136) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyBeanPostProcessorsBeforeInitialization(AbstractAutowireCapableBeanFactory.java:408) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1570) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:545) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:482) at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306) at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230) at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197) at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:775) at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:861) at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:541) at com.services.rendering.RenderingServiceDaemon.start(RenderingServiceDaemon.java:56) at com.services.rendering.RenderingServiceDaemon.main(RenderingServiceDaemon.java:80) Caused by: java.lang.UnsupportedOperationException: unexpected call to public native int java.lang.Object.hashCode() at com.testutil.UnsupportedOperationFactoryBean$PlaceHolder.invoke(UnsupportedOperationFactoryBean.java:78) at com.sun.proxy.$Proxy35.hashCode(Unknown Source) at java.util.concurrent.ConcurrentHashMap.get(ConcurrentHashMap.java:936) at java.util.concurrent.ConcurrentHashMap.containsKey(ConcurrentHashMap.java:964) at org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor.requiresDestruction(PersistenceAnnotationBeanPostProcessor.java:380) at org.springframework.beans.factory.support.DisposableBeanAdapter.hasApplicableProcessors(DisposableBeanAdapter.java:431) at org.springframework.beans.factory.support.AbstractBeanFactory.requiresDestruction(AbstractBeanFactory.java:1628) at org.springframework.beans.factory.support.AbstractBeanFactory.registerDisposableBeanIfNecessary(AbstractBeanFactory.java:1645) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:586) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:482) at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306) at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230) at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197) at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:775) at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:861) at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:541) at com.spring.module.ModuleInstance.loadConfig(ModuleInstance.java:65) at com.spring.module.ModuleInstance.load(ModuleInstance.java:50) at com.spring.module.ModuleDirector.init(ModuleDirector.java:115) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor$LifecycleElement.invoke(InitDestroyAnnotationBeanPostProcessor.java:365) at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor$LifecycleMetadata.invokeInitMethods(InitDestroyAnnotationBeanPostProcessor.java:310) at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeInitialization(InitDestroyAnnotationBeanPostProcessor.java:133) ... 13 more Affects: 4.3.0
Any help would be appreciated.
Comment From: snicoll
Spring 4.3 is EOL for over three years and does not officially support Java 18, see https://github.com/spring-projects/spring-framework/wiki/Spring-Framework-Versions.
If you can reproduce with a supported version of the framework against a supported Java version, please share a small sample we can run ourselves and we can reopen this issue.
Comment From: kawinprabhakaran
We are not using JDK 18, we are using JDK8 in case you got that wrong.
I will try to replicate using a sample and provide you!
Thanks for the response.
Comment From: snicoll
Sorry, I missed the dot. More coffee needed I guess. Make sure the sample uses a supported version.