From ea4413d1a06182ae2413379ed8aa3075ff58df4f Mon Sep 17 00:00:00 2001 From: Martin Stockhammer Date: Fri, 24 Dec 2021 13:48:22 +0100 Subject: [PATCH] Refactoring package names for maven proxy module --- .../admin/mock/ArchivaIndexManagerMock.java | 6 +++--- .../proxy/DebugTransferListener.java | 2 +- .../{ => common}/proxy/DefaultWagonFactory.java | 2 +- .../maven/{ => common}/proxy/WagonFactory.java | 2 +- .../proxy/WagonFactoryException.java | 2 +- .../{ => common}/proxy/WagonFactoryRequest.java | 2 +- .../main/resources/META-INF/spring-context.xml | 2 +- .../maven/indexer/MavenIndexManager.java | 6 +++--- .../src/test/resources/spring-context.xml | 2 +- .../{maven2 => maven}/model/Artifact.java | 5 ++--- .../{maven2 => maven}/model/TreeEntry.java | 5 ++--- .../{maven2 => maven}/model/ModelTest.java | 5 ++--- .../archiva-maven/archiva-maven-proxy/pom.xml | 17 +++++++++++++++++ .../proxy/MavenRepositoryProxyHandler.java | 5 ++++- .../main/resources/META-INF/spring-context.xml | 2 +- .../common/proxy}/WagonFactoryTest.java | 9 ++++----- .../proxy/AbstractProxyTestCase.java | 6 +++--- .../proxy/CacheFailuresTransferTest.java | 5 ++--- .../{ => maven}/proxy/ChecksumTransferTest.java | 5 ++--- .../{ => maven}/proxy/ErrorHandlingTest.java | 5 ++--- .../proxy/HttpProxyTransferTest.java | 6 +++--- .../proxy/ManagedDefaultTransferTest.java | 5 ++--- .../{ => maven}/proxy/MetadataTransferTest.java | 5 ++--- .../{ => maven}/proxy/MockConfiguration.java | 5 ++--- .../{ => maven}/proxy/SnapshotTransferTest.java | 5 ++--- .../{ => maven}/proxy/WagonDelegate.java | 5 ++--- .../MockRepositoryArchivaTaskScheduler.java | 5 ++--- .../repository}/ArchivaIndexManagerMock.java | 5 ++--- .../ManagedRepositoryContentMock.java | 5 ++--- .../RemoteRepositoryContentMock.java | 5 ++--- .../RepositoryContentProviderMock.java | 5 ++--- .../repository}/RepositoryProviderMock.java | 5 ++--- .../test/resources/META-INF/spring-context.xml | 2 +- .../src/test/resources/spring-context.xml | 6 +++--- .../dependency/tree/DependencyTreeBuilder.java | 2 +- .../tree/Maven3DependencyTreeBuilder.java | 2 +- .../tree/TreeDependencyNodeVisitor.java | 4 ++-- .../storage/Maven2RepositoryStorage.java | 2 +- .../storage/RepositoryModelResolver.java | 6 +++--- .../tree/DependencyTreeBuilderTestMaven3.java | 4 ++-- ...oryMetadataResolverMRM1411RepoGroupTest.java | 4 ++-- ...n2RepositoryMetadataResolverMRM1411Test.java | 4 ++-- ...itoryMetadataResolverManagedReleaseTest.java | 2 +- .../Maven2RepositoryMetadataResolverTest.java | 4 ++-- .../maven/mock/ArchivaIndexManagerMock.java | 6 +++--- .../DefaultDownloadRemoteIndexScheduler.java | 2 +- .../indexing/maven/DownloadRemoteIndexTask.java | 4 ++-- .../maven/DownloadRemoteIndexTaskRequest.java | 2 +- .../archiva/mock/ArchivaIndexManagerMock.java | 6 +++--- .../rest/api/model/ArtifactTransferRequest.java | 2 +- .../rest/api/services/BrowseService.java | 4 ++-- .../api/services/MergeRepositoriesService.java | 2 +- .../rest/api/services/RepositoriesService.java | 2 +- .../rest/api/services/SearchService.java | 2 +- .../rest/services/AbstractRestService.java | 2 +- .../rest/services/DefaultBrowseService.java | 4 ++-- .../DefaultMergeRepositoriesService.java | 2 +- .../DefaultRemoteRepositoriesService.java | 4 ++-- .../services/DefaultRepositoriesService.java | 2 +- .../rest/services/DefaultSearchService.java | 2 +- .../rest/services/utils/ArtifactBuilder.java | 2 +- .../rest/services/BrowseServiceTest.java | 2 +- .../services/MergeRepositoriesServiceTest.java | 4 +--- .../rest/services/RepositoriesServiceTest.java | 2 +- .../rest/services/SearchServiceTest.java | 2 +- .../DownloadMergedIndexNonDefaultPathTest.java | 3 +-- .../remotedownload/DownloadMergedIndexTest.java | 3 +-- 67 files changed, 131 insertions(+), 133 deletions(-) rename archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/{ => common}/proxy/DebugTransferListener.java (98%) rename archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/{ => common}/proxy/DefaultWagonFactory.java (98%) rename archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/{ => common}/proxy/WagonFactory.java (96%) rename archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/{ => common}/proxy/WagonFactoryException.java (95%) rename archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/{ => common}/proxy/WagonFactoryRequest.java (98%) rename archiva-modules/archiva-maven/archiva-maven-model/src/main/java/org/apache/archiva/{maven2 => maven}/model/Artifact.java (99%) rename archiva-modules/archiva-maven/archiva-maven-model/src/main/java/org/apache/archiva/{maven2 => maven}/model/TreeEntry.java (96%) rename archiva-modules/archiva-maven/archiva-maven-model/src/test/java/org/apache/archiva/{maven2 => maven}/model/ModelTest.java (96%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{proxy/common => maven/common/proxy}/WagonFactoryTest.java (89%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{ => maven}/proxy/AbstractProxyTestCase.java (99%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{ => maven}/proxy/CacheFailuresTransferTest.java (98%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{ => maven}/proxy/ChecksumTransferTest.java (99%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{ => maven}/proxy/ErrorHandlingTest.java (99%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{ => maven}/proxy/HttpProxyTransferTest.java (98%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{ => maven}/proxy/ManagedDefaultTransferTest.java (99%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{ => maven}/proxy/MetadataTransferTest.java (99%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{ => maven}/proxy/MockConfiguration.java (98%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{ => maven}/proxy/SnapshotTransferTest.java (99%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{ => maven}/proxy/WagonDelegate.java (98%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{ => maven/proxy/mock}/metadata/repository/MockRepositoryArchivaTaskScheduler.java (93%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{repository/mock => maven/proxy/mock/repository}/ArchivaIndexManagerMock.java (96%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{repository/mock => maven/proxy/mock/repository}/ManagedRepositoryContentMock.java (99%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{repository/mock => maven/proxy/mock/repository}/RemoteRepositoryContentMock.java (96%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{repository/mock => maven/proxy/mock/repository}/RepositoryContentProviderMock.java (95%) rename archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/{repository/mock => maven/proxy/mock/repository}/RepositoryProviderMock.java (99%) diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/test/java/org/apache/archiva/admin/mock/ArchivaIndexManagerMock.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/test/java/org/apache/archiva/admin/mock/ArchivaIndexManagerMock.java index 8b2d1f608..6fbfa9589 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/test/java/org/apache/archiva/admin/mock/ArchivaIndexManagerMock.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/test/java/org/apache/archiva/admin/mock/ArchivaIndexManagerMock.java @@ -28,9 +28,9 @@ import org.apache.archiva.indexer.IndexCreationFailedException; import org.apache.archiva.indexer.IndexUpdateFailedException; import org.apache.archiva.indexer.UnsupportedBaseContextException; import org.apache.archiva.proxy.ProxyRegistry; -import org.apache.archiva.maven.proxy.WagonFactory; -import org.apache.archiva.maven.proxy.WagonFactoryException; -import org.apache.archiva.maven.proxy.WagonFactoryRequest; +import org.apache.archiva.maven.common.proxy.WagonFactory; +import org.apache.archiva.maven.common.proxy.WagonFactoryException; +import org.apache.archiva.maven.common.proxy.WagonFactoryRequest; import org.apache.archiva.proxy.model.NetworkProxy; import org.apache.archiva.repository.EditableRepository; import org.apache.archiva.repository.ManagedRepository; diff --git a/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/proxy/DebugTransferListener.java b/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/common/proxy/DebugTransferListener.java similarity index 98% rename from archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/proxy/DebugTransferListener.java rename to archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/common/proxy/DebugTransferListener.java index 77a833fd1..cf885ea16 100644 --- a/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/proxy/DebugTransferListener.java +++ b/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/common/proxy/DebugTransferListener.java @@ -1,4 +1,4 @@ -package org.apache.archiva.maven.proxy; +package org.apache.archiva.maven.common.proxy; /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file diff --git a/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/proxy/DefaultWagonFactory.java b/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/common/proxy/DefaultWagonFactory.java similarity index 98% rename from archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/proxy/DefaultWagonFactory.java rename to archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/common/proxy/DefaultWagonFactory.java index 6ce2d0bdc..2e54de06d 100644 --- a/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/proxy/DefaultWagonFactory.java +++ b/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/common/proxy/DefaultWagonFactory.java @@ -1,4 +1,4 @@ -package org.apache.archiva.maven.proxy; +package org.apache.archiva.maven.common.proxy; /* * Licensed to the Apache Software Foundation (ASF) under one diff --git a/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/proxy/WagonFactory.java b/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/common/proxy/WagonFactory.java similarity index 96% rename from archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/proxy/WagonFactory.java rename to archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/common/proxy/WagonFactory.java index df05f1778..4d0333fcf 100644 --- a/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/proxy/WagonFactory.java +++ b/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/common/proxy/WagonFactory.java @@ -1,4 +1,4 @@ -package org.apache.archiva.maven.proxy; +package org.apache.archiva.maven.common.proxy; /* * Licensed to the Apache Software Foundation (ASF) under one diff --git a/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/proxy/WagonFactoryException.java b/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/common/proxy/WagonFactoryException.java similarity index 95% rename from archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/proxy/WagonFactoryException.java rename to archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/common/proxy/WagonFactoryException.java index 0e349d4ed..2b7bdcb88 100755 --- a/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/proxy/WagonFactoryException.java +++ b/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/common/proxy/WagonFactoryException.java @@ -1,4 +1,4 @@ -package org.apache.archiva.maven.proxy; +package org.apache.archiva.maven.common.proxy; /* * Licensed to the Apache Software Foundation (ASF) under one diff --git a/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/proxy/WagonFactoryRequest.java b/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/common/proxy/WagonFactoryRequest.java similarity index 98% rename from archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/proxy/WagonFactoryRequest.java rename to archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/common/proxy/WagonFactoryRequest.java index 6980c5f8b..d4d81fb5e 100644 --- a/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/proxy/WagonFactoryRequest.java +++ b/archiva-modules/archiva-maven/archiva-maven-common/src/main/java/org/apache/archiva/maven/common/proxy/WagonFactoryRequest.java @@ -1,4 +1,4 @@ -package org.apache.archiva.maven.proxy; +package org.apache.archiva.maven.common.proxy; /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file diff --git a/archiva-modules/archiva-maven/archiva-maven-common/src/main/resources/META-INF/spring-context.xml b/archiva-modules/archiva-maven/archiva-maven-common/src/main/resources/META-INF/spring-context.xml index 2f61235d7..ff20c35dd 100644 --- a/archiva-modules/archiva-maven/archiva-maven-common/src/main/resources/META-INF/spring-context.xml +++ b/archiva-modules/archiva-maven/archiva-maven-common/src/main/resources/META-INF/spring-context.xml @@ -28,6 +28,6 @@ default-lazy-init="true"> - + \ No newline at end of file diff --git a/archiva-modules/archiva-maven/archiva-maven-indexer/src/main/java/org/apache/archiva/maven/indexer/MavenIndexManager.java b/archiva-modules/archiva-maven/archiva-maven-indexer/src/main/java/org/apache/archiva/maven/indexer/MavenIndexManager.java index e45cfb8c1..512c74194 100644 --- a/archiva-modules/archiva-maven/archiva-maven-indexer/src/main/java/org/apache/archiva/maven/indexer/MavenIndexManager.java +++ b/archiva-modules/archiva-maven/archiva-maven-indexer/src/main/java/org/apache/archiva/maven/indexer/MavenIndexManager.java @@ -27,9 +27,9 @@ import org.apache.archiva.indexer.IndexCreationFailedException; import org.apache.archiva.indexer.IndexUpdateFailedException; import org.apache.archiva.indexer.UnsupportedBaseContextException; import org.apache.archiva.proxy.ProxyRegistry; -import org.apache.archiva.maven.proxy.WagonFactory; -import org.apache.archiva.maven.proxy.WagonFactoryException; -import org.apache.archiva.maven.proxy.WagonFactoryRequest; +import org.apache.archiva.maven.common.proxy.WagonFactory; +import org.apache.archiva.maven.common.proxy.WagonFactoryException; +import org.apache.archiva.maven.common.proxy.WagonFactoryRequest; import org.apache.archiva.proxy.model.NetworkProxy; import org.apache.archiva.repository.EditableRepository; import org.apache.archiva.repository.ManagedRepository; diff --git a/archiva-modules/archiva-maven/archiva-maven-indexer/src/test/resources/spring-context.xml b/archiva-modules/archiva-maven/archiva-maven-indexer/src/test/resources/spring-context.xml index c734bbc98..0fc9f1d62 100644 --- a/archiva-modules/archiva-maven/archiva-maven-indexer/src/test/resources/spring-context.xml +++ b/archiva-modules/archiva-maven/archiva-maven-indexer/src/test/resources/spring-context.xml @@ -28,7 +28,7 @@ default-lazy-init="false"> - + diff --git a/archiva-modules/archiva-maven/archiva-maven-model/src/main/java/org/apache/archiva/maven2/model/Artifact.java b/archiva-modules/archiva-maven/archiva-maven-model/src/main/java/org/apache/archiva/maven/model/Artifact.java similarity index 99% rename from archiva-modules/archiva-maven/archiva-maven-model/src/main/java/org/apache/archiva/maven2/model/Artifact.java rename to archiva-modules/archiva-maven/archiva-maven-model/src/main/java/org/apache/archiva/maven/model/Artifact.java index cf010b309..6f8b14019 100644 --- a/archiva-modules/archiva-maven/archiva-maven-model/src/main/java/org/apache/archiva/maven2/model/Artifact.java +++ b/archiva-modules/archiva-maven/archiva-maven-model/src/main/java/org/apache/archiva/maven/model/Artifact.java @@ -1,4 +1,4 @@ -package org.apache.archiva.maven2.model; +package org.apache.archiva.maven.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.maven2.model; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-maven/archiva-maven-model/src/main/java/org/apache/archiva/maven2/model/TreeEntry.java b/archiva-modules/archiva-maven/archiva-maven-model/src/main/java/org/apache/archiva/maven/model/TreeEntry.java similarity index 96% rename from archiva-modules/archiva-maven/archiva-maven-model/src/main/java/org/apache/archiva/maven2/model/TreeEntry.java rename to archiva-modules/archiva-maven/archiva-maven-model/src/main/java/org/apache/archiva/maven/model/TreeEntry.java index 23a3acf5c..e50e858ad 100644 --- a/archiva-modules/archiva-maven/archiva-maven-model/src/main/java/org/apache/archiva/maven2/model/TreeEntry.java +++ b/archiva-modules/archiva-maven/archiva-maven-model/src/main/java/org/apache/archiva/maven/model/TreeEntry.java @@ -1,4 +1,4 @@ -package org.apache.archiva.maven2.model; +package org.apache.archiva.maven.model; /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file @@ -8,8 +8,7 @@ package org.apache.archiva.maven2.model; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-maven/archiva-maven-model/src/test/java/org/apache/archiva/maven2/model/ModelTest.java b/archiva-modules/archiva-maven/archiva-maven-model/src/test/java/org/apache/archiva/maven/model/ModelTest.java similarity index 96% rename from archiva-modules/archiva-maven/archiva-maven-model/src/test/java/org/apache/archiva/maven2/model/ModelTest.java rename to archiva-modules/archiva-maven/archiva-maven-model/src/test/java/org/apache/archiva/maven/model/ModelTest.java index 75c4cc273..9600d2b90 100644 --- a/archiva-modules/archiva-maven/archiva-maven-model/src/test/java/org/apache/archiva/maven2/model/ModelTest.java +++ b/archiva-modules/archiva-maven/archiva-maven-model/src/test/java/org/apache/archiva/maven/model/ModelTest.java @@ -1,4 +1,4 @@ -package org.apache.archiva.maven2.model; +package org.apache.archiva.maven.model; /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file @@ -8,8 +8,7 @@ package org.apache.archiva.maven2.model; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-maven/archiva-maven-proxy/pom.xml b/archiva-modules/archiva-maven/archiva-maven-proxy/pom.xml index afd9022c6..c7f26a14e 100644 --- a/archiva-modules/archiva-maven/archiva-maven-proxy/pom.xml +++ b/archiva-modules/archiva-maven/archiva-maven-proxy/pom.xml @@ -234,6 +234,23 @@ + + + org.apache.maven.plugins + maven-surefire-plugin + + + ${project.build.directory}/appserver-base + ${project.build.directory}/appserver-base + ${project.build.directory}/appserver-base + ${redbackTestJdbcUrl} + ${redbackTestJdbcDriver} + mock + ${openjpa.Log} + + + +