What is Hibernate? | Introduction to Hibernate | ORM Tool

preview_player
Показать описание
This Learnaholic India will cover - What is Hibernate?
What is hibernate in java?
Introduction to Hibernate - ORM Tool
Hibernate was started in 2001 by Gavin King as an alternative to EJB2 style entity bean. #hibernate #LearnaholicIndia
Hibernate is Java framework that simplifies the development of Java application to interact with database.
It is an open source, lightweight, ORM (Object Relational Mapping) tool.
Hibernate implements the specifications of JPA (Java Persistence API) for data persistence.

ORM Tool
An ORM tool simplifies the data creation, data manipulation and data access.
It is a programming technique that maps the object to the data stored in the database. #advancedjava
The ORM tool internally uses the JDBC API to interact with the database.

What is JPA?
Java Persistence API (JPA) is a Java specification that provides certain functionality and standard to ORM tools.
The Java ORM standard for storing, accessing, and managing Java objects in a relational database.
The Java Persistence API is concerned with persistence, which loosely means any mechanism by which Java objects outlive the application process that created them.

JPA
The JPA specification lets you define which objects should be persisted, and how those objects should be persisted in your Java applications.
JPA is not a tool or framework; rather, it defines a set of concepts that can be implemented by any tool or framework.
JPA's object-relational mapping (ORM) model was originally based on Hibernate.
JPA was originally intended for use with relational/SQL databases.
What is Java ORM?
Object-relational mapping is a task–one that developers have good reason to avoid doing manually.
A framework like Hibernate ORM or EclipseLink codifies that task into a library or framework, an ORM layer.
ORM layer is responsible for managing the conversion of software objects to interact with the tables and columns in a relational database.
In Java, the ORM layer converts Java classes and objects so that they can be stored and managed in a relational database.
Advantages of Hibernate
Open Source and Lightweight
Database Independent Query
Fast Performance
Automation Table Creation
Provides Query Statistics and Database Status
Simplifies Complex Join

Architecture of Hibernate
The Hibernate architecture includes many objects such as persistent object, session factory, transaction factory, connection factory, session, transaction etc.
It has four layers-
Java application layer
Hibernate framework layer
Backhand api layer
Database layer
Architecture Diagram

Elements of Hibernate
Elements of Hibernate
Connection Provider – It is a factory of JDBC connections. It abstracts the application from DriverManager or DataSource. It is optional.
Transaction Factory - It is a factory of Transaction. It is optional.
Hibernate Example without IDE
Create the Persistent class
Create the mapping file for Persistent class
Create the Configuration file
Create the class that retrieves or stores the persistent object
Load the jar file
Run the first hibernate application by using command prompt
Detailed example will be explained in next tutorial

Thanks for Watching
Do Subscribe, like, share. For any queries please comment below.

-~-~~-~~~-~~-~-
Please watch: "SDLC Tutorial for Beginners | Phases of SDLC | Detail Explanation"
Рекомендации по теме
Комментарии
Автор

Give your feedback. Did you find the video helpful?
Suggest me what should I add to improve.
Support my channel and do Subscribe.
Thank you for watching.

LearnaholicIndia