pentaho/pentaho-kettle · error · FileSystemException

vfs.provider/missing-double-slashes.error

vfs.provider/missing-double-slashes.error

Error message

vfs.provider/missing-double-slashes.error

What it means

After extracting the scheme, extractPvfsScheme requires the remainder of the URI to start with '//' (the authority delimiter preceding the connection name), mirroring Commons VFS HostFileNameParser. Backslashes are not accepted. If the URI lacks the double slashes — e.g. 'pvfs:my-connection/folder' — a FileSystemException with message 'vfs.provider/missing-double-slashes.error' is thrown, parameterised with the offending URI.

Solutions

  1. Format the URI as scheme + '//' + connectionName + path: 'pvfs://my-connection/folder'.
  2. Replace backslashes with forward slashes before parsing (UriParser.fixSeparators or manual replace).
  3. Validate the URI contains '://' before calling parseUri.
  4. Normalize single leading slash after the scheme to a double slash in configuration cleanup code.

Example fix

// before
String uri = "pvfs:my-connection/folder";
parser.parseUri( uri ); // throws missing-double-slashes
// after
String uri = "pvfs://my-connection/folder";
parser.parseUri( uri ); // ok
Defensive patterns

Strategy: validation

Validate before calling

String normalized = uri.replace( '\\', '/' );
int i = normalized.indexOf( ':' );
if ( i >= 0 && !normalized.startsWith( "//", i + 1 ) ) {
  normalized = normalized.substring( 0, i + 1 ) + "/" + normalized.substring( i + 1 );
}

Type guard

boolean hasDoubleSlash( String uri ) {
  int i = uri.indexOf( ':' );
  return i >= 0 && uri.startsWith( "//", i + 1 );
}

Try / catch

try {
  return parser.parseUri( uri );
} catch ( FileSystemException e ) {
  if ( String.valueOf( e.getMessage() ).startsWith( "vfs.provider/missing-double-slashes" ) ) {
    // normalize separators / add '//' and retry
  }
  throw e;
}

Prevention

When it happens

Trigger: Parsing 'pvfs:my-connection/path' (single colon, no '//'), 'pvfs:/one-slash/path', or any URI using backslashes ('pvfs:\\conn') instead of forward slashes after the scheme.

Common situations: Hand-written URIs missing the authority part; string building with 'pvfs:' + name; Windows-style paths pasted with backslash separators into connection settings.

Understand the failure class

Background: "Invalid URL" errors: why new URL(), URI.parse, and reqwest::Url reject your string — missing scheme, whitespace, and bad path format — this error's family across 39 libraries.

Related errors


AI-assisted analysis of pentaho/pentaho-kettle@f3058517a1 (2026-09-13). Data as JSON: /api/errors/85d6309250109f72. Report an issue: GitHub.

Appendix: source

Thrown at core/src/main/java/org/pentaho/di/connections/vfs/provider/ConnectionFileNameParser.java:287

    // Examples: name = "/" | "/Folder/Sub Folder/100%25"

    String path = name.toString();

    return new ConnectionFileName( connectionName, path, fileType );
  }

  private void extractPvfsScheme( String uri, StringBuilder name ) throws FileSystemException {
    // UriParser.extractScheme initializes `name` with the contents of uri, and only then extracts the scheme.
    // Scheme may not be present, or invalid (e.g. drive letter), in which case null is returned.
    if ( UriParser.extractScheme( SCHEMES, uri, name ) == null ) {
      throw new FileSystemException( "vfs.provider/invalid-scheme" );
    }

    // Extract "//" (based on HostFileNameParser#parseUri(..))
    // These two are not supported as "\".
    if ( name.length() < 2 || name.charAt( 0 ) != SEPARATOR_CHAR || name.charAt( 1 ) != SEPARATOR_CHAR ) {
      throw new FileSystemException( "vfs.provider/missing-double-slashes.error", uri );
    }

    name.delete( 0, 2 );
  }
}

View on GitHub (pinned to f3058517a1)