Skip to content

landsman/typeid-hibernate

Repository files navigation

typeid-hibernate

Hibernate implementation of TypeID.

TypeIDs are a modern, type-safe, globally unique identifier based on the upcoming UUIDv7 standard. They provide a ton of nice properties that make them a great choice as the primary identifiers for your data in a database, APIs, and distributed systems. Read more about TypeIDs in their spec.

Installation

Starting with version 0.0.1, typeid-hibernate requires at least Java 17.

For installation via Gradle:

repositories {
    mavenCentral()
    maven {
        name = "GitHubPackages"
        url = uri("https://maven.pkg.github.com/landsman/typeid-hibernate")
        credentials {
            username = System.getenv("GITHUB_ACTOR")
            password = System.getenv("GITHUB_TOKEN")
        }
    }
}

dependencies {
    implementation("com.github.landsman:typeid-hibernate:0.0.1")
}

Usage

public class TestUserEntity {
    @Id
    @TypeIdHibernate(prefix = "u")
    private String id;
}

About

Custom ID generator for Hibernate, Spring Framework inspired by @stripe

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors 2

  •  
  •  

Languages