Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [eclipselink-users] Issue regarding creating default EntityListener

Check that the entity listener is overriding the correct methods.  If you see
it in the log, then it would seem to be picked up.  Do you see any errors in
the log?  Are you setting the JPA EntityListener or EclipseLink
DescriptorEventListener?  You can check your EclipseLink ClassDescriptor at
runtime by getting the descriptor from the EclipseLink Session and checking
its DescriptorEventManager for the listener.

Perhaps include the listener source code, and the orm.xml you are using to
set it.


atishpotdar wrote:
> 
> Hello There,
> 
> I am facing problem to create default entity listener for auditing. I have
> implemented the logic as define in Functional Specification: EclipseLink
> ORM XML 
> http://wiki.eclipse.org/EclipseLink/Development/200040/FunctionalSpec
> 
> I have tested my EntityListener using annotation and its working fine. Now
> I want to use it as default entity listener and as per specification I
> have created orm.xml file and define the entity listener. Then I have
> added that orm.xml in persistance.xml as follows
> 
> <mapping-file>META-INF/orm.xml</mapping-file>
> 
> I can make build and able to deploy on Glassfish 2.1. But the listener
> never invoke and also doesn't not throw any exception\error. Although as
> per glassfish server log file, I can see that its creating entity listener
> for each entity define in persistance.xml file.
> 
> The implementation of Listener is on different jar and the persistance.xml
> is in different jar. 
> Is it causing the problem? How do I resolve this problem?
> 
> 
> Thanks in advance.
> 
> -Atish
> 


-----
http://wiki.eclipse.org/User:James.sutherland.oracle.com James Sutherland 
http://www.eclipse.org/eclipselink/
 EclipseLink ,  http://www.oracle.com/technology/products/ias/toplink/
TopLink 
Wiki:  http://wiki.eclipse.org/EclipseLink EclipseLink , 
http://wiki.oracle.com/page/TopLink TopLink 
Forums:  http://forums.oracle.com/forums/forum.jspa?forumID=48 TopLink , 
http://www.nabble.com/EclipseLink-f26430.html EclipseLink 
Book:  http://en.wikibooks.org/wiki/Java_Persistence Java Persistence 
-- 
View this message in context: http://www.nabble.com/Issue-regarding-creating-default-EntityListener-tp25166953p25276090.html
Sent from the EclipseLink - Users mailing list archive at Nabble.com.



Back to the top