users@glassfish.java.net

RE: toplink essentials error messages need improvement

From: Gordon Yorke <gordon.yorke_at_oracle.com>
Date: Mon, 5 Jun 2006 15:42:09 -0400

Yes, TopLink should throw a better exception : https://glassfish.dev.java.net/issues/show_bug.cgi?id=711
--Gordon

-----Original Message-----
From: Matthew Pease [mailto:mpease_at_gmail.com]
Sent: Monday, June 05, 2006 3:25 PM
To: users_at_glassfish.dev.java.net
Subject: toplink essentials error messages need improvement


While I get the feeling that toplink error messages beat out
hibernate's, I think that messages like the following are pretty much
useless.

The first reaction I have when I see this is.. Why is toplink throwing
a nullPointerException... shouldn't it be in control? Also.. this
tells me nothing about what is going on.

These sorts of errors arise when attempting to access a Remote
entity's member collection with fetchtype Lazy & is no longer attached
to a persistance context. Can't toplink be a little smarter?

Thank you -
Matt



Caused by: java.lang.NullPointerException
        at oracle.toplink.essentials.internal.indirection.UnitOfWorkValueHolder.instantiate(UnitOfWorkValueHolder.java:217)
        at oracle.toplink.essentials.internal.indirection.DatabaseValueHolder.getValue(DatabaseValueHolder.java:82)
        at oracle.toplink.essentials.indirection.IndirectList.buildDelegate(IndirectList.java:193)
        at oracle.toplink.essentials.indirection.IndirectList.getDelegate(IndirectList.java:315)
        at oracle.toplink.essentials.indirection.IndirectList$1.<init>(IndirectList.java:410)
        at oracle.toplink.essentials.indirection.IndirectList.iterator(IndirectList.java:409)
        at org.apache.taglibs.standard.tag.common.core.ForEachSupport.toForEachIterator(ForEachSupport.java:348)

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
For additional commands, e-mail: users-help_at_glassfish.dev.java.net