Jackson JSON field mapping capitalization?

Since your setter method is named setMDReqID(…) Jackson assumes the variable is named mDReqID because of the Java naming conventions (variables should start with lower case letters).

If you really want a capital letter use the @JsonProperty annotation on the setter (or – for serialization – on the getter) like this:

@JsonProperty("MDReqID")
public void setMDReqID(String MDReqID) {
    this.MDReqID = MDReqID;
}

Leave a Comment