Skip to content

Commit

Permalink
alibaba#502 Support NONE healthChecker deserialize
Browse files Browse the repository at this point in the history
  • Loading branch information
nkorange committed Mar 15, 2019
1 parent 2dd28b1 commit 99513a2
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,10 @@ public <T> T deserialze(DefaultJSONParser parser, Type type, Object fieldName) {
return (T) JSON.parseObject(jsonObj.toJSONString(), AbstractHealthChecker.Tcp.class);
}

if (StringUtils.equals(checkType, AbstractHealthChecker.None.TYPE)) {
return (T) JSON.parseObject(jsonObj.toJSONString(), AbstractHealthChecker.None.class);
}

if (StringUtils.equals(checkType, AbstractHealthChecker.Mysql.TYPE)) {
return (T) JSON.parseObject(jsonObj.toJSONString(), AbstractHealthChecker.Mysql.class);
}
Expand Down

0 comments on commit 99513a2

Please sign in to comment.