Spring Data Rest (SDR ) bug? Persistent Entity Must not be null

后端 未结 3 1284
野趣味
野趣味 2020-12-19 08:07

Currently I am working on a POC for Spring Data Rest. Trying to get workable JSONout of a repository.

I have an Entity Class (NewTask)

@Entity
@Tab         


        
3条回答
  •  星月不相逢
    2020-12-19 08:48

    Spring Data REST can only return data for which the repository is registered for. In the other question that you reference, you'll notice that they created a custom repository specifically for the type that they needed. This isn't a bug in SDR, it's just how it functions. It also keeps it RESTful.

    So in your case, SDR can only return NewTask or collections of NewTask.

提交回复
热议问题