[
https://issues.apache.org/jira/browse/CAMEL-22739?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
James Netherton resolved CAMEL-22739.
-------------------------------------
Resolution: Fixed
> camel-main: Avoid potential duplicate route resources in
> DefaultRoutesCollector.findRouteResourcesFromDirectory
> ---------------------------------------------------------------------------------------------------------------
>
> Key: CAMEL-22739
> URL: https://issues.apache.org/jira/browse/CAMEL-22739
> Project: Camel
> Issue Type: Improvement
> Components: camel-main
> Reporter: James Netherton
> Assignee: James Netherton
> Priority: Minor
> Fix For: 4.17.0
>
>
> DefaultRoutesCollector.findRouteResourcesFromDirectory currently places
> discovered route resources into an ArrayList. Depending on the
> routes-include-pattern(s) used, there's the potential that duplicate
> resources could get added. Hence it might be better to use a Set instead.
> E.g if you have overlapping wildcard inclusion patterns, the resource
> resolver will recursively match resources for the file: scheme. So you can
> end up with duplicates being collected.
> It's maybe a bit of an edge case, but I think we should try to avoid it
> happening by default.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)