Hibernate Books

All times are UTC - 5 hours [ DST ]



Post new topic Reply to topic  [ 1 post ] 
Author Message
 Post subject: GridType missing
PostPosted: Fri Feb 24, 2012 5:48 am 
Newbie

Joined: Thu Feb 02, 2012 12:01 pm
Posts: 4
Hello,

When I try to retrieve an Entity Manager, I got this:

Caused by: org.hibernate.HibernateException: Unable to find a GridType for org.hibernate.type.SerializableType

So I looked into the org.hibernate.ogm.type.impl.TypeTranslatorImpl class and I think one line is missing:

Code:
typeConverter.put(SerializableTypeDescriptor.INSTANCE, SerializableType.INSTANCE);


Therefore the constant INSTANCE doesn't exist for SerializableTypeDescriptor. A possible hack could be:

Code:
typeConverter.put(new SerializableTypeDescriptor<Serializable>(Serializable.class), SerializableType.INSTANCE);


But it doesn't work because when the get() method is called on the map it won't return anything because the instance are different.

A ticket on Jira has been opened OGM-120

What can be done to fix it ?

Guillaume


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.