Skip to content
This repository has been archived by the owner on Nov 21, 2023. It is now read-only.

Example of using UUIDs as primary keys in Spring-Data REST

Notifications You must be signed in to change notification settings

otrosien/uuid-jpa-rest-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JPA/Eclipselink UUID primary key sample

Example project for demonstrating an enhanced usage of UUIDs as primary keys in JPA, using Version 1 (time-based) UUIDs.

Special Features

The UUID is not, naively serialized as String, but converted into a 16-byte array for optimized storage. The UUIDs are generated transparently while persisting the entity. This is achieved by registering a custom UUID sequence generator in EclipseLink.

The JUG Java Uuid Generator library serves as source for generation of (Version-1) UUIDs.

Further references:

About

Example of using UUIDs as primary keys in Spring-Data REST

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages