Finding issues in reading the json string using object mapper read value method. Can be able to retrieve the individual fields but unable to read array values as mentioned below.
{
"Stuname":"Test",
"State":"CREATE",
"resourceIds": ["{stuId: 814981025958, branches:[10, 4946]}"]
}
using
objectMapper.readValue(message, StudentState.class);
In which stuname,state and resourceids collection as well as array also tried. but not able to read it. For resourceids created seperate class which hold stuId and array of locations.
Student State Class :
public class StudentState{
private String Stuname;
private String state;
private Resources [] resourceIds;
//private Collection<Resources> resourceIds;
//Added respective getter/ setter
}