BasicPersistentEntity::returnPropertyIfBetterIdPropertyCandidateOrNull --> AnnotationBasedPersistentProperty::isIdProperty https://github.com/spring-projects/spring-data-commons/blob/main/src/main/java/org/springframework/data/mapping/model/AnnotationBasedPersistentProperty.java#L78-L79 Shouldn't the `Id.class` used here be `jakarta.persistence.id`? Otherwise the `RelationalEntityMetadata` doesn't contain the id column.