File tree 1 file changed +2
-2
lines changed
jdbc/basics/src/main/java/example/springdata/jdbc/basics/aggregate
1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change 29
29
import org .springframework .data .jdbc .core .convert .JdbcCustomConversions ;
30
30
import org .springframework .data .jdbc .repository .config .AbstractJdbcConfiguration ;
31
31
import org .springframework .data .jdbc .repository .config .EnableJdbcRepositories ;
32
- import org .springframework .data .relational .core .mapping .event .BeforeSaveEvent ;
32
+ import org .springframework .data .relational .core .mapping .event .BeforeConvertEvent ;
33
33
import org .springframework .jdbc .core .JdbcOperations ;
34
34
import org .springframework .jdbc .core .namedparam .NamedParameterJdbcTemplate ;
35
35
import org .springframework .jdbc .datasource .init .DataSourceInitializer ;
@@ -51,7 +51,7 @@ public class AggregateConfiguration extends AbstractJdbcConfiguration {
51
51
@ Bean
52
52
public ApplicationListener <?> idSetting () {
53
53
54
- return (ApplicationListener <BeforeSaveEvent >) event -> {
54
+ return (ApplicationListener <BeforeConvertEvent >) event -> {
55
55
56
56
if (event .getEntity () instanceof LegoSet ) {
57
57
setIds ((LegoSet ) event .getEntity ());
You can’t perform that action at this time.
0 commit comments