Skip to content

classpath*: is no longer finding resources with <import resource=""/> [SPR-6351] #11017

@spring-projects-issues

Description

@spring-projects-issues

Scott Andrews opened SPR-6351 and commented

Between RC1 and RC2, classpath*: file paths stopped working. In a web app context, I am importing a set of spring contexts that form a plugin system. None of the files that match this pattern are detected
<import resource="classpath*:META-INF/insight/insight-plugin-*.xml" />

Removing the wild card and hard coding the path also does not pickup the files.
<import resource="classpath*:META-INF/insight/insight-plugin-springmvc.xml" />

Replacing the classpath*: with classpath: it is able to find the file.
<import resource="classpath:META-INF/insight/insight-plugin-springmvc.xml" />

Using classpath: with a wild card only imports a single resource. (appears to be the first match alphabetically)
<import resource="classpath:META-INF/insight/insight-plugin-*.xml" />


Affects: 3.0 RC2

Issue Links:

1 votes, 0 watchers

Metadata

Metadata

Assignees

No one assigned

    Labels

    in: coreIssues in core modules (aop, beans, core, context, expression)type: bugA general bug

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions