[hibernate-issues] [Hibernate-JIRA] Commented: (HHH-2297) invalid id type error message doesn't report which entity
Diego Pires Plentz (JIRA)
noreply at atlassian.com
Sat Sep 29 22:14:25 EDT 2007
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-2297?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_28254 ]
Diego Pires Plentz commented on HHH-2297:
-----------------------------------------
Hey guys,
Why only CharacterType throws UnsupportedOperationException? Any special reason that I can't map an Id as char?
> invalid id type error message doesn't report which entity
> ---------------------------------------------------------
>
> Key: HHH-2297
> URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-2297
> Project: Hibernate3
> Issue Type: Patch
> Components: metamodel
> Affects Versions: 3.2.0.ga
> Reporter: Kelly Campbell
> Priority: Minor
> Attachments: hibernate-id-type.patch
>
>
> The error message given here makes it very hard to determine what entity has the problem.
> Simple patch is attached.
> java.lang.UnsupportedOperationException: not a valid id type
> at org.hibernate.type.CharacterType.getDefaultValue(CharacterType.java:20)
> at org.hibernate.engine.UnsavedValueFactory.getUnsavedIdentifierValue(UnsavedValueFactory.java:48)
> at org.hibernate.tuple.PropertyFactory.buildIdentifierProperty(PropertyFactory.java:44)
> at org.hibernate.tuple.EntityMetamodel.(EntityMetamodel.java:114)
> at org.hibernate.persister.entity.AbstractEntityPersister.(AbstractEntityPersister.java:418)
> at org.hibernate.persister.entity.SingleTableEntityPersister.(SingleTableEntityPersister.java:108)
> at org.hibernate.persister.PersisterFactory.createClassPersister(PersisterFactory.java:55)
> at org.hibernate.impl.SessionFactoryImpl.(SessionFactoryImpl.java:223)
> at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1213)
> at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:631)
> at org.hibernate.ejb.Ejb3Configuration.createEntityManagerFactory(Ejb3Configuration.java:760)
> at org.hibernate.ejb.Ejb3Configuration.createFactory(Ejb3Configuration.java:151)
> at org.hibernate.ejb.Ejb3Configuration.createEntityManagerFactory(Ejb3Configuration.java:205)
--
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