# Mistake in documentation for 3.7.2 Composite Identifiers

**URL:** <https://discourse.hibernate.org/t/mistake-in-documentation-for-3-7-2-composite-identifiers/12196>\
**Category:** Hibernate ORM\
**Created:** [March 30, 2026, 11:52am UTC](https://discourse.hibernate.org/t/mistake-in-documentation-for-3-7-2-composite-identifiers/12196 "2026-03-30T11:52:41Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![fbienz](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.hibernate.org/fbienz/32/4302_2.png) [@fbienz](https://discourse.hibernate.org/u/fbienz)\
**Post date:** [March 30, 2026, 11:52am UTC](https://discourse.hibernate.org/t/mistake-in-documentation-for-3-7-2-composite-identifiers/12196/1 "2026-03-30T11:52:41Z")

</div>

I believe I’ve found a mistake in the documentation.

Namely Section [3.7.2 Composite Identifiers](https://docs.hibernate.org/orm/7.3/userguide/html_single/#identifiers-composite) states, that JPA requires the following from Composite Identifiers:

- The primary key class must be public and must have a public no-arg constructor.
- The primary key class must be serializable.

However in the [release notes](https://jakarta.ee/specifications/persistence/3.2/) of JPA 3.2 it states: `Primary key classes are no longer required to be public and serializable`.

I’m assuming, this was simply not updated and no longer reflects the implementation. Therefore I can safely ignore these two points.

---

<div class="post-metadata">

**Author:** ![beikov](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.hibernate.org/beikov/32/258_2.png) [@beikov](https://discourse.hibernate.org/u/beikov)\
**Post date:** [March 30, 2026, 12:26pm UTC](https://discourse.hibernate.org/t/mistake-in-documentation-for-3-7-2-composite-identifiers/12196/2 "2026-03-30T12:26:02Z")

</div>

Correct, but it would be nice if you would create a PR to actually fix this 🙂

---

<div class="post-metadata">

**Author:** ![fbienz](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.hibernate.org/fbienz/32/4302_2.png) [@fbienz](https://discourse.hibernate.org/u/fbienz)\
**Post date:** [April 1, 2026, 9:09am UTC](https://discourse.hibernate.org/t/mistake-in-documentation-for-3-7-2-composite-identifiers/12196/3 "2026-04-01T09:09:47Z")

</div>

Here you go.

> <https://github.com/hibernate/hibernate-orm/pull/12111>
>
> align documentation on composite identifiers with JPA 3.2 specifiaction
> 
> Namel…y:
> \- remove requirement stating a primary key class must be serializable
> \- remove requirement for class to be public
> \- update requirement on no-args constructor to allow protected, excluding record types
> 
> Based on @beikov's Forum \[response\](https://discourse.hibernate.org/t/mistake-in-documentation-for-3-7-2-composite-identifiers/12196/2) I'm assuming that this change reflect the current state in Hibernate.
> 
> \----------------------
> By submitting this pull request, I confirm that my contribution is made under the terms of the \[Apache 2.0 license\](https://www.apache.org/licenses/LICENSE-2.0.txt)
> and can be relicensed under the terms of the \[LGPL v2.1 license\](https://www.gnu.org/licenses/old-licenses/lgpl-2.1.txt) in the future at the maintainers' discretion.
> For more information on licensing, please check \[here\](https://github.com/hibernate/hibernate-orm/blob/main/CONTRIBUTING.md#legal).
> 
> \----------------------
