I am trying out some very basic webservice. I get this exception everytime I try to return the Prtnr object.
Uncaught exception thrown in one of the service met
The infinite recursion is due to the following:
Class Prtnr
contains Set
and each PrtnrGeoInfo
contains PrtnrGeoInfoId id
which in turn contains Prtnr partner
.
Thus, Prtnr
-> PrtnrGeoInfo
->PrtnrGeoInfoId
->Prtnr
, is causing a cyclic dependency which is a problem for Jackson when it is trying to do the POJO Mapping.
You need to remove this cyclic dependency to fix this exception.