Hibernate or EclipseLink

I'm rather new in the Java world (coming from .NET/C#) and so also with Intellij IDEA. My question: what would be in general and more particular with Intellij IDEA the prefered ORM: Hibernate or EclipseLink, or doesn't it matter if both are equally supported? I need to persist in a first phase to MySQL and in a second phase also to MongoDB (both in a REST services setup with Tomcat 7).

Thanks.

1 comment
Comment actions Permalink

Hello.

I'm sharing an opinion from IDEA team side (well, even from my personal side), not from IDEA users side. Hope some users will add theirs. We may be not familiar with some practical use cases since IDEA is not that kind of application to require ORM in its development.

First I have no experience working with MongoDB via ORM, since Mongo is not traditional relational DB. It seems I never met such connection before in users' reports. Please investigate this point for yourself, or wait for users' comments.

Also during testing we didn't try mapping database as REST. I'm not sure does REST add any problems, since typical scheme of communication in ORM systems is: ( application code - ORM libraries - database accessible via JDBC properties ), so REST seems to be not involved. However, I may miss some point. Please, contact us if you meet problems here.

Then, answering the main question: I think both Hibernate and EclipseLink are Ok. Just a note: as Hibernate you may mean Hibernate persistence provider for JPA framework or Hibernate framework. In the former case Hibernate and EclipseLink are supported equally in IDEA. Same GUI, same workflow. Another issue is that 2 providers may have different limitations, but this is not IDEA problem. (I know, for example, that EclipseLink has no direct way to define "default schema" property. I this says nothing, then never mind.)

Hibernate as a framework has a bit different support in IDEA, but just slightly. Many things are similar. It is a bit more popular among users than JPA, so we had more reports and more improvements, but again, just a bit.

So from _IDEA_ point of view you may select any. Another case is your application area, here let users speak.

Keywords to search IDEA documentation are "JPA facet" and "Hibernate facet".

Regards,
Alexander.

0

Please sign in to leave a comment.