<s>
Hibernate	B-Library
ORM	O
(	O
or	O
simply	O
Hibernate	B-Library
)	O
is	O
an	O
object	B-General_Concept
–	I-General_Concept
relational	I-General_Concept
mapping	I-General_Concept
tool	O
for	O
the	O
Java	B-Language
programming	I-Language
language	I-Language
.	O
</s>
<s>
It	O
provides	O
a	O
framework	B-Architecture
for	O
mapping	O
an	O
object-oriented	B-Language
domain	O
model	O
to	O
a	O
relational	B-Application
database	I-Application
.	O
</s>
<s>
Hibernate	B-Library
handles	O
object	B-Architecture
–	I-Architecture
relational	I-Architecture
impedance	I-Architecture
mismatch	I-Architecture
problems	O
by	O
replacing	O
direct	O
,	O
persistent	B-Application
database	O
accesses	O
with	O
high-level	O
object	O
handling	O
functions	O
.	O
</s>
<s>
Hibernate	B-Library
is	O
free	B-Application
software	I-Application
that	O
is	O
distributed	O
under	O
the	O
GNU	B-Application
Lesser	I-Application
General	I-Application
Public	I-Application
License	I-Application
2.1	O
.	O
</s>
<s>
Hibernate	B-Library
's	O
primary	O
feature	O
is	O
mapping	O
from	O
Java	B-Language
classes	O
to	O
database	B-Application
tables	I-Application
,	O
and	O
mapping	O
from	O
Java	B-Language
data	O
types	O
to	O
SQL	B-Language
data	O
types	O
.	O
</s>
<s>
Hibernate	B-Library
also	O
provides	O
data	O
query	O
and	O
retrieval	O
facilities	O
.	O
</s>
<s>
It	O
generates	O
SQL	B-Language
calls	O
and	O
relieves	O
the	O
developer	O
from	O
the	O
manual	O
handling	O
and	O
object	O
conversion	O
of	O
the	O
result	O
set	O
.	O
</s>
<s>
The	O
mapping	O
of	O
Java	B-Language
classes	O
to	O
database	B-Application
tables	I-Application
is	O
implemented	O
by	O
the	O
configuration	O
of	O
an	O
XML	B-Protocol
file	O
or	O
by	O
using	O
Java	B-Language
Annotations	I-Language
.	O
</s>
<s>
When	O
using	O
an	O
XML	B-Protocol
file	O
,	O
Hibernate	B-Library
can	O
generate	B-Application
skeleton	O
source	O
code	O
for	O
the	O
persistence	B-Application
classes	O
.	O
</s>
<s>
This	O
is	O
auxiliary	O
when	O
annotations	B-Language
are	O
used	O
.	O
</s>
<s>
Hibernate	B-Library
can	O
use	O
the	O
XML	B-Protocol
file	O
or	O
the	O
Java	B-Language
annotations	I-Language
to	O
maintain	O
the	O
database	B-Application
schema	I-Application
.	O
</s>
<s>
There	O
are	O
provided	O
facilities	O
to	O
arrange	O
one-to-many	B-Application
and	O
many-to-many	B-Application
relationships	O
between	O
classes	O
.	O
</s>
<s>
In	O
addition	O
to	O
managing	O
associations	O
between	O
objects	O
,	O
Hibernate	B-Library
can	O
also	O
manage	O
reflexive	O
associations	O
wherein	O
an	O
object	O
has	O
a	O
one-to-many	B-Application
relationship	O
with	O
other	O
instances	O
of	O
the	O
class	O
type	O
.	O
</s>
<s>
Hibernate	B-Library
supports	O
the	O
mapping	O
of	O
custom	O
value	O
types	O
.	O
</s>
<s>
Overriding	O
the	O
default	O
SQL	B-Language
type	O
when	O
mapping	O
a	O
column	O
to	O
a	O
property	O
.	O
</s>
<s>
Mapping	O
Java	B-Language
Enums	B-Language
to	O
columns	O
as	O
though	O
they	O
were	O
regular	O
properties	O
.	O
</s>
<s>
Objects	O
in	O
an	O
object-oriented	B-Language
application	O
follow	O
OOP	B-Language
principles	O
,	O
while	O
objects	O
in	O
the	O
back-end	O
follow	O
database	B-Application
normalization	I-Application
principles	O
,	O
resulting	O
in	O
different	O
representation	O
requirements	O
.	O
</s>
<s>
This	O
problem	O
is	O
called	O
"	O
object	B-Architecture
–	I-Architecture
relational	I-Architecture
impedance	I-Architecture
mismatch	I-Architecture
"	O
.	O
</s>
<s>
Mapping	O
is	O
a	O
way	O
of	O
resolving	O
the	O
object	B-Architecture
–	I-Architecture
relational	I-Architecture
impedance	I-Architecture
mismatch	I-Architecture
problem	O
.	O
</s>
<s>
Mapping	O
informs	O
the	O
ORM	O
tool	O
of	O
what	O
Java	B-Language
class	O
object	O
to	O
store	O
in	O
which	O
database	B-Application
table	I-Application
.	O
</s>
<s>
Hibernate	B-Library
provides	O
a	O
SQL	B-Language
inspired	O
language	O
called	O
Hibernate	B-Library
Query	O
Language	O
(	O
HQL	O
)	O
for	O
writing	O
SQL-like	O
queries	O
against	O
Hibernate	B-Library
's	O
data	O
objects	O
.	O
</s>
<s>
Criteria	O
Queries	O
are	O
provided	O
as	O
an	O
object-oriented	B-Language
alternative	O
to	O
HQL	O
.	O
</s>
<s>
HQL	O
(	O
Hibernate	B-Library
Query	O
Language	O
)	O
is	O
the	O
object-oriented	B-Language
version	O
of	O
SQL	B-Language
.	O
</s>
<s>
Without	O
this	O
capability	O
,	O
changing	O
the	O
database	O
would	O
require	O
individual	O
SQL	B-Language
queries	O
to	O
be	O
changed	O
as	O
well	O
,	O
leading	O
to	O
maintenance	O
issues	O
.	O
</s>
<s>
Hibernate	B-Library
provides	O
transparent	O
persistence	B-Application
for	O
Plain	B-Language
Old	I-Language
Java	I-Language
Objects	I-Language
(	O
POJOs	O
)	O
.	O
</s>
<s>
The	O
only	O
strict	O
requirement	O
for	O
a	O
persistent	B-Application
class	O
is	O
a	O
no-argument	B-Language
constructor	I-Language
,	O
though	O
not	O
necessarily	O
.	O
</s>
<s>
Hibernate	B-Library
recommends	O
providing	O
an	O
identifier	O
attribute	O
,	O
and	O
this	O
is	O
planned	O
to	O
be	O
a	O
mandatory	O
requirement	O
in	O
a	O
future	O
release	O
.	O
</s>
<s>
Collections	O
of	O
data	O
objects	O
are	O
typically	O
stored	O
in	O
Java	B-Language
collection	O
classes	O
,	O
such	O
as	O
implementations	O
of	O
the	O
and	O
interfaces	O
.	O
</s>
<s>
Java	B-Language
generics	I-Language
,	O
introduced	O
in	O
Java	B-Language
5	O
,	O
are	O
also	O
supported	O
.	O
</s>
<s>
Hibernate	B-Library
can	O
be	O
configured	O
to	O
lazy	B-General_Concept
load	I-General_Concept
associated	O
collections	O
.	O
</s>
<s>
Lazy	B-General_Concept
loading	I-General_Concept
is	O
the	O
default	O
as	O
of	O
Hibernate	B-Library
3	O
.	O
</s>
<s>
Related	O
objects	O
can	O
be	O
configured	O
to	O
cascade	B-Application
operations	O
from	O
one	O
object	O
to	O
the	O
other	O
.	O
</s>
<s>
For	O
example	O
,	O
a	O
parent	O
class	O
object	O
can	O
be	O
configured	O
to	O
cascade	B-Application
its	O
and	O
operations	O
to	O
its	O
child	O
class	O
objects	O
.	O
</s>
<s>
Hibernate	B-Library
can	O
be	O
used	O
both	O
in	O
standalone	O
Java	B-Language
applications	O
and	O
in	O
Java	B-Language
EE	I-Language
applications	O
using	O
servlets	B-Application
,	O
EJB	B-Language
session	B-Language
beans	I-Language
,	O
and	O
JBI	B-Language
service	O
components	O
.	O
</s>
<s>
For	O
example	O
,	O
Adobe	O
integrated	O
Hibernate	B-Library
into	O
version	O
9	O
of	O
ColdFusion	B-Language
(	O
which	O
runs	O
on	O
J2EE	B-Language
app	O
servers	O
)	O
with	O
an	O
abstraction	O
layer	O
of	O
new	O
functions	O
and	O
syntax	O
added	O
into	O
CFML	B-Language
.	O
</s>
<s>
In	O
Hibernate	B-Library
jargon	O
,	O
an	O
entity	O
is	O
a	O
stand-alone	O
object	O
in	O
Hibernate	B-Library
's	O
persistent	B-Application
mechanism	O
which	O
can	O
be	O
manipulated	O
independently	O
of	O
other	O
objects	O
.	O
</s>
<s>
Unlike	O
J2EE	B-Language
,	O
Hibernate	B-Library
can	O
switch	O
databases	O
.	O
</s>
<s>
Hibernate	B-Library
was	O
started	O
in	O
2001	O
by	O
Gavin	O
King	O
with	O
colleagues	O
from	O
Cirrus	O
Technologies	O
as	O
an	O
alternative	O
to	O
using	O
EJB2-style	O
entity	O
beans	O
.	O
</s>
<s>
The	O
original	O
goal	O
was	O
to	O
offer	O
better	O
persistence	B-Application
capabilities	O
than	O
those	O
offered	O
by	O
EJB2	O
;	O
by	O
simplifying	O
the	O
complexities	O
and	O
supplementing	O
certain	O
missing	O
features	O
.	O
</s>
<s>
In	O
early	O
2003	O
,	O
the	O
Hibernate	B-Library
development	O
team	O
began	O
Hibernate2	O
releases	O
,	O
which	O
offered	O
many	O
significant	O
improvements	O
over	O
the	O
first	O
release	O
.	O
</s>
<s>
JBoss	O
,	O
Inc	O
.	O
(	O
now	O
part	O
of	O
Red	O
Hat	O
)	O
later	O
hired	O
the	O
lead	O
Hibernate	B-Library
developers	O
in	O
order	O
to	O
further	O
its	O
development	O
.	O
</s>
<s>
In	O
2005	O
,	O
Hibernate	B-Library
version	O
3.0	O
was	O
released	O
.	O
</s>
<s>
Key	O
features	O
included	O
a	O
new	O
Interceptor/Callback	O
architecture	O
,	O
user	O
defined	O
filters	O
,	O
and	O
JDK	O
5.0	O
Annotations	B-Language
(	O
Java	B-Language
's	O
metadata	O
feature	O
)	O
.	O
</s>
<s>
,	O
Hibernate	B-Library
3	O
(	O
version	O
3.5.0	O
and	O
up	O
)	O
was	O
a	O
certified	O
implementation	O
of	O
the	O
Java	B-Language
Persistence	I-Language
API	I-Language
2.0	O
specification	O
via	O
a	O
wrapper	O
for	O
the	O
Core	O
module	O
which	O
provides	O
conformity	O
with	O
the	O
JSR	O
317	O
standard	O
.	O
</s>
<s>
In	O
Dec	O
2011	O
,	O
Hibernate	B-Library
Core	I-Library
4.0.0	O
Final	O
was	O
released	O
.	O
</s>
<s>
This	O
includes	O
new	O
features	O
such	O
as	O
support	O
,	O
introduction	O
of	O
ServiceRegistry	O
(	O
a	O
major	O
change	O
in	O
how	O
Hibernate	B-Library
builds	O
and	O
manages	O
"	O
services	O
"	O
)	O
,	O
better	O
session	O
opening	O
from	O
SessionFactory	O
,	O
improved	O
integration	O
via	O
org.hibernate.integrator.spi.Integrator	O
and	O
auto	O
discovery	O
,	O
internationalization	B-General_Concept
support	O
,	O
message	O
codes	O
in	O
logging	O
,	O
and	O
a	O
more	O
distinction	O
between	O
the	O
API	O
,	O
SPI	O
or	O
implementation	O
classes	O
.	O
</s>
<s>
In	O
December	O
2012	O
,	O
Hibernate	B-Library
ORM	O
4.1.9	O
Final	O
was	O
released	O
.	O
</s>
<s>
In	O
Mar	O
2013	O
,	O
Hibernate	B-Library
ORM	O
4.2	O
Final	O
was	O
released	O
.	O
</s>
<s>
In	O
December	O
2013	O
,	O
Hibernate	B-Library
ORM	O
4.3.0	O
Final	O
was	O
released	O
.	O
</s>
<s>
It	O
features	O
Java	B-Language
Persistence	I-Language
API	I-Language
2.1	O
.	O
</s>
<s>
In	O
September	O
2015	O
,	O
Hibernate	B-Library
ORM	O
5.0.2	O
Final	O
was	O
released	O
.	O
</s>
<s>
It	O
has	O
improved	O
bootstrapping	O
,	O
hibernate-java8	O
,	O
hibernate-spatial	O
,	O
Karaf	O
support	O
.	O
</s>
<s>
In	O
November	O
2018	O
,	O
Hibernate	B-Library
ORM	O
5.1.17	O
Final	O
was	O
released	O
.	O
</s>
<s>
In	O
October	O
2018	O
,	O
Hibernate	B-Library
ORM	O
5.3	O
Final	O
was	O
released	O
.	O
</s>
<s>
It	O
featured	O
Java	B-Language
Persistence	I-Language
API	I-Language
2.2	O
inheritance	O
caching	O
.	O
</s>
<s>
In	O
December	O
2018	O
,	O
Hibernate	B-Library
ORM	O
5.4.0	O
Final	O
was	O
released	O
.	O
</s>
<s>
In	O
October	O
2022	O
,	O
Hibernate	B-Library
ORM	O
6.1.4	O
Final	O
was	O
released	O
.	O
</s>
<s>
The	O
Hibernate	B-Library
API	O
is	O
provided	O
in	O
the	O
Java	B-Language
package	I-Language
org.hibernate	O
.	O
</s>
<s>
The	O
org.hibernate.Session	O
interface	O
represents	O
a	O
Hibernate	B-Library
session	O
,	O
i.e.	O
,	O
the	O
main	O
point	O
of	O
the	O
manipulation	O
performed	O
on	O
the	O
database	O
entities	O
.	O
</s>
<s>
The	O
latter	O
activities	O
include	O
(	O
among	O
the	O
other	O
things	O
)	O
managing	O
the	O
persistence	B-Application
state	O
(	O
transient	B-Device
,	O
persisted	B-Language
,	O
detached	O
)	O
of	O
the	O
objects	O
,	O
fetching	O
the	O
persisted	B-Language
ones	O
from	O
the	O
database	O
and	O
the	O
management	O
of	O
the	O
transaction	O
demarcation	O
.	O
</s>
<s>
The	O
Hibernate	B-Library
software	O
includes	O
the	O
following	O
components	O
:	O
</s>
