vendredi 18 mars 2016

Etat HTTP 500 - Could not write JSON: failed to lazily initialize a collection of

Etat HTTP 500 - Could not write JSON: failed to lazily initialize a collection of

This exception occurs for example when you invoke with json an entity with has a relation with another
 (@ManyToOne).

To resolve this problem you must add @JsonIgnore before   (@ManyToOne), above  the getter of the property, and add @JsonProperty above the setter of the property.

Aucun commentaire:

Enregistrer un commentaire

CANADA JOB