gpt4 book ai didi

java - 升级到 Spring 5.0.0.RELEASE - 无法实例化 hazelcast

转载 作者:行者123 更新时间:2023-11-30 02:22:04 30 4
gpt4 key购买 nike

我正在从 Spring 4.3.x 升级到 5.0.0。修复了一些对 hibernate5 相关类的引用后,我收到以下错误:

Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.hazelcast.core.HazelcastInstance]: Factory method 'hazelcastInstance' threw exception; nested exception is java.lang.ExceptionInInitializerError
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:186)
at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:575)
... 100 common frames omitted
Caused by: java.lang.ExceptionInInitializerError: null
at com.hazelcast.hibernate.serialization.Hibernate4CacheEntrySerializerHook.createSerializer(Hibernate4CacheEntrySerializerHook.java:59)
at com.hazelcast.internal.serialization.impl.DefaultSerializationServiceBuilder.registerSerializerHooks(DefaultSerializationServiceBuilder.java:286)
at com.hazelcast.internal.serialization.impl.DefaultSerializationServiceBuilder.build(DefaultSerializationServiceBuilder.java:220)
at com.hazelcast.instance.DefaultNodeExtension.createSerializationService(DefaultNodeExtension.java:125)
at com.hazelcast.instance.Node.<init>(Node.java:174)
at com.hazelcast.instance.HazelcastInstanceImpl.<init>(HazelcastInstanceImpl.java:125)
at com.hazelcast.instance.HazelcastInstanceFactory.constructHazelcastInstance(HazelcastInstanceFactory.java:160)
at com.hazelcast.instance.HazelcastInstanceFactory.newHazelcastInstance(HazelcastInstanceFactory.java:143)
at com.hazelcast.instance.HazelcastInstanceFactory.newHazelcastInstance(HazelcastInstanceFactory.java:111)
at com.hazelcast.core.Hazelcast.newHazelcastInstance(Hazelcast.java:58)

...

Caused by: java.lang.NoSuchMethodException: org.hibernate.cache.spi.entry.StandardCacheEntryImpl.<init>([Ljava.io.Serializable;, java.lang.String, boolean, java.lang.Object)
at java.lang.Class.getConstructor0(Class.java:3082)
at java.lang.Class.getDeclaredConstructor(Class.java:2178)
at com.hazelcast.hibernate.serialization.Hibernate42CacheEntrySerializer.<clinit>(Hibernate42CacheEntrySerializer.java:47)

有人遇到过这个问题吗? hazelcast 支持 spring 5.0.0 吗?我没有找到有关它的文档。

最佳答案

由于 Hibernate 中的某些内部更改,您需要另一个版本的集成。请在此处查看正确的集成:https://github.com/hazelcast/hazelcast-hibernate5

关于java - 升级到 Spring 5.0.0.RELEASE - 无法实例化 hazelcast,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46512651/

30 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com