Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Virgo » Virgo vs Hibernate vs Joda
Virgo vs Hibernate vs Joda [message #984343] Wed, 14 November 2012 16:09
Seth Helstrip is currently offline Seth HelstripFriend
Messages: 22
Registered: September 2012
Junior Member
I'm having some problems getting Hibernate to map Joda attributes from my Value Objects, to the appropriate type in Virgo. I'm probably doing something daft wrong, I just thought I'd ask here, since I'm sure what I'm doing isn't particularly unusual, and hope someone can help me shed some light onto it.

Virgo=3.5
Hibernate=3.6
Joda=2.1
Joda-Hibernate=1.3

So I have a model bundle, in which I have a Value Object, with an attribute that I've annotated with the appropriate type mapping for Joda-Hibernate...

       ...
	@Column(nullable = false, name="REQUEST_DATE")
	@Type(type="org.joda.time.contrib.hibernate.PersistentDateTime")
	private DateTime requestDate;
       ...


The model bundle MANIFEST.MF is being generated correctly, and includes an import to the
org.joda.time.contrib.hibernate
package.

Now, I would have thought this would be enough. However, I get the following exception on deploying my application.

Caused by: org.hibernate.MappingException: Could not determine type for: org.joda.time.contrib.hibernate.PersistentDateTime, at table: REQUEST, for columns: [org.hibernate.mapping.Column(REQUEST_DATE)]
	at org.hibernate.mapping.SimpleValue.getType(SimpleValue.java:306)
	at org.hibernate.mapping.SimpleValue.isValid(SimpleValue.java:290)
	at org.hibernate.mapping.Property.isValid(Property.java:217)


Looking deeper into the stacktrace, I see that this problem is actually occurring at the point where my dao-impl bundle is being deployed, and the entity manager is being created.

So with that in mind, I've also included an Import-Package statement for that bundle, to include the Hibernate-Jodatime mapper.

However, it still doesn't work. At this point, I'm out of ideas.

Has anyone else seen this problem? If you've any ideas how I can solve this, please can you let me know?

Many thanks in advance,
Seth
Previous Topic:Blueprint problem after moving from 3.5.0.M03 to 3.5.0.RELEASE or 3.6.0.M03
Next Topic:Virgo tooling: issues with hot deploy to server in Servers view
Goto Forum:
  


Current Time: Sun Sep 22 04:18:35 GMT 2024

Powered by FUDForum. Page generated in 0.03148 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top