Wie konfiguriere ich Jackson in Wildfly?

Ich habe eine Session Bean mit der folgenden Methode:

@POST
@Consumes("application/x-www-form-urlencoded")
@Path("/calculate")
@Produces("application/json")
public CalculationResult calculate(@FormParam("childProfile") String childProfile,
        @FormParam("parentProfile") String parentProfile) {
...
}

Das zurückgegebene CalculationResult kann JSON nicht zugeordnet werden, und die folgende Ausnahme tritt auf:

Caused by: com.fasterxml.jackson.databind.JsonMappingException: No serializer found for class com.test.UniqueName and no properties discovered to create BeanSerializer (to avoid exception, disable SerializationFeature.FAIL_ON_EMPTY_BEANS)...

Wie kann ich Jackson und sein @ konfiguriereSerializationFeature in Wildfly?

Antworten auf die Frage(4)

Ihre Antwort auf die Frage