Skip to Main Content

Berkeley DB Family

Announcement

For appeals, questions and feedback, please email oracle-forums_moderators_us@oracle.com

InvalidClassException Error when using Berkeley db 18.3.12 and Helidon 3.0.2

User_UOX6DJan 26 2023 — edited Jan 26 2023

Hi,
We are using Berkeley db in our project where we are also using Helidon.
Here are the versions we are using-
Helidon version - 3.0.2
Java 17
Berkeley db 18.3.12
In an independent java project, where we are only using Berkeley db and no helidon, with an empty Berkeley db folder on start up, entity store is being created properly and everything is working fine. When done the same in a project where we are using helidon 3.0.2 and Berkeley db with an empty bdb folder on startup, we are seeing InvalidClassException error and it’s trying to create entity store multiple times in the Dao class and failing.
Would greatly appreciate any help on this.
Below is the error stack trace -
2023-01-26 09:56:19,345 ERROR [main] com.oracle.blockchain.opcp.ServerLifecycleEvents - Unable to check And Populate Default LDAP
com.sleepycat.je.EnvironmentFailureException: (JE 18.3.12) java.io.InvalidClassException: filter status: REJECTED UNEXPECTED_EXCEPTION: Unexpected internal Exception, may have side effects.
com.sleepycat.je.EnvironmentFailureException: (JE 18.3.12) java.io.InvalidClassException: filter status: REJECTED UNEXPECTED_EXCEPTION: Unexpected internal Exception, may have side effects.
at com.sleepycat.je.EnvironmentFailureException.unexpectedException(EnvironmentFailureException.java:354)
at com.sleepycat.compat.DbCompat.unexpectedException(DbCompat.java:582)
at com.sleepycat.persist.impl.PersistCatalog.readData(PersistCatalog.java:1266)
at com.sleepycat.persist.impl.PersistCatalog.init(PersistCatalog.java:318)
at com.sleepycat.persist.impl.PersistCatalog.initAndRetry(PersistCatalog.java:274)
at com.sleepycat.persist.impl.PersistCatalog.<init>(PersistCatalog.java:234)
at com.sleepycat.persist.impl.Store.<init>(Store.java:210)
at com.sleepycat.persist.EntityStore.<init>(EntityStore.java:204)
at com.oracle.blockchain.opcp.EntityStoreConfig.initializeBerkeleyDb(EntityStoreConfig.java:73)
at com.oracle.blockchain.opcp.EntityStoreConfig.<init>(EntityStoreConfig.java:36)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:77)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)
at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:480)
at org.jboss.weld.injection.ConstructorInjectionPoint.newInstance(ConstructorInjectionPoint.java:119)
at org.jboss.weld.injection.ConstructorInjectionPoint.invokeAroundConstructCallbacks(ConstructorInjectionPoint.java:92)
at org.jboss.weld.injection.ConstructorInjectionPoint.newInstance(ConstructorInjectionPoint.java:78)
at org.jboss.weld.injection.producer.AbstractInstantiator.newInstance(AbstractInstantiator.java:28)
at org.jboss.weld.injection.producer.BasicInjectionTarget.produce(BasicInjectionTarget.java:112)
at org.jboss.weld.injection.producer.BeanInjectionTarget.produce(BeanInjectionTarget.java:186)
at io.helidon.integrations.cdi.delegates.DelegatingProducer.produce(DelegatingProducer.java:51)
at io.helidon.integrations.cdi.delegates.DelegatingProducer.produce(DelegatingProducer.java:51)
at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:160)
at org.jboss.weld.contexts.AbstractContext.get(AbstractContext.java:96)
at org.jboss.weld.bean.ContextualInstanceStrategy$DefaultContextualInstanceStrategy.get(ContextualInstanceStrategy.java:100)
at org.jboss.weld.bean.ContextualInstanceStrategy$ApplicationScopedContextualInstanceStrategy.get(ContextualInstanceStrategy.java:140)
at org.jboss.weld.bean.ContextualInstance.get(ContextualInstance.java:50)
at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:102)
at org.jboss.weld.bean.proxy.ProxyMethodHandler.getInstance(ProxyMethodHandler.java:131)
at com.oracle.blockchain.opcp.EntityStoreConfig$Proxy$_$$_WeldClientProxy.getStore(Unknown Source)
at com.oracle.blockchain.opcp.dao.core.ConfigDao.<init>(ConfigDao.java:37)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:77)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)
at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:480)
at org.jboss.weld.injection.ConstructorInjectionPoint.newInstance(ConstructorInjectionPoint.java:119)
at org.jboss.weld.injection.ConstructorInjectionPoint.invokeAroundConstructCallbacks(ConstructorInjectionPoint.java:92)
at org.jboss.weld.injection.ConstructorInjectionPoint.newInstance(ConstructorInjectionPoint.java:78)
at org.jboss.weld.injection.producer.AbstractInstantiator.newInstance(AbstractInstantiator.java:28)
at org.jboss.weld.injection.producer.BasicInjectionTarget.produce(BasicInjectionTarget.java:112)
at org.jboss.weld.injection.producer.BeanInjectionTarget.produce(BeanInjectionTarget.java:186)
at io.helidon.integrations.cdi.delegates.DelegatingProducer.produce(DelegatingProducer.java:51)
at io.helidon.integrations.cdi.delegates.DelegatingProducer.produce(DelegatingProducer.java:51)
at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:160)
at org.jboss.weld.contexts.AbstractContext.get(AbstractContext.java:96)
at org.jboss.weld.bean.ContextualInstanceStrategy$DefaultContextualInstanceStrategy.get(ContextualInstanceStrategy.java:100)
at org.jboss.weld.bean.ContextualInstanceStrategy$ApplicationScopedContextualInstanceStrategy.get(ContextualInstanceStrategy.java:140)
at org.jboss.weld.bean.ContextualInstance.get(ContextualInstance.java:50)
at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:102)
at org.jboss.weld.bean.proxy.ProxyMethodHandler.getInstance(ProxyMethodHandler.java:131)
at com.oracle.blockchain.opcp.dao.core.ConfigDao$Proxy$_$$_WeldClientProxy.getLdapConfigByName(Unknown Source)
at com.oracle.blockchain.opcp.ServerLifecycleEvents.checkAndPopulateDefaultLDAP(ServerLifecycleEvents.java:105)
at com.oracle.blockchain.opcp.ServerLifecycleEvents.postServerStartActions(ServerLifecycleEvents.java:91)
at com.oracle.blockchain.opcp.ServerLifecycleEvents.onStartup(ServerLifecycleEvents.java:78)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:568)
at org.jboss.weld.injection.StaticMethodInjectionPoint.invoke(StaticMethodInjectionPoint.java:95)
at org.jboss.weld.injection.StaticMethodInjectionPoint.invoke(StaticMethodInjectionPoint.java:85)
at org.jboss.weld.injection.MethodInvocationStrategy$SimpleMethodInvocationStrategy.invoke(MethodInvocationStrategy.java:168)
at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:330)
at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:308)
at org.jboss.weld.event.ObserverMethodImpl.notify(ObserverMethodImpl.java:286)
at jakarta.enterprise.inject.spi.ObserverMethod.notify(ObserverMethod.java:125)
at org.jboss.weld.util.Observers.notify(Observers.java:166)
at org.jboss.weld.event.ObserverNotifier.notifySyncObservers(ObserverNotifier.java:285)
at org.jboss.weld.event.ObserverNotifier.notify(ObserverNotifier.java:273)
at org.jboss.weld.event.EventImpl.fire(EventImpl.java:96)
at io.helidon.microprofile.cdi.HelidonContainerImpl.doStart(HelidonContainerImpl.java:340)
at io.helidon.common.context.Contexts.runInContext(Contexts.java:137)
at io.helidon.microprofile.cdi.HelidonContainerImpl.start(HelidonContainerImpl.java:250)
at io.helidon.microprofile.server.ServerImpl.start(ServerImpl.java:76)
at com.oracle.blockchain.opcp.restserver.BPControlPlaneServer.startServer(BPControlPlaneServer.java:15)
at com.oracle.blockchain.opcp.restserver.BPControlPlaneServer.main(BPControlPlaneServer.java:11)
Caused by: java.io.InvalidClassException: filter status: REJECTED
at java.base/java.io.ObjectInputStream.filterCheck(ObjectInputStream.java:1409)
at java.base/java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:2044)
at java.base/java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1898)
at java.base/java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2224)
at java.base/java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1733)
at java.base/java.io.ObjectInputStream.readObject(ObjectInputStream.java:509)
at java.base/java.io.ObjectInputStream.readObject(ObjectInputStream.java:467)
at com.sleepycat.persist.impl.PersistCatalog.readData(PersistCatalog.java:1249)
... 74 more
Thank you!

Comments
Post Details
Added on Jan 26 2023
1 comment
167 views