public static int getInt(String key, int def) {
        String value = get(key);
        if (value == null) {
            return def;
        }

        value = value.trim().toLowerCase();
        try {
            return Integer.parseInt(value);
        } catch (Exception ignored) {
            // ignored
        }

        LOG.warn("Unable to parse the integer system property '{}':{} - using the default value: {}.", key, value, def);

        return def;
    }
Returns the value of the Java system property with the
specified {@code key}, while falling back to the specified
default value if the property access fails.

@return the property value.
{@code def} if there's no such property or if an access
to the specified property is not allowed.
jraft-core/src/main/java/com/alipay/sofa/jraft/util/SystemPropertyUtil.java