Hallo liebe Developer
),
habe hier eine Dto-Klasse, die ich mit Jersey in ein JSON-String mappen möchte ...
Um das bidirektionale Mapping für diese Klasse in Jersey zu testen, habe ich folgenden Test aufgestellt.
Weiß einer, wie man Jersey das bidirektionale Mapping für diese Klasse beibringen kann?
Z.Z. kommt folgende Exception, sobald ich diesen Test ausführe ...
Ich hab's, wie auf folgender Seite beschrieben, hauptsächlich mit JsonManagedReference/JsonBackReference/JsonIdentityInfo versucht, allerdings bleibt diese Exception ...
http://www.baeldung.com/jackson-bidirectional-relationships-and-infinite-recursion
habe hier eine Dto-Klasse, die ich mit Jersey in ein JSON-String mappen möchte ...
Java:
package dtos;
import java.util.ArrayList;
import java.util.List;
import org.codehaus.jackson.annotate.JsonBackReference;
import org.codehaus.jackson.annotate.JsonIgnore;
import org.codehaus.jackson.annotate.JsonManagedReference;
public class PersonDto extends NativePersonDto {
private PersonDto partner;
private PersonDto mother;
private PersonDto father;
private List<PersonDto> childrens = new ArrayList<PersonDto>();
public void setPartner(PersonDto partner) {
this.partner = partner;
}
public PersonDto getPartner() {
return partner;
}
//@JsonBackReference
public PersonDto getMother() {
return mother;
}
//@JsonBackReference
public void setMother(PersonDto mother) {
this.mother = mother;
}
//@JsonBackReference
public PersonDto getFather() {
return father;
}
//@JsonBackReference
public void setFather(PersonDto father) {
this.father = father;
}
@JsonManagedReference
@JsonBackReference
public void setChildrens(List<PersonDto> childrens) {
this.childrens = childrens;
}
@JsonManagedReference
@JsonBackReference
public List<PersonDto> getChildrens() {
return childrens;
}
}
Java:
private PersonDto createPersonDto_WithBiMapping() {
PersonDto personDto = new PersonDto();
personDto.setId(1L);
PersonDto mother = new PersonDto();
mother.setId(2L);
mother.getChildrens().add(personDto);
personDto.setMother(mother);
PersonDto father = new PersonDto();
father.setId(3L);
father.getChildrens().add(personDto);
personDto.setFather(father);
PersonDto child1 = new PersonDto();
personDto.getChildrens().add(child1);
return personDto;
}
Z.Z. kommt folgende Exception, sobald ich diesen Test ausführe ...
Code:
org.codehaus.jackson.map.JsonMappingException: Infinite recursion (StackOverflowError) (through reference chain: dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"]->java.util.ArrayList[0]->dtos.PersonDto["mother"]->dtos.PersonDto["childrens"])
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:189)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
at org.codehaus.jackson.map.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:430)
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:175)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
at org.codehaus.jackson.map.ser.ContainerSerializers$IndexedListSerializer.serializeContents(ContainerSerializers.java:304)
at org.codehaus.jackson.map.ser.ContainerSerializers$IndexedListSerializer.serializeContents(ContainerSerializers.java:254)
at org.codehaus.jackson.map.ser.ContainerSerializers$AsArraySerializer.serialize(ContainerSerializers.java:142)
at org.codehaus.jackson.map.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:430)
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:175)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
at org.codehaus.jackson.map.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:430)
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:175)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
at org.codehaus.jackson.map.ser.ContainerSerializers$IndexedListSerializer.serializeContents(ContainerSerializers.java:304)
at org.codehaus.jackson.map.ser.ContainerSerializers$IndexedListSerializer.serializeContents(ContainerSerializers.java:254)
at org.codehaus.jackson.map.ser.ContainerSerializers$AsArraySerializer.serialize(ContainerSerializers.java:142)
at org.codehaus.jackson.map.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:430)
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:175)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
at org.codehaus.jackson.map.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:430)
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:175)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
at org.codehaus.jackson.map.ser.ContainerSerializers$IndexedListSerializer.serializeContents(ContainerSerializers.java:304)
at org.codehaus.jackson.map.ser.ContainerSerializers$IndexedListSerializer.serializeContents(ContainerSerializers.java:254)
at org.codehaus.jackson.map.ser.ContainerSerializers$AsArraySerializer.serialize(ContainerSerializers.java:142)
at org.codehaus.jackson.map.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:430)
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:175)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
at org.codehaus.jackson.map.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:430)
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:175)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
at org.codehaus.jackson.map.ser.ContainerSerializers$IndexedListSerializer.serializeContents(ContainerSerializers.java:304)
at org.codehaus.jackson.map.ser.ContainerSerializers$IndexedListSerializer.serializeContents(ContainerSerializers.java:254)
at org.codehaus.jackson.map.ser.ContainerSerializers$AsArraySerializer.serialize(ContainerSerializers.java:142)
at org.codehaus.jackson.map.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:430)
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:175)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
at org.codehaus.jackson.map.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:430)
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:175)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
at org.codehaus.jackson.map.ser.ContainerSerializers$IndexedListSerializer.serializeContents(ContainerSerializers.java:304)
at org.codehaus.jackson.map.ser.ContainerSerializers$IndexedListSerializer.serializeContents(ContainerSerializers.java:254)
at org.codehaus.jackson.map.ser.ContainerSerializers$AsArraySerializer.serialize(ContainerSerializers.java:142)
at org.codehaus.jackson.map.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:430)
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:175)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
at org.codehaus.jackson.map.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:430)
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:175)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
at org.codehaus.jackson.map.ser.ContainerSerializers$IndexedListSerializer.serializeContents(ContainerSerializers.java:304)
at org.codehaus.jackson.map.ser.ContainerSerializers$IndexedListSerializer.serializeContents(ContainerSerializers.java:254)
at org.codehaus.jackson.map.ser.ContainerSerializers$AsArraySerializer.serialize(ContainerSerializers.java:142)
at org.codehaus.jackson.map.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:430)
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:175)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
at org.codehaus.jackson.map.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:430)
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:175)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
at org.codehaus.jackson.map.ser.ContainerSerializers$IndexedListSerializer.serializeContents(ContainerSerializers.java:304)
at org.codehaus.jackson.map.ser.ContainerSerializers$IndexedListSerializer.serializeContents(ContainerSerializers.java:254)
at org.codehaus.jackson.map.ser.ContainerSerializers$AsArraySerializer.serialize(ContainerSerializers.java:142)
at org.codehaus.jackson.map.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:430)
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:175)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
at org.codehaus.jackson.map.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:430)
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:175)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
at org.codehaus.jackson.map.ser.ContainerSerializers$IndexedListSerializer.serializeContents(ContainerSerializers.java:304)
at org.codehaus.jackson.map.ser.ContainerSerializers$IndexedListSerializer.serializeContents(ContainerSerializers.java:254)
at org.codehaus.jackson.map.ser.ContainerSerializers$AsArraySerializer.serialize(ContainerSerializers.java:142)
at org.codehaus.jackson.map.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:430)
at org.codehaus.jackson.map.ser.BeanSerializer.serializeFields(BeanSerializer.java:175)
at org.codehaus.jackson.map.ser.BeanSerializer.serialize(BeanSerializer.java:142)
Ich hab's, wie auf folgender Seite beschrieben, hauptsächlich mit JsonManagedReference/JsonBackReference/JsonIdentityInfo versucht, allerdings bleibt diese Exception ...
http://www.baeldung.com/jackson-bidirectional-relationships-and-infinite-recursion