UrlMapping.getPatternParser() is called quite often. This should be no problem if the pattern parser was cached. But the dirty-flag is never set to false, so a new pattern parser will be created for every call to UrlMapping.getPatternParser().
If I had an idea, when to set the dirty flag to false, I could fix it.
Could you perhaps give the latest snapshots a try (3.3.1-SNAPSHOT)? They should be automatically deployed to our repository in about 20 minutes. You will find all the details you need to include the snapshots in your project here:
These methods always create new Pattern instances. If you have a regex, try to compile it and reuse it. If you don’t have a regex, just use one of the org.apache.commons.lang.StringUtils methods. Or simply String.indexOf(…).
Hope this helps.
PS: to check if the sessionid is in the url, just use javax.servlet.http.HttpServletRequest#isRequestedSessionIdFromURL