Skip to main content

Hibernate framework

Image of hibernate

Hibernate is an open source object relational mapping object–relational mapping (ORM) tool that provides a framework to map object-oriented domain models to relational databases for web applications. Hibernate not only takes care of the mapping from Java classes to database tables (and from Java data types to SQL data types), but also provides data query and retrieval facilities. This tutorial will teach you how to use Hibernate to develop your database based web applications in simple and easy steps.

Why Hibernate?

Hibernate reduces lines of code by maintaining object-table mapping itself and returns result to application in form of Java objects. It relieves programmer from manual handling of persistent data, hence reducing the development time and maintenance cost.

History of Hibernate

Hibernate was started in 2001 by Gavin King with colleagues from Cirrus Technologies as an alternative to using EJB2-style entity beans. The original goal was to offer better persistence capabilities than those offered by EJB2. In early 2003, the Hibernate development team began Hibernate2 releases. In 2005, Hibernate version 3.0 was released. In December 2018, Hibernate ORM 5.4.0 Final was released.

Advantages of Hibernate

  • Lightweight and open-source.
  • Increased performance.
  • Auto DDL Operations.
  • Database Independence.
  • It provides simple querying of data.
  • Minimizes database access with smart fetching strategies.
  • It does not require any application server to operate.

Working of Hibernate

Hibernate is an open source Object-Relational Persistence and Query service for any Java Application. Hibernate maps Java classes to database tables and from Java data types to SQL data types and relieves the developer from most common data persistence related programming tasks. Hibernate sits between traditional Java objects and database server to handle all the works in persisting those objects based on the appropriate O/R mechanisms and patterns.

Companies who uses Hibernate

182 companies reportedly use Hibernate in their tech stacks, including Platform, Trendyol Group, and Wealthsimple.

PlatformTrendyolWealthsimple

References:


edureka