NullPointerException thrown when the InferenceAgent tries to load an entity from backingstore (JDBC driver)

NullPointerException thrown when the InferenceAgent tries to load an entity from backingstore (JDBC driver)

book

Article ID: KB0071633

calendar_today

Updated On:

Products Versions
TIBCO BusinessEvents Enterprise Edition 6.0.0, 6.1.0, 6.1.1, 6.1.2, 6.2.0, 6.2.1, 6.2.2

Description

Under heavy load, the following exception can be thrown when Oracle is configured as the backingstore and the InferenceAgent loads an old version of the JDBC Oracle driver.

<timeStamp> <agentName> WARN [<workerThread>] - [runtime.service] [<agent>] Cache:  Exception in get(<{ID|extID}>), retry num=1: java.lang.RuntimeException: Exception reading entry from backingstore.
javax.cache.integration.CacheLoaderException: java.lang.RuntimeException: Exception reading entry from backingstore.
    at org.apache.ignite.internal.processors.cache.store.GridCacheStoreManagerAdapter.loadFromStore(GridCacheStoreManagerAdapter.java:338)
    at org.apache.ignite.internal.processors.cache.store.GridCacheStoreManagerAdapter.load(GridCacheStoreManagerAdapter.java:293)
    at org.apache.ignite.internal.processors.cache.store.GridCacheStoreManagerAdapter.loadAllFromStore(GridCacheStoreManagerAdapter.java:434)
    at org.apache.ignite.internal.processors.cache.store.GridCacheStoreManagerAdapter.loadAll(GridCacheStoreManagerAdapter.java:400)
    at org.apache.ignite.internal.processors.cache.GridCacheAdapter$18.call(GridCacheAdapter.java:2241)
    at org.apache.ignite.internal.processors.cache.GridCacheAdapter$18.call(GridCacheAdapter.java:2239)
    at org.apache.ignite.internal.util.IgniteUtils.wrapThreadLoader(IgniteUtils.java:7085)
    at org.apache.ignite.internal.processors.closure.GridClosureProcessor$2.body(GridClosureProcessor.java:971)
    at org.apache.ignite.internal.util.worker.GridWorker.run(GridWorker.java:120)
    at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
    at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
    at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.lang.RuntimeException: Exception reading entry from backingstore.
    at com.tibco.cep.ignite.cache.IgniteCacheLoader.load(IgniteCacheLoader.java:43)
    at org.apache.ignite.internal.processors.cache.GridCacheLoaderWriterStore.load(GridCacheLoaderWriterStore.java:105)
    at org.apache.ignite.internal.processors.cache.CacheStoreBalancingWrapper.load(CacheStoreBalancingWrapper.java:98)
    at org.apache.ignite.internal.processors.cache.store.GridCacheStoreManagerAdapter.loadFromStore(GridCacheStoreManagerAdapter.java:327)
    ... 11 more
Caused by: java.lang.NullPointerException
    at com.tibco.cep.ignite.cache.IgniteCacheLoader.load(IgniteCacheLoader.java:41)
    ... 14 more

 

Environment

All Operating Systems (Cache- and backingstore enabled)

Resolution

The error can be thrown if an old JDBC driver is loaded by the InferenceAgent (ojdbc6.jar instead of ojdbc8.jar).

To avoid the error, stop all agents, remove the old jdbc driver from classpath and copy the latest version to the classpath. To ensure that the new JDBC driver is loaded, update the property "tibco.env.CUSTOM_EXT_PREPEND_CP" and add the folder where you copied the new JDBC libraries.

The Oracle JDBC drivers are available here:  Oracle JDBC driver download

 

Issue/Introduction

Exception in get(<{ID|extID}>), retry num=1: java.lang.RuntimeException: Exception reading entry from backingstore. javax.cache.integration.CacheLoaderException: java.lang.RuntimeException: Exception reading entry from backingstore.