diff options
author | Maria Odea B. Ching <oching@apache.org> | 2010-10-01 03:50:04 +0000 |
---|---|---|
committer | Maria Odea B. Ching <oching@apache.org> | 2010-10-01 03:50:04 +0000 |
commit | d35e740ca9af5352e77788e3929db365c2d1a051 (patch) | |
tree | 28120559549f51dd113fad881d9a8cc5308b088c /archiva-modules/plugins | |
parent | e82ce0f0b50f2db74e998c02384c8f7cfa1ee4a4 (diff) | |
download | archiva-d35e740ca9af5352e77788e3929db365c2d1a051.tar.gz archiva-d35e740ca9af5352e77788e3929db365c2d1a051.zip |
[MRM-1409] web services for repository merge
submitted by Gwen Harold Autencio
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1003378 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'archiva-modules/plugins')
4 files changed, 10 insertions, 3 deletions
diff --git a/archiva-modules/plugins/audit/src/main/java/org/apache/archiva/audit/AuditEvent.java b/archiva-modules/plugins/audit/src/main/java/org/apache/archiva/audit/AuditEvent.java index bf84c90ab..77d7ad8de 100644 --- a/archiva-modules/plugins/audit/src/main/java/org/apache/archiva/audit/AuditEvent.java +++ b/archiva-modules/plugins/audit/src/main/java/org/apache/archiva/audit/AuditEvent.java @@ -101,6 +101,8 @@ public class AuditEvent public static final String REMOVE_PATTERN = "Removed File Type Pattern"; + public static final String MERGE_REPO_REMOTE = "Merged Staging Repository Triggered Remotely"; + private String repositoryId; private String userId; diff --git a/archiva-modules/plugins/stage-repository-merge/src/main/java/org/apache/archiva/stagerepository/merge/Maven2RepositoryMerger.java b/archiva-modules/plugins/stage-repository-merge/src/main/java/org/apache/archiva/stagerepository/merge/Maven2RepositoryMerger.java index 943b667d6..7b45b067d 100644 --- a/archiva-modules/plugins/stage-repository-merge/src/main/java/org/apache/archiva/stagerepository/merge/Maven2RepositoryMerger.java +++ b/archiva-modules/plugins/stage-repository-merge/src/main/java/org/apache/archiva/stagerepository/merge/Maven2RepositoryMerger.java @@ -325,7 +325,7 @@ public class Maven2RepositoryMerger return metadata; } - public List<ArtifactMetadata> getConflictsartifacts( String sourceRepo, String targetRepo ) + public List<ArtifactMetadata> getConflictingArtifacts( String sourceRepo, String targetRepo ) throws Exception { List<ArtifactMetadata> targetArtifacts = metadataRepository.getArtifacts( targetRepo ); diff --git a/archiva-modules/plugins/stage-repository-merge/src/main/java/org/apache/archiva/stagerepository/merge/RepositoryMerger.java b/archiva-modules/plugins/stage-repository-merge/src/main/java/org/apache/archiva/stagerepository/merge/RepositoryMerger.java index 44fb3a172..85bb52cb5 100644 --- a/archiva-modules/plugins/stage-repository-merge/src/main/java/org/apache/archiva/stagerepository/merge/RepositoryMerger.java +++ b/archiva-modules/plugins/stage-repository-merge/src/main/java/org/apache/archiva/stagerepository/merge/RepositoryMerger.java @@ -19,6 +19,8 @@ package org.apache.archiva.stagerepository.merge; * under the License. */ +import java.util.List; + import org.apache.archiva.metadata.model.ArtifactMetadata; import org.apache.archiva.metadata.repository.filter.Filter; @@ -28,4 +30,7 @@ public interface RepositoryMerger throws Exception; void merge( String sourceRepoId, String targetRepoId, Filter<ArtifactMetadata> filter ) throws Exception; -} + + public List<ArtifactMetadata> getConflictingArtifacts( String sourceRepo, String targetRepo ) + throws Exception; +}
\ No newline at end of file diff --git a/archiva-modules/plugins/stage-repository-merge/src/test/java/org/apache/archiva/stagerepository/merge/Maven2RepositoryMergerTest.java b/archiva-modules/plugins/stage-repository-merge/src/test/java/org/apache/archiva/stagerepository/merge/Maven2RepositoryMergerTest.java index 5773d1bba..2346850fc 100644 --- a/archiva-modules/plugins/stage-repository-merge/src/test/java/org/apache/archiva/stagerepository/merge/Maven2RepositoryMergerTest.java +++ b/archiva-modules/plugins/stage-repository-merge/src/test/java/org/apache/archiva/stagerepository/merge/Maven2RepositoryMergerTest.java @@ -154,7 +154,7 @@ public class Maven2RepositoryMergerTest when( metadataRepository.getArtifacts( sourceRepoId ) ).thenReturn( sourceRepoArtifactsList ); when( metadataRepository.getArtifacts( TEST_REPO_ID ) ).thenReturn( targetRepoArtifactsList ); - assertEquals( 1, repositoryMerger.getConflictsartifacts( sourceRepoId, TEST_REPO_ID ).size() ); + assertEquals( 1, repositoryMerger.getConflictingArtifacts( sourceRepoId, TEST_REPO_ID ).size() ); verify( metadataRepository ).getArtifacts( TEST_REPO_ID ); } |