-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 
Author Message
 Post subject: Native API vs. JPA API
PostPosted: Mon Nov 22, 2010 1:54 pm 
Newbie

Joined: Mon Nov 22, 2010 1:46 pm
Posts: 2
Hi.

I'm beginning a new project with Hibernate but I'm confused about native and JPA apis.

What is the advantage, if any, of using native API instead of JPA?

My project is quite standard: customers, invoices... I'll be using Sping container for DI and transaction management.

Thank you.


Top
 Profile  
 
 Post subject: Re: Native API vs. JPA API
PostPosted: Mon Nov 22, 2010 2:43 pm 
Senior
Senior

Joined: Fri Oct 08, 2010 8:44 am
Posts: 130
antonares wrote:
Hi.

I'm beginning a new project with Hibernate but I'm confused about native and JPA apis.

What is the advantage, if any, of using native API instead of JPA?

My project is quite standard: customers, invoices... I'll be using Sping container for DI and transaction management.

Thank you.


Using JPA API only will make your application implementation independent. You will be able to change JPA provider in case Hibernate will frustrate you.

Spring container is obsolete and heavy :)


Top
 Profile  
 
 Post subject: Re: Native API vs. JPA API
PostPosted: Mon Nov 22, 2010 6:27 pm 
Newbie

Joined: Mon Nov 22, 2010 1:46 pm
Posts: 2
Thanks r.

r wrote:
Using JPA API only will make your application implementation independent. You will be able to change JPA provider in case Hibernate will frustrate you.

That is an advantage for JPA. Does native Hibernate offer extra functionality? Any power feature? Increased performance? Or do both native Hibernate and JPA just map each other?

r wrote:
Spring container is obsolete and heavy :)

Could you recommend an alternative to Spring container? I require simple web container: no application server, no EJBs, no JEE container, no extra and heavy add-ons i will never use.

Could you also recommend an alternative for managing transactions? I like the way Spring isolates my application for the underlying environment, actually I understand that using Spring I can manage transaction pretty much the way JTA does but having it outside the application server and without using JNDI. Maybe native Hibernate transaction handling?

Thanks again.


Top
 Profile  
 
 Post subject: Re: Native API vs. JPA API
PostPosted: Mon Jun 27, 2011 7:53 pm 
Newbie

Joined: Mon Jun 27, 2011 7:50 pm
Posts: 1
Spring Core (BeanFactory) is wonderful.

It gives you modularity & configurability.. rather than having to hard-code configuration and write a bunch of glue code/ init crud, with order-of-init issues, to run at startup.

What's not to like?

In the web domain I use only Spring Core and Spring MVC, skip the rest. Not heavy at all.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 

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.