Use of classpath*: / Windows
Cantor, Scott
cantor.2 at osu.edu
Tue Jun 23 10:00:16 EDT 2015
> Is the meat of the problem this:
>
> > the problem is that Spring is inconsistent in how it handles
> getResources() and getResource(). And
> > the second problem is that SWF is using both (the former for pattern
> flows, the latter for system/explicit flows).
I would say that's a problem if Spring chooses to implement something that works inconsistently in those two ways, and it does (I think).
> Or this:
>
> > Yes, but, the base-path of the SWF registry/repository needs the * if
> > classpath resources are in src/main/resources and test/main/resources
> > (multiple disjoint paths).
But that's the actual use case we have for trying to make this work at the moment. I'm not convinced yet we have others.
> If I understand the second, it seems to say that SWF is abusing the
> semantics of classpath* to mean something completely different,
No, not really, it's saying it wants all the files that match the expression across all possible classpath locations, and that's what Spring defines that to mean.
> Or is it both? Is there a sensible RFI/Bug that can be entered for this?
> Where 'sensible' means explainable and with a decent chance of being fixed
> since it seems to me that this behaviour is now baked into the SWF/Spring
> semantics and cannot be changed.
The RFI would be to implement getResource() for classpath*, which is basically what we did, but since it has undefined behavior when multiple resources exist, I suspect they'd balk at that.
I think the unintended consequence issue is that they maybe didn't realize SWF was allowing classpath* to work.
-- Scott
More information about the dev
mailing list