This week's book giveaway is in the Jython/Python forum.
We're giving away four copies of Hands On Software Engineering with Python and have Brian Allbey on-line!
See this thread for details.
Win a copy of Hands On Software Engineering with Python this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Bear Bibeault
  • Knute Snortum
  • Liutauras Vilda
Sheriffs:
  • Tim Cooke
  • Devaka Cooray
  • Paul Clapham
Saloon Keepers:
  • Tim Moores
  • Frits Walraven
  • Ron McLeod
  • Ganesh Patekar
  • salvin francis
Bartenders:
  • Tim Holloway
  • Carey Brown
  • Stephan van Hulst

EJB and Hibernate  RSS feed

 
Ranch Hand
Posts: 38
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am new to EJB technology. I have little knowledge on Hibernate. Hibernates also works on Object relational maping and so objects are made persistant so can we say that EJB is obsolate? Shall I continue studing EJB? How can I compare these two?

Thanks.
Sachin.
 
Ranch Hand
Posts: 209
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

As i understand it - i am also new to both EJB and Hibernate :-)

is that EJB is divided up into 3 main sections, i.e. Session EJB beans, Entity EJB beans and Message driven beans

Hibernate is a representation of database tables using java classes i.e. using a database in an object orientated way.

Session beans are a single transaction with the user with no direct database involvement

Entity beans represent entities within a persistant storage (for example a database). Entity beans have direct database involvement and can use EJB-SQL.

Message beans are used by a client to send a message to a bean and doesnt really care if the data gets to the client or not.



Entity beans is most like Hibernate. So Hibernate represents 1 section out of 3 of EJB

EJB 2.0 doesnt use Hibernate so what i would (and plan to do) is to study and understand EJB 2.0 with SQL

The newest version of EJB (3.0) doesnt have SQL for Entity beans but rather uses Hibernate to do database involvement.

I hope the above helps :-)

Niall
[ March 24, 2007: Message edited by: Niall Loughnane ]
 
Ranch Hand
Posts: 1855
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Originally posted by sachin pachpute:
Hibernates also works on Object relational maping and so objects are made persistant so can we say that EJB is obsolate? Shall I continue studing EJB?



HFEJB has 12 chapters about EJB. Only 2 of them are about Entity Beans. If you like to go Hibernate, forget those 2 chapters (actually read them too ) and concentrate on the 10 other chapters.
 
ranger
Posts: 17344
11
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In EJB 2.x Hibernate is a replacement for Entity Beans, plus a whole lot more.

In EJB 3.x Hibernate is an implementation of the JPA spec, plus a whole lot more.

Mark
 
sachin pachpute
Ranch Hand
Posts: 38
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you all for giving time,
Sachin.
 
Why does your bag say "bombs"? The reason I ask is that my bag says "tiny ads" and it has stuff like this:
Programmatically Create PDF Using Free Spire.PDF with Java
https://coderanch.com/wiki/703735/Programmatically-Create-PDF-Free-Spire
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!