public static <T> Map<String, T> jsonToMap(final String json, final Class<T> valueTypeRef) {
        try {
            JavaType t = MAPPER.getTypeFactory().constructParametricType(HashMap.class, String.class, valueTypeRef);
            return MAPPER.readValue(json, t);
        } catch (IOException e) {
            LOG.warn("write to map error: {}", json, e);
            return new LinkedHashMap<>();
        }
    }
String to Map.

@param json         the object
@param valueTypeRef class
@param <T>          generic
@return the converted map
shenyu-common/src/main/java/org/apache/shenyu/common/utils/JsonUtils.java