public static Configuration getSystemPropertiesConfiguration(final String prefix, final boolean trimPrefix) {
        final BaseConfiguration apacheConfiguration = new BaseConfiguration();
        for (final Map.Entry<Object, Object> entry : System.getProperties().entrySet()) {
            final String key = entry.getKey().toString();
            final Object value = entry.getValue();
            if (key.startsWith(prefix + "."))
                apacheConfiguration.setProperty(trimPrefix ? key.substring(prefix.length() + 1) : key, value);
        }
        return apacheConfiguration;
    }
Generate a {@link Configuration} from the {@link System#getProperties}.
Only those properties with specified prefix key are aggregated.
If the prefix and a . should be removed, then trim prefix.

@param prefix     the prefix of the keys to include in the configuration
@param trimPrefix whether to trim the prefix + . from the key
@return a configuration generated from the System properties
gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/util/SystemUtil.java