Tim Moore created MDEP-368: ------------------------------ Summary: Configure plexus-archiver to use java.io.File methods to set permissions when available. Key: MDEP-368 URL: https://jira.codehaus.org/browse/MDEP-368 Project: Maven 2.x Dependency Plugin Issue Type: Improvement Components: unpack, unpack-dependencies Affects Versions: 2.5 Reporter: Tim Moore Attachments: useJvmChmod.patch
We updated from maven-dependency-plugin 2.4 to 2.5 in our build, and found that it slowed down significantly. Our build process involves unpacking several large zip files, and profiling the build showed us that the extra time was spent in Plexus Archiver's {{ArchiveEntryUtils.chmod}}, where it was executing a {{chmod}} process for each file in the archive. We tracked this change to an update of the Plexus Archiver dependency from 2.0 to 2.1.1 in version 2.5 of the Maven Dependency Plugin: http://svn.apache.org/viewvc?view=revision&revision=1292983 Plexus Archiver can be configured to use the {{setReadable}}, {{setWritable}} and {{setExecutable}} methods on {{java.io.File}} instead of executing {{chmod}}. These methods are new in Java 6, but Plexus Archiver invokes them using reflection when they are available, falling back on executing {{chmod}} when they are not, so it remains backwards compatible with Java 5. This configuration is disabled by default, but can be configured via Plexus. The attached patch to Maven Dependency Plugin sets the archiver components to use the JVM implementation when available. The patch doesn't include tests, since the behavior is dependent on the Java version used, but when applied all of the existing tests pass in Java 6. Credit for the investigation and the patch is due to Vincent Choy (vc...@atlassian.com). He asked me to file this issue on his behalf. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira