Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SPR-16838 PathMatchingResourcePatternResolver should enforce consistent alphabetical sorting of directory content #1832

Closed
wants to merge 1 commit into from

Conversation

benbenw
Copy link
Contributor

@benbenw benbenw commented May 18, 2018

A sort was added in SPR-14085 but the default File#compareTo depends
upon the underlying system.
The ordering of the ressources returned by
PathMatchingResourcePatternResolver#retrieveMatchingFiles may differ
between OS (Windows, Unix).
This leads to subtle bugs hard to track.
This PR replace the default sort with one based on the file name.

alphabetical sorting of directory content

A sort was added in SPR-14085 but the default File#compareTo depends
upon the underlying system.
The ordering of the ressources returned by
PathMatchingResourcePatternResolver#retrieveMatchingFiles may differ
between OS (Windows, Unix).
This leads to subtle bugs hard to track.
This PR replace the default sort with one based on the file name.
@jhoeller
Copy link
Contributor

As per my JIRA comments, resolved in a more extensive fashion. Thanks for the pull request, in any case!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants