Hi,

I'm trying to use NotifyBuilder for a test, and am running into a matching 
issue regarding the "from" method. My route looks like

From( "sjms2:queue:my-queue-name?transacted=true&consumerCount=1")
//processing here

I use NotifyBuilder like this:

NotifyBuilder notifyBuilder = new NotifyBuilder(context)
                
.from("sjms2:queue:my-queue-name?transacted=true&consumerCount=1")
                .whenDone(1)
                .create()

Followed by a call to matches(). When I run the test, the NotifyBuilder fails 
to match.
The NotifyBuilder uses the EndpointHelper to match from endpoint URIs, and the 
call I'm seeing return false has the following parameters:

EndpointHelper.matchEndpoint(context, uri = 
"sjms2://queue:my-queue-name?consumerCount=1&transacted=true", pattern = 
"sjms2:queue:my-queue-name?transacted=true&consumerCount=1")

I would expect these values to match, but the EndpointHelper handles reordered 
query parameters by normalizing the "uri" parameter, but not the "pattern" 
parameter. As the "uri" parameter is already normalized, these values end up 
not matching.

Should I raise an issue for this, or is this a known limitation?

Reply via email to