diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/content/AbstractDefaultRepositoryContent.java b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/content/AbstractDefaultRepositoryContent.java index 07b02005a..8c685a72c 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/content/AbstractDefaultRepositoryContent.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/content/AbstractDefaultRepositoryContent.java @@ -82,7 +82,7 @@ public abstract class AbstractDefaultRepositoryContent public String toMetadataPath( ProjectReference reference ) { - StringBuffer path = new StringBuffer(); + StringBuilder path = new StringBuilder(); path.append( formatAsDirectory( reference.getGroupId() ) ).append( PATH_SEPARATOR ); path.append( reference.getArtifactId() ).append( PATH_SEPARATOR ); @@ -93,7 +93,7 @@ public abstract class AbstractDefaultRepositoryContent public String toMetadataPath( VersionedReference reference ) { - StringBuffer path = new StringBuffer(); + StringBuilder path = new StringBuilder(); path.append( formatAsDirectory( reference.getGroupId() ) ).append( PATH_SEPARATOR ); path.append( reference.getArtifactId() ).append( PATH_SEPARATOR ); diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/content/AbstractLegacyRepositoryContent.java b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/content/AbstractLegacyRepositoryContent.java index fb8e79ad7..e32d8d2d6 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/content/AbstractLegacyRepositoryContent.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/content/AbstractLegacyRepositoryContent.java @@ -87,7 +87,7 @@ public abstract class AbstractLegacyRepositoryContent private String toPath( String groupId, String artifactId, String version, String classifier, String type ) { - StringBuffer path = new StringBuffer(); + StringBuilder path = new StringBuilder(); path.append( groupId ).append( PATH_SEPARATOR ); path.append( getDirectory( type ) ).append( PATH_SEPARATOR ); diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/content/FilenameParser.java b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/content/FilenameParser.java index d3cc9bb46..1e2a09e8c 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/content/FilenameParser.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/content/FilenameParser.java @@ -227,7 +227,7 @@ public class FilenameParser { boolean done = false; - StringBuffer ver = new StringBuffer(); + StringBuilder ver = new StringBuilder(); while ( !done ) { diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/content/ManagedDefaultRepositoryContent.java b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/content/ManagedDefaultRepositoryContent.java index 3d2e68dec..1cc8f41a5 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/content/ManagedDefaultRepositoryContent.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/content/ManagedDefaultRepositoryContent.java @@ -140,7 +140,7 @@ public class ManagedDefaultRepositoryContent } catch ( LayoutException e ) { - log.debug( "Not processing file that is not an artifact: " + e.getMessage() ); + log.debug( "Not processing file that is not an artifact: {}", e.getMessage() ); } } } diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/metadata/MetadataTools.java b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/metadata/MetadataTools.java index 8491fdd30..2c50094b6 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/metadata/MetadataTools.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/metadata/MetadataTools.java @@ -222,7 +222,7 @@ public class MetadataTools reference.setArtifactId( pathParts[artifactIdOffset] ); - StringBuffer gid = new StringBuffer(); + StringBuilder gid = new StringBuilder(); for ( int i = 0; i <= groupIdEnd; i++ ) { if ( i > 0 ) @@ -262,7 +262,7 @@ public class MetadataTools reference.setArtifactId( pathParts[artifactIdOffset] ); - StringBuffer gid = new StringBuffer(); + StringBuilder gid = new StringBuilder(); for ( int i = 0; i <= groupIdEnd; i++ ) { if ( i > 0 ) @@ -279,7 +279,7 @@ public class MetadataTools public String toPath( ProjectReference reference ) { - StringBuffer path = new StringBuffer(); + StringBuilder path = new StringBuilder(); path.append( formatAsDirectory( reference.getGroupId() ) ).append( PATH_SEPARATOR ); path.append( reference.getArtifactId() ).append( PATH_SEPARATOR ); @@ -290,7 +290,7 @@ public class MetadataTools public String toPath( VersionedReference reference ) { - StringBuffer path = new StringBuffer(); + StringBuilder path = new StringBuilder(); path.append( formatAsDirectory( reference.getGroupId() ) ).append( PATH_SEPARATOR ); path.append( reference.getArtifactId() ).append( PATH_SEPARATOR ); @@ -330,7 +330,7 @@ public class MetadataTools */ public String getRepositorySpecificName( String proxyId, String path ) { - StringBuffer ret = new StringBuffer(); + StringBuilder ret = new StringBuilder(); int idx = path.lastIndexOf( "/" ); if ( idx > 0 )