Skip to content

Commit

Permalink
Merge branch 'release-3.2' into cherry-pick-2667-to-release-3.2
Browse files Browse the repository at this point in the history
  • Loading branch information
shiyuhang0 authored Apr 26, 2023
2 parents cf5ab14 + 1d7009e commit 0c036cb
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
import static com.pingcap.tikv.codec.MetaCodec.KEY_DBs;

import com.fasterxml.jackson.core.JsonParseException;
import com.fasterxml.jackson.databind.DeserializationFeature;
import com.fasterxml.jackson.databind.JsonMappingException;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.pingcap.tikv.Snapshot;
Expand Down Expand Up @@ -51,6 +52,7 @@ public static <T> T parseFromJson(ByteString json, Class<T> cls) {

logger.debug(String.format("Parse Json %s : %s", cls.getSimpleName(), json.toStringUtf8()));
ObjectMapper mapper = new ObjectMapper();
mapper.disable(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES);
try {
return mapper.readValue(json.toStringUtf8(), cls);
} catch (JsonParseException | JsonMappingException e) {
Expand Down

0 comments on commit 0c036cb

Please sign in to comment.