For historic reasons, we currently have multiple places in which identifier lookups and the algorithm for the is-new-detection is implemented. Originally implemented in the EntityInformation abstraction (which was tied to repositories), we now also keep a similar implementation in IsNewStrategy used via a factory mostly from the auditing subsystem.
We should move to unify these approaches in PersistentEntity as we already implement the identifier and property lookup there, allow store specific overrides. This also means that repository implementations could work with PersistentEntity instead of EntityInformation. As this would require more intensive refactoring, we could refactor the PersistentEntityInformation implementation to completely delegate to PersistentEntity and deprecate all related implementations of EntityInformation (the one handling Persistable etc.).
Also, we should deprecate IsNewStrategyFactory and rather move IsNewAwareAuditingHandler onto the is-new-detection to be exposed from PersistentEntity
Issue Links:
DATAMONGO-1990 Adapt build to changes in is-new-handling
("is depended on by")
The text was updated successfully, but these errors were encountered:
spring-projects-issues commentedMay 31, 2018
Oliver Drotbohm opened DATACMNS-1333 and commented
For historic reasons, we currently have multiple places in which identifier lookups and the algorithm for the is-new-detection is implemented. Originally implemented in the
EntityInformation
abstraction (which was tied to repositories), we now also keep a similar implementation inIsNewStrategy
used via a factory mostly from the auditing subsystem.We should move to unify these approaches in
PersistentEntity
as we already implement the identifier and property lookup there, allow store specific overrides. This also means that repository implementations could work withPersistentEntity
instead ofEntityInformation
. As this would require more intensive refactoring, we could refactor thePersistentEntityInformation
implementation to completely delegate toPersistentEntity
and deprecate all related implementations ofEntityInformation
(the one handlingPersistable
etc.).Also, we should deprecate
IsNewStrategyFactory
and rather moveIsNewAwareAuditingHandler
onto the is-new-detection to be exposed fromPersistentEntity
Issue Links:
("is depended on by")
The text was updated successfully, but these errors were encountered: