class ConnectorOptions {

    public static String extractOption(Map<String, ?> options, String key, String defaultValue) {
        if (options == null) {
            return defaultValue;
        }

        return Optional.ofNullable(options.get(key))
            .map(Object::toString)
            .filter(v -> v.length() > 0)
            .orElse(defaultValue);
    }

    private  ConnectorOptions();

}