Problem
Hibernate logs deprecation warnings on startup for applications using SpringUserFramework:
HHH90000033: Encountered use of deprecated annotation [jakarta.persistence.Temporal] on:
- com.devondragon.springuserframework.user.persistence.model.User.lastActivityDate
- com.devondragon.springuserframework.user.persistence.model.User.lockedDate
- com.devondragon.springuserframework.user.persistence.model.User.registrationDate
The @Temporal annotation is unnecessary for Java 8+ date/time types (LocalDate, LocalDateTime, Instant, etc.) — Hibernate handles them natively. If these fields use java.util.Date, they should be migrated to modern types.
Fix
- Check the types of
lastActivityDate, lockedDate, and registrationDate on the User entity
- If they use
java.util.Date → migrate to java.time.LocalDateTime (or appropriate type) and remove @Temporal
- If they already use Java 8+ types → simply remove the
@Temporal annotation
- Update any related code that interacts with these fields
Priority
Low — deprecation cleanup, but will eventually break in a future Hibernate version.
Problem
Hibernate logs deprecation warnings on startup for applications using SpringUserFramework:
The
@Temporalannotation is unnecessary for Java 8+ date/time types (LocalDate,LocalDateTime,Instant, etc.) — Hibernate handles them natively. If these fields usejava.util.Date, they should be migrated to modern types.Fix
lastActivityDate,lockedDate, andregistrationDateon theUserentityjava.util.Date→ migrate tojava.time.LocalDateTime(or appropriate type) and remove@Temporal@TemporalannotationPriority
Low — deprecation cleanup, but will eventually break in a future Hibernate version.