DATAJDBC-400 - Deprecated Identifier for those events that also have an entity.
Retrieval of the Identifier has been shown to cost significant performance. Original pull request: #164.
This commit is contained in:
committed by
Mark Paluch
parent
2289195e8a
commit
af3b9f8adb
@@ -39,11 +39,13 @@ public class RelationalEventWithId extends SimpleRelationalEvent implements With
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.jdbc.core.mapping.event.JdbcEvent#getId()
|
||||
/**
|
||||
* Events with an identifier will always return a {@link Specified} one.
|
||||
*
|
||||
* @deprecated obtain the id from the entity instead.
|
||||
*/
|
||||
@Override
|
||||
@Deprecated
|
||||
public Specified getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
@@ -43,11 +43,11 @@ class SimpleRelationalEvent extends ApplicationEvent implements RelationalEvent
|
||||
this.change = change;
|
||||
}
|
||||
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.jdbc.core.mapping.event.JdbcEvent#getId()
|
||||
/**
|
||||
* @deprecated obtain the id from the entity instead.
|
||||
*/
|
||||
@Override
|
||||
@Deprecated
|
||||
public Identifier getId() {
|
||||
return (Identifier) getSource();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user