[hibernate-issues] [Hibernate-JIRA] Commented: (HHH-5236) Exception with hibernate model

Gail Badner (JIRA) noreply at atlassian.com
Mon Jan 10 19:27:05 EST 2011


    [ http://opensource.atlassian.com/projects/hibernate/browse/HHH-5236?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=39544#action_39544 ] 

Gail Badner commented on HHH-5236:
----------------------------------

Is this still an issue when using 3.6.0?

> Exception with hibernate model
> ------------------------------
>
>                 Key: HHH-5236
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-5236
>             Project: Hibernate Core
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 3.2.0.ga, 3.5.0-Final, 3.5.2
>         Environment: Java 1.5
> Windows/Unix
>            Reporter: Michael Zhang
>         Attachments: CmPaperType.hbm.xml, CmPaperType.java
>
>
> I have a hibernate model class member e.g. (active) that is mapped to a string (either "Y" or "N"). Both getter and setter are implemented.  There is also another method in the class: public boolean isActive()...
> When test it from JUnit, everything works fine.  However when the class is accessed from thread with database update operation, hibernate will throw ClassCast exception from Boolean to String. 
> If the method of "isActive" is changed to something else such as "isActiveMethod", the exception will disappeare.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the hibernate-issues mailing list