I have 2 flows,
1. Condition proxy.pathsuffix MatchesPath /{id}/text
2. Condition proxy.pathsuffix MatchesPath /{id}
When I pass the URL as http://www.test.com/text, it is going to second condition since the condition is satisfied and id gets the value text. Is there a way to handle this issue
Dear @Rashmi.Murthy1 ,
Yes, It's possible. You can use regular expression to do this. Use JavaRegex. For more details refer here.
Or you can just say
proxy.pathsuffix MatchesPath **/text
Cheers,
Anil Sagar
Hi Anil
Thanks for responding. We are more interested in throwing back an error if id is not passed in the URL mentioned above.
http://www.test.com/text - should yield an error since id is not passed. But it goes to Condition 2, and treats text as id, which we dont need.
Please let us know, if there is a way to handle this. I see that there is something called startsWith operartor to check the suffix. What we are looking for is more of endsWith kind of operator.
Dear @Meghna.Madhusudan ,
You need to use Raise Fault policy and use condition as proxy.pathsuffix MatchesPath /text to raise custom error.
Cheers,
Anil Sagar
User | Count |
---|---|
1 | |
1 | |
1 | |
1 | |
1 |