My Oracle Support Banner

NullPointerException When Using The Canonical Meta Model Before The PersistenceContext Was Initialized Firstly (Doc ID 1553581.1)

Last updated on MAY 20, 2013

Applies to:

Oracle TopLink - Version 11.1.1.4.0 and later
Information in this document applies to any platform.

Symptoms

A code line using the canonical meta model of a JPA 2.0 persistence unit runs into

Caused by: java.lang.NullPointerException
at ch.ipt.ClientSimulator.loadHugoMeier(ClientSimulator.java:36)
...
with
ch.ipt.ClientSimulator Line 36 :
String resolvingPath = Person_.shoppingCards.getName() + "." + ShoppingCard_.items.getName() + "." + Item_.product.getName();

 

with ClientSimulator being a stateless SessionBean and loadHugoMeier defined as

@Schedule(second = "*/12", minute = "*", hour = "*", persistent = false)
public void loadHugoMeier() {
Set resolvingPaths = new HashSet();
String resolvingPath = Person_.shoppingCards.getName() + "." + ShoppingCard_.items.getName() + "." + Item_.product.getName();
...

 

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Cause
Solution


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.