Support user destinations without leading slash
Before this commit the DefaultUserDestinationResolver did not support well broker destinations that use dot as separator with a built in assumptions that the destinations it resolves must start with slash. This change adds PathMatcher property that is used to determine if an alternative path separator is in use and if so the leading slash is left out. Issue: SPR-14044
This commit is contained in:
@@ -573,6 +573,10 @@ class MessageBrokerBeanDefinitionParser implements BeanDefinitionParser {
|
||||
if (brokerElem.hasAttribute("user-destination-prefix")) {
|
||||
beanDef.getPropertyValues().add("userDestinationPrefix", brokerElem.getAttribute("user-destination-prefix"));
|
||||
}
|
||||
if (brokerElem.hasAttribute("path-matcher")) {
|
||||
String pathMatcherRef = brokerElem.getAttribute("path-matcher");
|
||||
beanDef.getPropertyValues().add("pathMatcher", new RuntimeBeanReference(pathMatcherRef));
|
||||
}
|
||||
return new RuntimeBeanReference(registerBeanDef(beanDef, context, source));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user