0 Replies Latest reply on Nov 10, 2009 9:46 AM by Kevin Schmidt

    Hibernate 3.5 Beta-2: Envers AuditMetadata Generator causes

    Kevin Schmidt Newbie

      Adam,

      I just wanted to give you a heads up that I created a JIRA Issue due to a class cast exception in the Envers code base. Here is the jira ticket. Long story short, the following exception is thrown while envers is handling discriminator columns (which can be SQL based formulas).

      Caused by: java.lang.ClassCastException: org.hibernate.mapping.Formula cannot be cast to org.hibernate.mapping.Column
      at org.hibernate.envers.configuration.metadata.MetadataTools.addColumns(MetadataTools.java:154)
      at org.hibernate.envers.configuration.metadata.AuditMetadataGenerator.generateMappingData(AuditMetadataGenerator.java:252)
      at org.hibernate.envers.configuration.metadata.AuditMetadataGenerator.generateFirstPass(AuditMetadataGenerator.java:327)
      at org.hibernate.envers.configuration.EntitiesConfigurator.configure(EntitiesConfigurator.java:87)
      at org.hibernate.envers.configuration.AuditConfiguration.(AuditConfiguration.java:86)
      at org.hibernate.envers.configuration.AuditConfiguration.getFor(AuditConfiguration.java:99)
      at org.hibernate.envers.event.AuditEventListener.initialize(AuditEventListener.java:259)
      at org.hibernate.event.EventListeners$1.processListener(EventListeners.java:198)
      at org.hibernate.event.EventListeners.processListeners(EventListeners.java:181)
      at org.hibernate.event.EventListeners.initializeListeners(EventListeners.java:194)

      Thanks for your time,
      Kevin Schmidt
      kevinrsgmail(dot)com