I'm afraid I'm not familiar enough with envers to help ... I haven't
heard of it before.

On Fri, Dec 18, 2009 at 4:21 PM, Jim O'Callaghan <jc1000...@yahoo.co.uk> wrote:
> Still stumped on this - any pointers on where to look or Tapestry5 relevant 
> examples would be really helpful.
>
> Relevant envers listeners are configured and are working correctly when 
> entities are created / updated.  Tapestry (specifically the hibernate 
> session) does not appear to see the generated xyz_AUD entities and complains 
> that these entities are not mapped with an error ex.:
>
> Caused by: org.hibernate.hql.ast.QuerySyntaxException: 
> com.abc.xyz.entities.core.user.User_AUD is not mapped [select e, r from ...
>
> ... whenever any AuditReader methods are called.
>
> Within method contributeValueEncoderSource in HibernateModule.java, 
> persistentClass.getMappedClass() returns null for the *_AUD classes, 
> resulting in an error adding the entity to the configuration (blank key).  I 
> tried testing classForName on the *_AUD entities where .hasPojoRepresentation 
> returns false but get class not found exception.
>
> Towards the end of startup output I do see the entities I expect configured:
>
> [INFO] HibernateCoreModule.HibernateSessionSource Configured Hibernate 
> entities: Client_Address_AUD, Client_Phone_AUD, 
> com.abc.xyz.entities.core.SystemKey, 
> com.abc.xyz.entities.core.client.Address, 
> com.abc.xyz.entities.core.client.Address_AUD, 
> com.abc.xyz.entities.core.client.Client, 
> com.abc.xyz.entities.core.client.Client_AUD, 
> com.abc.xyz.entities.core.client.Phone, 
> com.abc.xyz.entities.core.client.Phone_AUD, 
> com.abc.xyz.entities.core.user.Role, com.abc.xyz.entities.core.user.User, 
> com.abc.xyz.entities.core.user.UserClass, com.abc.xyz.entities.menu.Menu, 
> com.abc.xyz.entities.menu.MenuEntry, 
> org.hibernate.envers.DefaultRevisionEntity
>
> The earlier startup output does differ between the concrete entities and the 
> envers ones:
>
> .
> .
> .
> [INFO] cfg.AnnotationBinder Binding entity from annotated class: 
> com.abc.xyz.entities.core.client.Client
> [INFO] annotations.EntityBinder Bind entity 
> com.abc.xyz.entities.core.client.Client on table Client
> [INFO] cfg.AnnotationBinder Binding entity from annotated class: 
> com.abc.xyz.entities.core.client.Address
> [INFO] annotations.EntityBinder Bind entity 
> com.abc.xyz.entities.core.client.Address on table Address
> [INFO] cfg.AnnotationBinder Binding entity from annotated class: 
> com.abc.xyz.entities.core.client.Phone
> [INFO] annotations.EntityBinder Bind entity 
> com.abc.xyz.entities.core.client.Phone on table Phone
> .
> .
> .
>
> [INFO] cfg.HbmBinder Mapping class: 
> com.abc.xyz.entities.core.client.Client_AUD -> Client_AUD
> [INFO] cfg.HbmBinder Mapping class: Client_Address_AUD -> Client_Address_AUD
> [INFO] cfg.HbmBinder Mapping class: Client_Phone_AUD -> Client_Phone_AUD
> [INFO] cfg.HbmBinder Mapping class: 
> com.abc.xyz.entities.core.client.Address_AUD -> Address_AUD
> [INFO] cfg.HbmBinder Mapping class: 
> com.abc.xyz.entities.core.client.Phone_AUD -> Phone_AUD
> [INFO] cfg.HbmBinder Mapping class: 
> org.hibernate.envers.DefaultRevisionEntity -> REVINFO
>
> Does this give any clues - HbmBinder vs. EntityBinder?
>
> Regards,
> Jim.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
>
>



-- 
Howard M. Lewis Ship

Creator of Apache Tapestry

The source for Tapestry training, mentoring and support. Contact me to
learn how I can get you up and productive in Tapestry fast!

(971) 678-5210
http://howardlewisship.com

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org

Reply via email to