Skip to content

Remove GraalVM workaround in PathMatchingResourcePatternResolver #29214

Closed
@sbrannen

Description

@sbrannen

This is a follow up to #29163.

Once oracle/graal#5080 and oracle/graal#5081 have been resolved (tentatively in GraalVM 22.3), we should be able to remove the following workaround in PathMatchingResourcePatternResolver.

// If the URI is for a "resource" in the GraalVM native image file system, we have to
// ensure that the root directory does not end in a slash while simultaneously ensuring
// that the root directory is not an empty string (since fileSystem.getPath("").resolve(str)
// throws an ArrayIndexOutOfBoundsException in a native image).
if ("resource".equals(rootDirUri.getScheme()) && (rootDir.length() > 1) && rootDir.endsWith("/")) {
rootDir = rootDir.substring(0, rootDir.length() - 1);
}

Metadata

Metadata

Assignees

Labels

in: coreIssues in core modules (aop, beans, core, context, expression)theme: aotAn issue related to Ahead-of-time processing

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions