[
https://jira.codehaus.org/browse/JBEHAVE-617?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Mauro Talevi resolved JBEHAVE-617.
----------------------------------
Resolution: Fixed
Applied with thanks.
Also created a examples/performance module where we can verify the performance
related behaviour.
Feel free to contribute any story of which you'd want to test performance
issues.
> Speed up RegexStoryParser by removing leading .*
> ------------------------------------------------
>
> Key: JBEHAVE-617
> URL: https://jira.codehaus.org/browse/JBEHAVE-617
> Project: JBehave
> Issue Type: Improvement
> Components: Core
> Affects Versions: 3.4
> Reporter: Laura Dean
> Assignee: Mauro Talevi
> Fix For: 3.5.4, 3.6
>
> Attachments: jbehave-regex.diff
>
>
> We noticed our jbehave tests taking a long time. Mostly our fault, but also
> a surprising amount of time spent in Matcher.find() from RegexStoryParser,
> said the profiler. Who knew? Turns out, that happens when you call find()
> on long lines and your regex starts with .* , as this guy explains:
> http://www.fasterj.com/articles/regex2.shtml
> So we removed it, and our tests ran a little faster. (We removed it only
> from the expressions used with find(); we didn't touch the ones using
> matches().)
> And your tests run a lot faster!
> Unfortunately, I don't know how to prevent regression here. I don't see
> performance tests, and the behavior didn't change. (You can note how long
> things take on the continuous integration server, though.) And it's pretty
> easy to imagine someone coming through and making the regular expressions all
> look the same. Still, there you have it.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email