Saturday, March 31, 2007

Das Pferd isst keinen...

Gurkensalat.

Low - Breaker

www.youtube.com/watch?v=zmo7tyrtGW0

yummy. I only wonder why he doesn't start with the piece on his plate :-)

Friday, March 30, 2007

OC4J+JPA+Hibernate3+spring antlr problem

Setup:
OC4J 10.1.3.2
Spring 2.0.3
Hibernate 3.2.2 as JPA persistence provider.

Problem:
org.hibernate.QueryException: ClassNotFoundException: org.hibernate.hql.ast.HqlToken


Analysis:
There's an old antlr.jar in the toplink-lib that comes with OC4J. You have to use the one that comes with
Hibernate.

Solution:
Avoid oracle's toplink stuff to be loaded.
in orion-application.xml, enter:

<orion-application>
<imported-shared-libraries>
<remove-inherited name="oracle.toplink">
</remove-inherited>
</imported-shared-libraries>

See
Oracle® Containers for J2EE Developer's Guide chapter 3.

IIRC there's even a property in the EM that you can set to do this while deploying.