I have a Java class as
@JsonIgnoreProperties(ignoreUnknown = true)
public class LogMessage {
private String timestamp;
private String level;
private String message;
private String loggername;
private String thread;
}
The following code:
ObjectMapper objectMapper = new ObjectMapper();
....
objectMapper.readValue(m, LogMessage.class);
will throw an expectation when a message field contains a JSON format data.
What will be a good way to deal with the problem?