This repo is a collection of the JPA Fundamentals examples. You can learn the JPA Fundamentals & Hibernate on my blog.
entity-and-context: Kind of a Hello world application for the JPA.id-generation: What are theGenerationType.TABLEandGenerationType.IDENTITYand where to use@GenericGenerator(...)enumarated-and-temporal: How to work with enum types (@Enumaration), date types and usage of@Temporalannotationcomposed-keys: How to work with composed key with@Embeddableway or@IdClasswayone-to-one-relation: Learn how to create one-to-one relationship between entities using@SecondaryTableor@OneToOneannotationone-to-many-and-many-to-one: Learn how to map one-to-many relationship and which methods are the best for the perfomance.many-to-many: Learn how to map many-to-many relationship.association-override: How to create relationship using@Embeddableand@Embeddedinheritance-strategies: Learn options to construct inheritance relationship in JPA and also learn how to use@MappedSuperclassentity-lifecycle: Learn how to use entity lifecycle events.