Spring Boot : Error creating bean with name 'jpaMappingContext': java.lang.NullPointerException

前端 未结 4 1504
太阳男子
太阳男子 2021-02-07 09:20

My combination of is Spring Boot + Spring Data Jpa + Multiple Databases. I am getting following NullPointer exception when starting the application. Feels like SPring Data with

4条回答
  •  没有蜡笔的小新
    2021-02-07 10:21

    For me this turned out to be due to a custom implementation of org.hibernate.usertype.UserType that I was using for mapping JSON types to Java objects.

    In my particular case, it was mapping to a java.util.Map and this change in Spring Data JPA was causing a regression on upgrading to that version.

    The fix was to explicitly set generic types for the Map - e.g. Map in my case.

提交回复
热议问题