diff options
author | skygo <skygo@unknown> | 2013-03-14 22:12:24 +0000 |
---|---|---|
committer | skygo <skygo@unknown> | 2013-03-14 22:12:24 +0000 |
commit | 40c462af88fc5ab7e9c3f979a1944335bd931175 (patch) | |
tree | 98c674a86a59fe13050b4360f3f39d6b72c2c429 /archiva-modules/archiva-base | |
parent | 1af394618d7f66c1e6333432541e60d07ca7e233 (diff) | |
download | archiva-40c462af88fc5ab7e9c3f979a1944335bd931175.tar.gz archiva-40c462af88fc5ab7e9c3f979a1944335bd931175.zip |
fix imports and minors warning sonar.
remove a space in transactions name pom.
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1456696 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'archiva-modules/archiva-base')
18 files changed, 19 insertions, 30 deletions
diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ConfigurationListener.java b/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ConfigurationListener.java index d13157bc2..2abeb6371 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ConfigurationListener.java +++ b/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ConfigurationListener.java @@ -29,5 +29,5 @@ public interface ConfigurationListener /** * Generic event point to notify components that something has happend in the configuration. */ - public void configurationEvent( ConfigurationEvent event ); + void configurationEvent( ConfigurationEvent event ); } diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-api/src/main/java/org/apache/archiva/consumers/ConsumerMonitor.java b/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-api/src/main/java/org/apache/archiva/consumers/ConsumerMonitor.java index c762cf1fb..b6e2c81c6 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-api/src/main/java/org/apache/archiva/consumers/ConsumerMonitor.java +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-api/src/main/java/org/apache/archiva/consumers/ConsumerMonitor.java @@ -33,7 +33,7 @@ public interface ConsumerMonitor * @param type the type of error. * @param message the message about the error. */ - public void consumerError( Consumer consumer, String type, String message ); + void consumerError( Consumer consumer, String type, String message ); /** * A consumer warning event. @@ -42,7 +42,7 @@ public interface ConsumerMonitor * @param type the type of warning. * @param message the message about the warning. */ - public void consumerWarning( Consumer consumer, String type, String message ); + void consumerWarning( Consumer consumer, String type, String message ); /** * A consumer informational event. @@ -50,5 +50,5 @@ public interface ConsumerMonitor * @param consumer the consumer that caused the informational message. * @param message the message. */ - public void consumerInfo( Consumer consumer, String message ); + void consumerInfo( Consumer consumer, String message ); } diff --git a/archiva-modules/archiva-base/archiva-indexer/src/main/java/org/apache/archiva/indexer/merger/DefaultIndexMerger.java b/archiva-modules/archiva-base/archiva-indexer/src/main/java/org/apache/archiva/indexer/merger/DefaultIndexMerger.java index 8ed8205c3..1d4bfecfd 100644 --- a/archiva-modules/archiva-base/archiva-indexer/src/main/java/org/apache/archiva/indexer/merger/DefaultIndexMerger.java +++ b/archiva-modules/archiva-base/archiva-indexer/src/main/java/org/apache/archiva/indexer/merger/DefaultIndexMerger.java @@ -24,7 +24,6 @@ import org.apache.archiva.common.plexusbridge.MavenIndexerUtils; import org.apache.archiva.common.plexusbridge.PlexusSisuBridge; import org.apache.archiva.common.plexusbridge.PlexusSisuBridgeException; import org.apache.commons.io.FileUtils; -import org.apache.commons.lang.math.NumberUtils; import org.apache.commons.lang.time.StopWatch; import org.apache.maven.index.NexusIndexer; import org.apache.maven.index.context.IndexingContext; diff --git a/archiva-modules/archiva-base/archiva-indexer/src/main/java/org/apache/archiva/indexer/merger/IndexMerger.java b/archiva-modules/archiva-base/archiva-indexer/src/main/java/org/apache/archiva/indexer/merger/IndexMerger.java index b7d6fd487..462c3e4a1 100644 --- a/archiva-modules/archiva-base/archiva-indexer/src/main/java/org/apache/archiva/indexer/merger/IndexMerger.java +++ b/archiva-modules/archiva-base/archiva-indexer/src/main/java/org/apache/archiva/indexer/merger/IndexMerger.java @@ -32,7 +32,7 @@ public interface IndexMerger /** * system property which contains the value in s for ttl of temporary index groups */ - static final String TMP_GROUP_INDEX_SYS_KEY = "archiva.tmp.group.index.ttl"; + String TMP_GROUP_INDEX_SYS_KEY = "archiva.tmp.group.index.ttl"; /** * @param indexMergerRequest diff --git a/archiva-modules/archiva-base/archiva-indexer/src/main/java/org/apache/archiva/indexer/search/MavenRepositorySearch.java b/archiva-modules/archiva-base/archiva-indexer/src/main/java/org/apache/archiva/indexer/search/MavenRepositorySearch.java index 81059f9ff..3ec7502e1 100644 --- a/archiva-modules/archiva-base/archiva-indexer/src/main/java/org/apache/archiva/indexer/search/MavenRepositorySearch.java +++ b/archiva-modules/archiva-base/archiva-indexer/src/main/java/org/apache/archiva/indexer/search/MavenRepositorySearch.java @@ -39,7 +39,6 @@ import org.apache.maven.index.NexusIndexer; import org.apache.maven.index.OSGI; import org.apache.maven.index.context.IndexCreator; import org.apache.maven.index.context.IndexingContext; -import org.apache.maven.index.context.UnsupportedExistingLuceneIndexException; import org.apache.maven.index.expr.SourcedSearchExpression; import org.apache.maven.index.expr.UserInputSearchExpression; import org.slf4j.Logger; @@ -47,7 +46,6 @@ import org.slf4j.LoggerFactory; import org.springframework.stereotype.Service; import javax.inject.Inject; -import java.io.File; import java.io.IOException; import java.util.ArrayList; import java.util.Collection; diff --git a/archiva-modules/archiva-base/archiva-model/src/main/java/org/apache/archiva/model/ArchivaArtifactPlatformDetails.java b/archiva-modules/archiva-base/archiva-model/src/main/java/org/apache/archiva/model/ArchivaArtifactPlatformDetails.java index aea8bad2b..427ab0a98 100644 --- a/archiva-modules/archiva-base/archiva-model/src/main/java/org/apache/archiva/model/ArchivaArtifactPlatformDetails.java +++ b/archiva-modules/archiva-base/archiva-model/src/main/java/org/apache/archiva/model/ArchivaArtifactPlatformDetails.java @@ -26,5 +26,5 @@ package org.apache.archiva.model; */ public interface ArchivaArtifactPlatformDetails { - public String getPlatform(); + String getPlatform(); } diff --git a/archiva-modules/archiva-base/archiva-model/src/main/java/org/apache/archiva/model/CompoundKey.java b/archiva-modules/archiva-base/archiva-model/src/main/java/org/apache/archiva/model/CompoundKey.java index 6cd0ff9c7..1539d10fe 100644 --- a/archiva-modules/archiva-base/archiva-model/src/main/java/org/apache/archiva/model/CompoundKey.java +++ b/archiva-modules/archiva-base/archiva-model/src/main/java/org/apache/archiva/model/CompoundKey.java @@ -26,5 +26,5 @@ package org.apache.archiva.model; */ public interface CompoundKey { - public String toString(); + String toString(); } diff --git a/archiva-modules/archiva-base/archiva-policies/src/main/java/org/apache/archiva/policies/CachedFailuresPolicy.java b/archiva-modules/archiva-base/archiva-policies/src/main/java/org/apache/archiva/policies/CachedFailuresPolicy.java index bb1590037..bdb45b2e9 100644 --- a/archiva-modules/archiva-base/archiva-policies/src/main/java/org/apache/archiva/policies/CachedFailuresPolicy.java +++ b/archiva-modules/archiva-base/archiva-policies/src/main/java/org/apache/archiva/policies/CachedFailuresPolicy.java @@ -26,7 +26,6 @@ import org.slf4j.LoggerFactory; import org.springframework.stereotype.Service; import javax.inject.Inject; -import javax.inject.Named; import java.io.File; import java.util.ArrayList; import java.util.List; diff --git a/archiva-modules/archiva-base/archiva-policies/src/main/java/org/apache/archiva/policies/DownloadErrorPolicy.java b/archiva-modules/archiva-base/archiva-policies/src/main/java/org/apache/archiva/policies/DownloadErrorPolicy.java index d2a5aa23f..971afc763 100644 --- a/archiva-modules/archiva-base/archiva-policies/src/main/java/org/apache/archiva/policies/DownloadErrorPolicy.java +++ b/archiva-modules/archiva-base/archiva-policies/src/main/java/org/apache/archiva/policies/DownloadErrorPolicy.java @@ -43,7 +43,7 @@ public interface DownloadErrorPolicy * @return whether to process the exception or not * @throws PolicyConfigurationException if the policy is improperly configured */ - public boolean applyPolicy( String policySetting, Properties request, File localFile, Exception exception, + boolean applyPolicy( String policySetting, Properties request, File localFile, Exception exception, Map<String, Exception> previousExceptions ) throws PolicyConfigurationException; } diff --git a/archiva-modules/archiva-base/archiva-policies/src/main/java/org/apache/archiva/policies/DownloadPolicy.java b/archiva-modules/archiva-base/archiva-policies/src/main/java/org/apache/archiva/policies/DownloadPolicy.java index 41c365088..1a25043d6 100644 --- a/archiva-modules/archiva-base/archiva-policies/src/main/java/org/apache/archiva/policies/DownloadPolicy.java +++ b/archiva-modules/archiva-base/archiva-policies/src/main/java/org/apache/archiva/policies/DownloadPolicy.java @@ -40,6 +40,6 @@ public interface DownloadPolicy * * @throws PolicyViolationException if the policy has been violated. */ - public void applyPolicy( String policySetting, Properties request, File localFile ) + void applyPolicy( String policySetting, Properties request, File localFile ) throws PolicyViolationException, PolicyConfigurationException; } diff --git a/archiva-modules/archiva-base/archiva-proxy-api/src/main/java/org/apache/archiva/proxy/model/RepositoryProxyConnectors.java b/archiva-modules/archiva-base/archiva-proxy-api/src/main/java/org/apache/archiva/proxy/model/RepositoryProxyConnectors.java index 58a3aaf3a..37b373219 100644 --- a/archiva-modules/archiva-base/archiva-proxy-api/src/main/java/org/apache/archiva/proxy/model/RepositoryProxyConnectors.java +++ b/archiva-modules/archiva-base/archiva-proxy-api/src/main/java/org/apache/archiva/proxy/model/RepositoryProxyConnectors.java @@ -45,7 +45,7 @@ public interface RepositoryProxyConnectors * @return the file that was obtained, or null if no content was obtained * @throws ProxyDownloadException if there was a problem fetching the content from the target repositories. */ - public File fetchFromProxies( ManagedRepositoryContent repository, ArtifactReference artifact ) + File fetchFromProxies( ManagedRepositoryContent repository, ArtifactReference artifact ) throws ProxyDownloadException; /** @@ -59,7 +59,7 @@ public interface RepositoryProxyConnectors * @param logicalPath the metadata to fetch. * @return the file that was obtained, or null if no content was obtained */ - public File fetchMetatadaFromProxies( ManagedRepositoryContent repository, String logicalPath ); + File fetchMetatadaFromProxies( ManagedRepositoryContent repository, String logicalPath ); /** * Performs the fetch operation against the target repositories @@ -69,7 +69,7 @@ public interface RepositoryProxyConnectors * @param path the path of the resource to fetch * @return the file that was obtained, or null if no content was obtained */ - public File fetchFromProxies( ManagedRepositoryContent managedRepository, String path ); + File fetchFromProxies( ManagedRepositoryContent managedRepository, String path ); /** * Get the List of {@link ProxyConnector} objects of the source repository. @@ -77,7 +77,7 @@ public interface RepositoryProxyConnectors * @param repository the source repository to look for. * @return the List of {@link ProxyConnector} objects. */ - public List<ProxyConnector> getProxyConnectors( ManagedRepositoryContent repository ); + List<ProxyConnector> getProxyConnectors( ManagedRepositoryContent repository ); /** * Tests to see if the provided repository is a source repository for @@ -87,5 +87,5 @@ public interface RepositoryProxyConnectors * @return true if there are proxy connectors that use the provided * repository as a source repository. */ - public boolean hasProxies( ManagedRepositoryContent repository ); + boolean hasProxies( ManagedRepositoryContent repository ); } diff --git a/archiva-modules/archiva-base/archiva-proxy/src/main/java/org/apache/archiva/proxy/DefaultRepositoryProxyConnectors.java b/archiva-modules/archiva-base/archiva-proxy/src/main/java/org/apache/archiva/proxy/DefaultRepositoryProxyConnectors.java index 188437187..687a2d1c7 100644 --- a/archiva-modules/archiva-base/archiva-proxy/src/main/java/org/apache/archiva/proxy/DefaultRepositoryProxyConnectors.java +++ b/archiva-modules/archiva-base/archiva-proxy/src/main/java/org/apache/archiva/proxy/DefaultRepositoryProxyConnectors.java @@ -76,8 +76,6 @@ import org.apache.tools.ant.types.selectors.SelectorUtils; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.slf4j.MarkerFactory; -import org.slf4j.helpers.BasicMarker; -import org.slf4j.helpers.BasicMarkerFactory; import org.springframework.stereotype.Service; import javax.annotation.PostConstruct; diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-api/src/main/java/org/apache/archiva/admin/model/RepositoryCommonValidator.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-api/src/main/java/org/apache/archiva/admin/model/RepositoryCommonValidator.java index 447d5fb62..0983e0aa8 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-api/src/main/java/org/apache/archiva/admin/model/RepositoryCommonValidator.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-api/src/main/java/org/apache/archiva/admin/model/RepositoryCommonValidator.java @@ -31,9 +31,9 @@ import org.apache.archiva.admin.model.beans.ManagedRepository; public interface RepositoryCommonValidator { - public static final String REPOSITORY_ID_VALID_EXPRESSION = "^[a-zA-Z0-9._-]+$"; + String REPOSITORY_ID_VALID_EXPRESSION = "^[a-zA-Z0-9._-]+$"; - public static final String REPOSITORY_NAME_VALID_EXPRESSION = "^([a-zA-Z0-9.)/_(-]|\\s)+$"; + String REPOSITORY_NAME_VALID_EXPRESSION = "^([a-zA-Z0-9.)/_(-]|\\s)+$"; void basicValidation( AbstractRepository abstractRepository, boolean update ) diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-api/src/main/java/org/apache/archiva/admin/model/proxyconnector/ProxyConnectorAdmin.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-api/src/main/java/org/apache/archiva/admin/model/proxyconnector/ProxyConnectorAdmin.java index 256633d49..f06a1e6ea 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-api/src/main/java/org/apache/archiva/admin/model/proxyconnector/ProxyConnectorAdmin.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-api/src/main/java/org/apache/archiva/admin/model/proxyconnector/ProxyConnectorAdmin.java @@ -21,7 +21,6 @@ package org.apache.archiva.admin.model.proxyconnector; import org.apache.archiva.admin.model.AuditInformation; import org.apache.archiva.admin.model.RepositoryAdminException; import org.apache.archiva.admin.model.beans.ProxyConnector; -import org.apache.archiva.admin.model.beans.ProxyConnectorRule; import java.util.List; import java.util.Map; diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/admin/DefaultArchivaAdministration.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/admin/DefaultArchivaAdministration.java index d15644f63..e95862539 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/admin/DefaultArchivaAdministration.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/admin/DefaultArchivaAdministration.java @@ -33,9 +33,7 @@ import org.apache.archiva.configuration.Configuration; import org.apache.archiva.configuration.UserInterfaceOptions; import org.apache.archiva.configuration.WebappConfiguration; import org.apache.commons.lang.StringUtils; -import org.apache.http.conn.ClientConnectionManager; import org.apache.http.impl.conn.PoolingClientConnectionManager; -import org.apache.http.impl.conn.tsccm.ThreadSafeClientConnManager; import org.apache.maven.wagon.providers.http.HttpWagon; import org.springframework.stereotype.Service; diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/metadata/RepositoryMetadataWriter.java b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/metadata/RepositoryMetadataWriter.java index 3f0632903..535be967e 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/metadata/RepositoryMetadataWriter.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/metadata/RepositoryMetadataWriter.java @@ -36,7 +36,6 @@ import java.io.FileWriter; import java.io.IOException; import java.io.Writer; import java.util.Iterator; -import java.util.List; /** * RepositoryMetadataWriter diff --git a/archiva-modules/archiva-base/archiva-repository-scanner/src/main/java/org/apache/archiva/repository/scanner/RepositoryScanner.java b/archiva-modules/archiva-base/archiva-repository-scanner/src/main/java/org/apache/archiva/repository/scanner/RepositoryScanner.java index f5db9657a..562cd2713 100644 --- a/archiva-modules/archiva-base/archiva-repository-scanner/src/main/java/org/apache/archiva/repository/scanner/RepositoryScanner.java +++ b/archiva-modules/archiva-base/archiva-repository-scanner/src/main/java/org/apache/archiva/repository/scanner/RepositoryScanner.java @@ -22,7 +22,6 @@ package org.apache.archiva.repository.scanner; import org.apache.archiva.admin.model.beans.ManagedRepository; import org.apache.archiva.consumers.InvalidRepositoryContentConsumer; import org.apache.archiva.consumers.KnownRepositoryContentConsumer; -import org.springframework.scheduling.annotation.Async; import java.util.List; import java.util.Set; @@ -38,7 +37,7 @@ public interface RepositoryScanner * The value to pass to {@link #scan(ManagedRepository, long)} to have the scan * operate in a fresh fashion, with no check on changes based on timestamp. */ - public static final long FRESH_SCAN = 0; + long FRESH_SCAN = 0; /** * <p> @@ -53,7 +52,7 @@ public interface RepositoryScanner * These patterns are only valid for archiva-cli and archiva-converter use. * </p> */ - public static final String[] IGNORABLE_CONTENT = + static final String[] IGNORABLE_CONTENT = { "bin/**", "reports/**", ".index", ".reports/**", ".maven/**", "**/.svn/**", "**/*snapshot-version", "*/website/**", "*/licences/**", "**/.htaccess", "**/*.html", "**/*.txt", "**/README*", "**/CHANGELOG*", "**/KEYS*", ".indexer" }; diff --git a/archiva-modules/archiva-base/archiva-transaction/pom.xml b/archiva-modules/archiva-base/archiva-transaction/pom.xml index 8dd180476..007b4c2b2 100644 --- a/archiva-modules/archiva-base/archiva-transaction/pom.xml +++ b/archiva-modules/archiva-base/archiva-transaction/pom.xml @@ -26,7 +26,7 @@ </parent> <artifactId>archiva-transaction</artifactId> <packaging>bundle</packaging> - <name>Archiva Base :: Transactions</name> + <name>Archiva Base :: Transactions</name> <description>API for managing transaction.</description> <dependencies> <dependency> |