You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Given a resource named main having one related resource named related of type a, and a have a sub-type b, and using @JsonApiRelation(lookup=AUTOMATICALLY_WHEN_NULL) and @JsonApiRelationId When requesting main using include=related and repository implementation of main fills the id of related, but this id matches an instance of b (which extends a). Result the type of related in relationships section is a, the type of related in included section is b Expected Same type, ideally b into the 2 sections.
Issue
Given a resource named
main
having one related resource namedrelated
of typea
, anda
have a sub-typeb
, and using@JsonApiRelation(lookup=AUTOMATICALLY_WHEN_NULL)
and@JsonApiRelationId
When requesting
main
usinginclude=related
and repository implementation ofmain
fills the id ofrelated
, but this id matches an instance ofb
(which extendsa
).Result the type of
related
inrelationships
section isa
, the type ofrelated
inincluded
section isb
Expected Same type, ideally
b
into the 2 sections.Example :
Resources
NB: Getters and setters are omitted for brevity.
Requests
NB: requests are written with httpie, for these examples, you just have to know that 'x==y' means add a request parameter x with value y.
http :8080/main/mainId include==related
data.relationships.related.data.type
should matchincluded[0].type
Remark
I know that having Crnk returning type
b
ifincluded=related
is not specified is not possible. But whenincluded
is present, types should match.The text was updated successfully, but these errors were encountered: