Cache Settings in SvnUtil
-------------------------
Key: SCM-535
URL: http://jira.codehaus.org/browse/SCM-535
Project: Maven SCM
Issue Type: Improvement
Components: maven-scm-provider-svn
Affects Versions: 1.4
Reporter: Jake Cobb
Attachments: SvnUtil.r686374.patch
{{SvnUtil.getSettings}} recreates the {{Settings}} every time it is called.
Attached is a simple patch to cache the {{Settings}}.
The current behavior is ugly for a couple of reasons. One, the settings cannot
be easily adjusted at runtime, this has no effect on the provider:
{noformat}SvnUtil.getSettings().setUseNonInteractive(false);{noformat}
Second, the way this class is used has terrible performance implications.
[SvnCommandLineUtils|https://svn.apache.org/repos/asf/maven/scm/trunk/maven-scm-providers/maven-scm-providers-svn/maven-scm-provider-svnexe/src/main/java/org/apache/maven/scm/provider/svn/svnexe/command/SvnCommandLineUtils.java]
calls it over and over. If the settings file is present, it will be re-parsed
numerous times during the execution of a single SVN command.
A similar patch should probably be applied to the GIT and CVS providers, which
appear to have copied the SvnUtil code.
[SCM-522|http://jira.codehaus.org/browse/SCM-522]
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira