mirror of
https://github.com/apache/archiva.git
synced 2025-02-21 01:15:08 +00:00
git-svn-id: https://svn.apache.org/repos/asf/archiva/branches/archiva-MRM-1756@1488531 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
ad2961ba66
commit
0c9c688ea9
@ -23,7 +23,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-artifact-converter</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-checksum</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>archiva-common</artifactId>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>archiva-configuration</artifactId>
|
||||
|
@ -848,6 +848,14 @@
|
||||
<defaultValue>/.indexer</defaultValue>
|
||||
<description>The path of the merged index.</description>
|
||||
</field>
|
||||
<field>
|
||||
<name>mergedIndexTtl</name>
|
||||
<version>1.4.0+</version>
|
||||
<type>int</type>
|
||||
<required>false</required>
|
||||
<defaultValue>30</defaultValue>
|
||||
<description>The time to live of the merged index of the repository group.</description>
|
||||
</field>
|
||||
<field>
|
||||
<name>repositories</name>
|
||||
<version>1.2.0+</version>
|
||||
|
@ -23,7 +23,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-consumers</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-consumer-api</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -23,7 +23,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-consumers</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-consumer-archetype</artifactId>
|
||||
<packaging>maven-archetype</packaging>
|
||||
|
@ -23,7 +23,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-consumers</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-core-consumers</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -173,7 +173,7 @@ public boolean canObtainAccess( Class<?> aClass )
|
||||
return false;
|
||||
}
|
||||
|
||||
public Object obtainAccess( Class<?> aClass )
|
||||
public <T>T obtainAccess( Class<T> aClass )
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
@ -23,7 +23,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-consumers</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-lucene-consumers</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -23,7 +23,7 @@
|
||||
<parent>
|
||||
<artifactId>archiva-consumers</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-metadata-consumer</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -20,7 +20,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-consumers</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>archiva-signature-consumers</artifactId>
|
||||
|
@ -23,7 +23,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>archiva-consumers</artifactId>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>archiva-converter</artifactId>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>archiva-indexer</artifactId>
|
||||
|
@ -19,6 +19,7 @@
|
||||
*/
|
||||
|
||||
import com.google.common.io.Files;
|
||||
|
||||
import org.apache.archiva.admin.model.managed.ManagedRepositoryAdmin;
|
||||
import org.apache.archiva.common.plexusbridge.MavenIndexerUtils;
|
||||
import org.apache.archiva.common.plexusbridge.PlexusSisuBridge;
|
||||
@ -35,7 +36,6 @@
|
||||
import org.springframework.scheduling.annotation.Async;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.PostConstruct;
|
||||
import javax.inject.Inject;
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
@ -70,8 +70,6 @@ public class DefaultIndexMerger
|
||||
|
||||
private List<TemporaryGroupIndex> temporaryGroupIndexes = new CopyOnWriteArrayList<TemporaryGroupIndex>();
|
||||
|
||||
private int groupMergedIndexTtl;
|
||||
|
||||
@Inject
|
||||
public DefaultIndexMerger( PlexusSisuBridge plexusSisuBridge, MavenIndexerUtils mavenIndexerUtils )
|
||||
throws PlexusSisuBridgeException
|
||||
@ -81,12 +79,6 @@ public DefaultIndexMerger( PlexusSisuBridge plexusSisuBridge, MavenIndexerUtils
|
||||
indexPacker = plexusSisuBridge.lookup( IndexPacker.class, "default" );
|
||||
}
|
||||
|
||||
@PostConstruct
|
||||
public void intialize()
|
||||
{
|
||||
this.groupMergedIndexTtl = Integer.getInteger( IndexMerger.TMP_GROUP_INDEX_SYS_KEY, DEFAULT_GROUP_INDEX_TTL );
|
||||
}
|
||||
|
||||
public IndexingContext buildMergedIndex( IndexMergerRequest indexMergerRequest )
|
||||
throws IndexMergerException
|
||||
{
|
||||
@ -122,7 +114,7 @@ public IndexingContext buildMergedIndex( IndexMergerRequest indexMergerRequest )
|
||||
indexPacker.packIndex( request );
|
||||
}
|
||||
temporaryGroupIndexes.add(
|
||||
new TemporaryGroupIndex( tempRepoFile, tempRepoId, indexMergerRequest.getGroupId() ) );
|
||||
new TemporaryGroupIndex( tempRepoFile, tempRepoId, indexMergerRequest.getGroupId(), indexMergerRequest.getMergedIndexTtl() ) );
|
||||
stopWatch.stop();
|
||||
log.info( "merged index for repos {} in {} s", indexMergerRequest.getRepositoriesIds(),
|
||||
stopWatch.getTime() );
|
||||
@ -170,9 +162,4 @@ public Collection<TemporaryGroupIndex> getTemporaryGroupIndexes()
|
||||
{
|
||||
return this.temporaryGroupIndexes;
|
||||
}
|
||||
|
||||
public int getGroupMergedIndexTtl()
|
||||
{
|
||||
return this.groupMergedIndexTtl;
|
||||
}
|
||||
}
|
||||
|
@ -28,12 +28,6 @@
|
||||
*/
|
||||
public interface IndexMerger
|
||||
{
|
||||
|
||||
/**
|
||||
* system property which contains the value in s for ttl of temporary index groups
|
||||
*/
|
||||
String TMP_GROUP_INDEX_SYS_KEY = "archiva.tmp.group.index.ttl";
|
||||
|
||||
/**
|
||||
* @param indexMergerRequest
|
||||
* @return a temporary directory with a merge index (directory marked deleteOnExit)
|
||||
@ -45,10 +39,4 @@ IndexingContext buildMergedIndex( IndexMergerRequest indexMergerRequest )
|
||||
void cleanTemporaryGroupIndex( TemporaryGroupIndex temporaryGroupIndex );
|
||||
|
||||
Collection<TemporaryGroupIndex> getTemporaryGroupIndexes();
|
||||
|
||||
/**
|
||||
* @return ttl of temporay group index
|
||||
*/
|
||||
int getGroupMergedIndexTtl();
|
||||
|
||||
}
|
||||
|
@ -42,6 +42,8 @@ public class IndexMergerRequest
|
||||
|
||||
private String mergedIndexPath = "/.indexer";
|
||||
|
||||
private int mergedIndexTtl;
|
||||
|
||||
public IndexMergerRequest( Collection<String> repositoriesIds, boolean packIndex, String groupId )
|
||||
{
|
||||
this.repositoriesIds = repositoriesIds;
|
||||
@ -52,13 +54,14 @@ public IndexMergerRequest( Collection<String> repositoriesIds, boolean packIndex
|
||||
/**
|
||||
* @since 1.4-M4
|
||||
*/
|
||||
public IndexMergerRequest( Collection<String> repositoriesIds, boolean packIndex, String groupId,
|
||||
String mergedIndexPath )
|
||||
public IndexMergerRequest(Collection<String> repositoriesIds, boolean packIndex, String groupId,
|
||||
String mergedIndexPath, int mergedIndexTtl)
|
||||
{
|
||||
this.repositoriesIds = repositoriesIds;
|
||||
this.packIndex = packIndex;
|
||||
this.groupId = groupId;
|
||||
this.mergedIndexPath = mergedIndexPath;
|
||||
this.mergedIndexTtl = mergedIndexTtl;
|
||||
}
|
||||
|
||||
public Collection<String> getRepositoriesIds()
|
||||
@ -101,6 +104,14 @@ public void setMergedIndexPath( String mergedIndexPath )
|
||||
this.mergedIndexPath = mergedIndexPath;
|
||||
}
|
||||
|
||||
public int getMergedIndexTtl() {
|
||||
return mergedIndexTtl;
|
||||
}
|
||||
|
||||
public void setMergedIndexTtl(int mergedIndexTtl) {
|
||||
this.mergedIndexTtl = mergedIndexTtl;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString()
|
||||
{
|
||||
@ -109,6 +120,7 @@ public String toString()
|
||||
sb.append( ", packIndex=" ).append( packIndex );
|
||||
sb.append( ", groupId='" ).append( groupId ).append( '\'' );
|
||||
sb.append( ", mergedIndexPath='" ).append( mergedIndexPath ).append( '\'' );
|
||||
sb.append( ", mergedIndexTtl='" ).append( mergedIndexTtl ).append( '\'' );
|
||||
sb.append( '}' );
|
||||
return sb.toString();
|
||||
}
|
||||
|
@ -36,11 +36,14 @@ public class TemporaryGroupIndex
|
||||
|
||||
private String groupId;
|
||||
|
||||
public TemporaryGroupIndex( File directory, String indexId, String groupId )
|
||||
private int mergedIndexTtl;
|
||||
|
||||
public TemporaryGroupIndex(File directory, String indexId, String groupId, int mergedIndexTtl)
|
||||
{
|
||||
this.directory = directory;
|
||||
this.indexId = indexId;
|
||||
this.groupId = groupId;
|
||||
this.mergedIndexTtl = mergedIndexTtl;
|
||||
}
|
||||
|
||||
public long getCreationTime()
|
||||
@ -86,6 +89,14 @@ public void setGroupId( String groupId )
|
||||
this.groupId = groupId;
|
||||
}
|
||||
|
||||
public int getMergedIndexTtl() {
|
||||
return mergedIndexTtl;
|
||||
}
|
||||
|
||||
public void setMergedIndexTtl(int mergedIndexTtl) {
|
||||
this.mergedIndexTtl = mergedIndexTtl;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode()
|
||||
{
|
||||
|
@ -58,7 +58,7 @@ public void cleanTemporaryIndex()
|
||||
for ( TemporaryGroupIndex temporaryGroupIndex : indexMerger.getTemporaryGroupIndexes() )
|
||||
{
|
||||
// cleanup files older than the ttl
|
||||
if ( new Date().getTime() - temporaryGroupIndex.getCreationTime() > indexMerger.getGroupMergedIndexTtl() )
|
||||
if ( new Date().getTime() - temporaryGroupIndex.getCreationTime() > temporaryGroupIndex.getMergedIndexTtl() )
|
||||
{
|
||||
log.info( "cleanTemporaryIndex for groupId {}", temporaryGroupIndex.getGroupId() );
|
||||
indexMerger.cleanTemporaryGroupIndex( temporaryGroupIndex );
|
||||
|
@ -256,7 +256,7 @@ public boolean canObtainAccess( Class<?> aClass )
|
||||
return false; //To change body of implemented methods use File | Settings | File Templates.
|
||||
}
|
||||
|
||||
public Object obtainAccess( Class<?> aClass )
|
||||
public <T>T obtainAccess( Class<T> aClass )
|
||||
{
|
||||
return null; //To change body of implemented methods use File | Settings | File Templates.
|
||||
}
|
||||
|
@ -22,11 +22,10 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>archiva-maven2-metadata</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<packaging>bundle</packaging>
|
||||
|
||||
<name>Archiva Base :: Maven 2 Metadata</name>
|
||||
|
@ -22,11 +22,10 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>archiva-maven2-model</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<packaging>bundle</packaging>
|
||||
|
||||
<name>Archiva Base :: Maven 2 Model</name>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>archiva-model</artifactId>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>archiva-plexus-bridge</artifactId>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>archiva-policies</artifactId>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-proxy-api</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-proxy-common</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>archiva-proxy</artifactId>
|
||||
|
@ -178,7 +178,7 @@ public boolean canObtainAccess( Class<?> aClass )
|
||||
return false;
|
||||
}
|
||||
|
||||
public Object obtainAccess( Class<?> aClass )
|
||||
public <T>T obtainAccess( Class<T> aClass )
|
||||
{
|
||||
return null; //To change body of implemented methods use File | Settings | File Templates.
|
||||
}
|
||||
|
@ -23,7 +23,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-repository-admin</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-repository-admin-api</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -46,6 +46,11 @@ public class RepositoryGroup
|
||||
*/
|
||||
private String mergedIndexPath = "/.indexer";
|
||||
|
||||
/**
|
||||
* The TTL (time to live) of the repo group's merged index.
|
||||
*/
|
||||
private int mergedIndexTtl = 30;
|
||||
|
||||
public RepositoryGroup()
|
||||
{
|
||||
// no op
|
||||
@ -132,12 +137,29 @@ public void setMergedIndexPath( String mergedIndexPath )
|
||||
this.mergedIndexPath = mergedIndexPath;
|
||||
}
|
||||
|
||||
public RepositoryGroup mergedIndexPath( String mergedIndexPath )
|
||||
{
|
||||
public int getMergedIndexTtl() {
|
||||
return mergedIndexTtl;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the TTL of the repo group's merged index.
|
||||
*
|
||||
* @param mergedIndexTtl
|
||||
*/
|
||||
public void setMergedIndexTtl(int mergedIndexTtl) {
|
||||
this.mergedIndexTtl = mergedIndexTtl;
|
||||
}
|
||||
|
||||
public RepositoryGroup mergedIndexPath( String mergedIndexPath ) {
|
||||
this.mergedIndexPath = mergedIndexPath;
|
||||
return this;
|
||||
}
|
||||
|
||||
public RepositoryGroup mergedIndexTtl( int mergedIndexTtl ) {
|
||||
this.mergedIndexTtl = mergedIndexTtl;
|
||||
return this;
|
||||
}
|
||||
|
||||
public boolean equals( Object other )
|
||||
{
|
||||
if ( this == other )
|
||||
|
@ -23,7 +23,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-repository-admin</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-repository-admin-default</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -68,7 +68,7 @@ public List<RepositoryGroup> getRepositoriesGroups()
|
||||
{
|
||||
repositoriesGroups.add( new RepositoryGroup( repositoryGroupConfiguration.getId(), new ArrayList<String>(
|
||||
repositoryGroupConfiguration.getRepositories() ) ).mergedIndexPath(
|
||||
repositoryGroupConfiguration.getMergedIndexPath() ) );
|
||||
repositoryGroupConfiguration.getMergedIndexPath() ).mergedIndexTtl( repositoryGroupConfiguration.getMergedIndexTtl() ) );
|
||||
}
|
||||
|
||||
return repositoriesGroups;
|
||||
@ -93,10 +93,12 @@ public Boolean addRepositoryGroup( RepositoryGroup repositoryGroup, AuditInforma
|
||||
{
|
||||
validateRepositoryGroup( repositoryGroup, false );
|
||||
validateManagedRepositoriesExists( repositoryGroup.getRepositories() );
|
||||
|
||||
RepositoryGroupConfiguration repositoryGroupConfiguration = new RepositoryGroupConfiguration();
|
||||
repositoryGroupConfiguration.setId( repositoryGroup.getId() );
|
||||
repositoryGroupConfiguration.setRepositories( repositoryGroup.getRepositories() );
|
||||
repositoryGroupConfiguration.setMergedIndexPath( repositoryGroup.getMergedIndexPath() );
|
||||
repositoryGroupConfiguration.setMergedIndexTtl( repositoryGroup.getMergedIndexTtl() );
|
||||
Configuration configuration = getArchivaConfiguration().getConfiguration();
|
||||
configuration.addRepositoryGroup( repositoryGroupConfiguration );
|
||||
saveConfiguration( configuration );
|
||||
@ -141,6 +143,7 @@ private Boolean updateRepositoryGroup( RepositoryGroup repositoryGroup, AuditInf
|
||||
|
||||
repositoryGroupConfiguration.setRepositories( repositoryGroup.getRepositories() );
|
||||
repositoryGroupConfiguration.setMergedIndexPath( repositoryGroup.getMergedIndexPath() );
|
||||
repositoryGroupConfiguration.setMergedIndexTtl( repositoryGroup.getMergedIndexTtl() );
|
||||
configuration.addRepositoryGroup( repositoryGroupConfiguration );
|
||||
|
||||
saveConfiguration( configuration );
|
||||
@ -282,6 +285,11 @@ public Boolean validateRepositoryGroup( RepositoryGroup repositoryGroup, boolean
|
||||
"Invalid character(s) found in identifier. Only the following characters are allowed: alphanumeric, '.', '-' and '_'" );
|
||||
}
|
||||
|
||||
if ( repositoryGroup.getMergedIndexTtl() <= 0)
|
||||
{
|
||||
throw new RepositoryAdminException( "Merged Index TTL must be greater than 0." );
|
||||
}
|
||||
|
||||
Configuration configuration = getArchivaConfiguration().getConfiguration();
|
||||
|
||||
if ( configuration.getRepositoryGroupsAsMap().containsKey( repoGroupId ) )
|
||||
|
@ -256,7 +256,7 @@ public boolean canObtainAccess( Class<?> aClass )
|
||||
return false; //To change body of implemented methods use File | Settings | File Templates.
|
||||
}
|
||||
|
||||
public Object obtainAccess( Class<?> aClass )
|
||||
public <T>T obtainAccess( Class<T> aClass )
|
||||
{
|
||||
return null; //To change body of implemented methods use File | Settings | File Templates.
|
||||
}
|
||||
|
@ -18,6 +18,7 @@
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
import org.apache.archiva.admin.model.RepositoryAdminException;
|
||||
import org.apache.archiva.admin.model.beans.ManagedRepository;
|
||||
import org.apache.archiva.admin.model.beans.RepositoryGroup;
|
||||
import org.apache.archiva.admin.model.group.RepositoryGroupAdmin;
|
||||
@ -67,6 +68,10 @@ public void addAndDeleteGroup()
|
||||
assertEquals( Arrays.asList( "test-new-one", "test-new-two" ),
|
||||
repositoryGroupAdmin.getRepositoriesGroups().get( 0 ).getRepositories() );
|
||||
|
||||
// verify if default values were saved
|
||||
assertEquals(30, repositoryGroupAdmin.getRepositoriesGroups().get( 0 ).getMergedIndexTtl() );
|
||||
assertEquals("/.indexer", repositoryGroupAdmin.getRepositoriesGroups().get( 0 ).getMergedIndexPath() );
|
||||
|
||||
repositoryGroupAdmin.deleteRepositoryGroup( "repo-group-one", getFakeAuditInformation() );
|
||||
|
||||
assertEquals( 0, repositoryGroupAdmin.getRepositoriesGroups().size() );
|
||||
@ -100,7 +105,8 @@ public void addAndUpdateAndDeleteGroup()
|
||||
|
||||
managedRepositoryAdmin.addManagedRepository( managedRepositoryTwo, false, getFakeAuditInformation() );
|
||||
|
||||
RepositoryGroup repositoryGroup = new RepositoryGroup( "repo-group-one", Arrays.asList( "test-new-one" ) );
|
||||
RepositoryGroup repositoryGroup = new RepositoryGroup( "repo-group-one", Arrays.asList( "test-new-one" ) )
|
||||
.mergedIndexTtl( 20 ).mergedIndexPath( "/.nonDefaultPath" );
|
||||
|
||||
mockAuditListener.clearEvents();
|
||||
|
||||
@ -111,6 +117,8 @@ public void addAndUpdateAndDeleteGroup()
|
||||
assertEquals( 1, repositoryGroupAdmin.getRepositoriesGroups().get( 0 ).getRepositories().size() );
|
||||
assertEquals( Arrays.asList( "test-new-one" ),
|
||||
repositoryGroupAdmin.getRepositoriesGroups().get( 0 ).getRepositories() );
|
||||
assertEquals( 20, repositoryGroupAdmin.getRepositoriesGroups().get( 0 ).getMergedIndexTtl() );
|
||||
assertEquals( "/.nonDefaultPath", repositoryGroupAdmin.getRepositoriesGroups().get( 0 ).getMergedIndexPath() );
|
||||
|
||||
repositoryGroup = repositoryGroupAdmin.getRepositoryGroup( "repo-group-one" );
|
||||
assertNotNull( repositoryGroup );
|
||||
@ -143,9 +151,8 @@ public void addAndUpdateAndDeleteGroup()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@Test
|
||||
public void addAndDeleteGroupWithRemowingManagedRepo()
|
||||
public void addAndDeleteGroupWithRemovedManagedRepo()
|
||||
throws Exception
|
||||
{
|
||||
try
|
||||
@ -199,4 +206,78 @@ public void addAndDeleteGroupWithRemowingManagedRepo()
|
||||
managedRepositoryAdmin.deleteManagedRepository( "test-new-two", getFakeAuditInformation(), true );
|
||||
}
|
||||
}
|
||||
|
||||
@Test( expected = RepositoryAdminException.class )
|
||||
public void testAddGroupWithInvalidMergedIndexTtl() throws Exception {
|
||||
try {
|
||||
ManagedRepository managedRepositoryOne =
|
||||
getTestManagedRepository( "test-new-one", APPSERVER_BASE_PATH + File.separator + "test-new-one" );
|
||||
|
||||
ManagedRepository managedRepositoryTwo =
|
||||
getTestManagedRepository( "test-new-two", APPSERVER_BASE_PATH + File.separator + "test-new-two" );
|
||||
|
||||
managedRepositoryAdmin.addManagedRepository( managedRepositoryOne, false, getFakeAuditInformation() );
|
||||
|
||||
managedRepositoryAdmin.addManagedRepository( managedRepositoryTwo, false, getFakeAuditInformation() );
|
||||
|
||||
RepositoryGroup repositoryGroup =
|
||||
new RepositoryGroup( "repo-group-one", Arrays.asList( "test-new-one", "test-new-two" ) )
|
||||
.mergedIndexTtl( -1 );
|
||||
|
||||
mockAuditListener.clearEvents();
|
||||
|
||||
repositoryGroupAdmin.addRepositoryGroup( repositoryGroup, getFakeAuditInformation() );
|
||||
}
|
||||
finally
|
||||
{
|
||||
mockAuditListener.clearEvents();
|
||||
managedRepositoryAdmin.deleteManagedRepository( "test-new-one", getFakeAuditInformation(), true );
|
||||
managedRepositoryAdmin.deleteManagedRepository( "test-new-two", getFakeAuditInformation(), true );
|
||||
}
|
||||
}
|
||||
|
||||
@Test( expected = RepositoryAdminException.class )
|
||||
public void testAddAndUpdateGroupWithInvalidMergedIndexTtl() throws Exception {
|
||||
try {
|
||||
ManagedRepository managedRepositoryOne =
|
||||
getTestManagedRepository( "test-new-one", APPSERVER_BASE_PATH + File.separator + "test-new-one" );
|
||||
|
||||
ManagedRepository managedRepositoryTwo =
|
||||
getTestManagedRepository( "test-new-two", APPSERVER_BASE_PATH + File.separator + "test-new-two" );
|
||||
|
||||
managedRepositoryAdmin.addManagedRepository( managedRepositoryOne, false, getFakeAuditInformation() );
|
||||
|
||||
managedRepositoryAdmin.addManagedRepository( managedRepositoryTwo, false, getFakeAuditInformation() );
|
||||
|
||||
RepositoryGroup repositoryGroup =
|
||||
new RepositoryGroup( "repo-group-one", Arrays.asList( "test-new-one", "test-new-two" ) );
|
||||
|
||||
mockAuditListener.clearEvents();
|
||||
|
||||
repositoryGroupAdmin.addRepositoryGroup( repositoryGroup, getFakeAuditInformation() );
|
||||
|
||||
assertEquals( 1, repositoryGroupAdmin.getRepositoriesGroups().size() );
|
||||
assertEquals( "repo-group-one", repositoryGroupAdmin.getRepositoriesGroups().get( 0 ).getId() );
|
||||
assertEquals( 2, repositoryGroupAdmin.getRepositoriesGroups().get( 0 ).getRepositories().size() );
|
||||
assertEquals( Arrays.asList( "test-new-one", "test-new-two" ),
|
||||
repositoryGroupAdmin.getRepositoriesGroups().get( 0 ).getRepositories() );
|
||||
|
||||
// verify if default values were saved
|
||||
assertEquals(30, repositoryGroupAdmin.getRepositoriesGroups().get( 0 ).getMergedIndexTtl() );
|
||||
assertEquals("/.indexer", repositoryGroupAdmin.getRepositoriesGroups().get( 0 ).getMergedIndexPath() );
|
||||
|
||||
repositoryGroup = repositoryGroupAdmin.getRepositoryGroup( "repo-group-one" );
|
||||
assertNotNull( repositoryGroup );
|
||||
|
||||
repositoryGroup.mergedIndexTtl( -1 );
|
||||
|
||||
repositoryGroupAdmin.updateRepositoryGroup( repositoryGroup, getFakeAuditInformation() );
|
||||
}
|
||||
finally
|
||||
{
|
||||
mockAuditListener.clearEvents();
|
||||
managedRepositoryAdmin.deleteManagedRepository( "test-new-one", getFakeAuditInformation(), true );
|
||||
managedRepositoryAdmin.deleteManagedRepository( "test-new-two", getFakeAuditInformation(), true );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -23,7 +23,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-repository-admin</artifactId>
|
||||
<name>Archiva Base :: Repository Admin</name>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>archiva-repository-layer</artifactId>
|
||||
|
@ -23,7 +23,7 @@
|
||||
<parent>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-repository-scanner</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-security-common</artifactId>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>archiva-test-utils</artifactId>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-transaction</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-base</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>archiva-xml-tools</artifactId>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-modules</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>archiva-base</artifactId>
|
||||
|
@ -21,7 +21,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-karaf</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>org.apache.archiva.karaf</groupId>
|
||||
|
@ -21,7 +21,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-modules</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>archiva-karaf</artifactId>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>archiva-scheduler</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-scheduler-api</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>archiva-scheduler</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-scheduler-indexing</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -256,7 +256,7 @@ public boolean canObtainAccess( Class<?> aClass )
|
||||
return false; //To change body of implemented methods use File | Settings | File Templates.
|
||||
}
|
||||
|
||||
public Object obtainAccess( Class<?> aClass )
|
||||
public <T>T obtainAccess( Class<T> aClass )
|
||||
{
|
||||
return null; //To change body of implemented methods use File | Settings | File Templates.
|
||||
}
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>archiva-scheduler</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-scheduler-repository-api</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>archiva-scheduler</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-scheduler-repository</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-modules</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>archiva-scheduler</artifactId>
|
||||
|
@ -17,13 +17,12 @@
|
||||
~ specific language governing permissions and limitations
|
||||
~ under the License.
|
||||
-->
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<artifactId>archiva-rest</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-rest-api</artifactId>
|
||||
<!-- DO NOT USE bundle packaging generated documentation is not included in the jar !!! -->
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-rest</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-rest-services</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -52,7 +52,8 @@ public List<RepositoryGroup> getRepositoriesGroups()
|
||||
for ( org.apache.archiva.admin.model.beans.RepositoryGroup repoGroup : repositoryGroupAdmin.getRepositoriesGroups() )
|
||||
{
|
||||
repositoriesGroups.add( new RepositoryGroup( repoGroup.getId(), new ArrayList<String>(
|
||||
repoGroup.getRepositories() ) ).mergedIndexPath( repoGroup.getMergedIndexPath() ) );
|
||||
repoGroup.getRepositories() ) ).mergedIndexPath( repoGroup.getMergedIndexPath() )
|
||||
.mergedIndexTtl( repoGroup.getMergedIndexTtl() ) );
|
||||
}
|
||||
return repositoriesGroups;
|
||||
}
|
||||
@ -82,8 +83,8 @@ public Boolean addRepositoryGroup( RepositoryGroup repoGroup )
|
||||
{
|
||||
return repositoryGroupAdmin.addRepositoryGroup(
|
||||
new org.apache.archiva.admin.model.beans.RepositoryGroup( repoGroup.getId(), new ArrayList<String>(
|
||||
repoGroup.getRepositories() ) ).mergedIndexPath( repoGroup.getMergedIndexPath() ),
|
||||
getAuditInformation() );
|
||||
repoGroup.getRepositories() ) ).mergedIndexPath( repoGroup.getMergedIndexPath() )
|
||||
.mergedIndexTtl( repoGroup.getMergedIndexTtl() ), getAuditInformation() );
|
||||
}
|
||||
catch ( RepositoryAdminException e )
|
||||
{
|
||||
@ -98,8 +99,8 @@ public Boolean updateRepositoryGroup( RepositoryGroup repoGroup )
|
||||
{
|
||||
return repositoryGroupAdmin.updateRepositoryGroup(
|
||||
new org.apache.archiva.admin.model.beans.RepositoryGroup( repoGroup.getId(), new ArrayList<String>(
|
||||
repoGroup.getRepositories() ) ).mergedIndexPath( repoGroup.getMergedIndexPath() ),
|
||||
getAuditInformation() );
|
||||
repoGroup.getRepositories() ) ).mergedIndexPath( repoGroup.getMergedIndexPath() )
|
||||
.mergedIndexTtl( repoGroup.getMergedIndexTtl() ), getAuditInformation() );
|
||||
}
|
||||
catch ( RepositoryAdminException e )
|
||||
{
|
||||
|
@ -51,11 +51,13 @@ public void addAndDelete()
|
||||
|
||||
managedRepositoriesService.addManagedRepository( managedRepository );
|
||||
|
||||
RepositoryGroup repositoryGroup = new RepositoryGroup( "one", Arrays.asList( managedRepository.getId() ) );
|
||||
RepositoryGroup repositoryGroup = new RepositoryGroup( "one", Arrays.asList( managedRepository.getId() ) )
|
||||
.mergedIndexTtl( 40 );
|
||||
|
||||
service.addRepositoryGroup( repositoryGroup );
|
||||
assertFalse( service.getRepositoriesGroups().isEmpty() );
|
||||
assertEquals( 1, service.getRepositoriesGroups().size() );
|
||||
assertEquals( 40, service.getRepositoriesGroups().get(0).getMergedIndexTtl() );
|
||||
|
||||
service.deleteRepositoryGroup( "one" );
|
||||
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-web</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-rest</artifactId>
|
||||
<name>Archiva Web :: REST support</name>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>archiva-web</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>archiva-rss</artifactId>
|
||||
|
@ -250,7 +250,7 @@ public boolean canObtainAccess( Class<?> aClass )
|
||||
return false;
|
||||
}
|
||||
|
||||
public Object obtainAccess( Class<?> aClass )
|
||||
public <T>T obtainAccess( Class<T> aClass )
|
||||
{
|
||||
throw new UnsupportedOperationException();
|
||||
}
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-web</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>archiva-security</artifactId>
|
||||
|
@ -22,11 +22,10 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-web</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>archiva-test-mocks</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
|
||||
<name>Archiva Web :: Tests Mocks</name>
|
||||
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-web</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>archiva-web-common</artifactId>
|
||||
|
@ -312,6 +312,7 @@ repository.groups.list=Repository Groups
|
||||
repository-groups.grid.tab.title=Repository Groups
|
||||
repository.group.delete.confirm=Are you sure to delete Repository Group {0} ?
|
||||
repository.group.mergedIndexPath=Merged Index Path
|
||||
repository.group.mergedIndexTtl=Merged Index Time to Live (in Minutes)
|
||||
|
||||
#roles
|
||||
roles.bulk.save.confirm=Are you sure to update {0} Role(s)
|
||||
|
@ -220,7 +220,7 @@ public boolean canObtainAccess( Class<?> aClass )
|
||||
return false;
|
||||
}
|
||||
|
||||
public Object obtainAccess( Class<?> aClass )
|
||||
public <T>T obtainAccess( Class<T> aClass )
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
@ -23,7 +23,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-web</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-webapp-test</artifactId>
|
||||
<packaging>pom</packaging>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-web</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>archiva-webapp</artifactId>
|
||||
<packaging>war</packaging>
|
||||
@ -1014,7 +1014,6 @@
|
||||
<archiva.devMode>${archiva.devMode}</archiva.devMode>
|
||||
<archiva.javascriptLog>${archiva.javascriptLog}</archiva.javascriptLog>
|
||||
<archiva.logMissingI18n>${archiva.logMissingI18n}</archiva.logMissingI18n>
|
||||
<archiva.tmp.group.index.ttl>${archiva.groupIndexTtl}</archiva.tmp.group.index.ttl>
|
||||
<!--
|
||||
not needed as we use asyncLogger in configuration
|
||||
<Log4jContextSelector>org.apache.logging.log4j.core.async.AsyncLoggerContextSelector</Log4jContextSelector>
|
||||
|
180
archiva-modules/archiva-web/archiva-webapp/src/main/webapp/css/jqueryFileTree.css
Executable file → Normal file
180
archiva-modules/archiva-web/archiva-webapp/src/main/webapp/css/jqueryFileTree.css
Executable file → Normal file
@ -1,91 +1,91 @@
|
||||
UL.jqueryFileTree {
|
||||
font-family: Verdana, sans-serif;
|
||||
font-size: 11px;
|
||||
line-height: 18px;
|
||||
padding: 0px;
|
||||
margin: 0px;
|
||||
}
|
||||
|
||||
UL.jqueryFileTree LI {
|
||||
list-style: none;
|
||||
padding: 0px;
|
||||
padding-left: 20px;
|
||||
margin: 0px;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
UL.jqueryFileTree A {
|
||||
color: #333;
|
||||
text-decoration: none;
|
||||
display: block;
|
||||
padding: 0px 2px;
|
||||
}
|
||||
|
||||
UL.jqueryFileTree A:hover {
|
||||
background: #BDF;
|
||||
}
|
||||
|
||||
/* Core Styles */
|
||||
.jqueryFileTree LI.directory { background: url(images/folder-closed.gif) left top no-repeat; }
|
||||
.jqueryFileTree LI.expanded { background: url(images/folder.gif) left top no-repeat; }
|
||||
.jqueryFileTree LI.file { background: url(images/file.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.wait { background: url(images/spinner.gif) left top no-repeat; }
|
||||
/* File Extensions*/
|
||||
.jqueryFileTree LI.ext_3gp { background: url(images/film.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_afp { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_afpa { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_asp { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_aspx { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_avi { background: url(images/film.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_bat { background: url(images/application.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_bmp { background: url(images/picture.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_c { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_cfm { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_cgi { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_com { background: url(images/application.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_cpp { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_css { background: url(images/css.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_doc { background: url(images/doc.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_exe { background: url(images/application.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_gif { background: url(images/picture.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_fla { background: url(images/flash.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_h { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_htm { background: url(images/html.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_html { background: url(images/html.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_jar { background: url(images/java.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_jpg { background: url(images/picture.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_jpeg { background: url(images/picture.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_js { background: url(images/script.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_lasso { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_log { background: url(images/txt.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_m4p { background: url(images/music.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_mov { background: url(images/film.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_mp3 { background: url(images/music.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_mp4 { background: url(images/film.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_mpg { background: url(images/film.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_mpeg { background: url(images/film.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_ogg { background: url(images/music.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_pcx { background: url(images/picture.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_pdf { background: url(images/pdf.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_php { background: url(images/php.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_png { background: url(images/picture.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_ppt { background: url(images/ppt.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_psd { background: url(images/psd.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_pl { background: url(images/script.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_py { background: url(images/script.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_rb { background: url(images/ruby.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_rbx { background: url(images/ruby.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_rhtml { background: url(images/ruby.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_rpm { background: url(images/linux.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_ruby { background: url(images/ruby.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_sql { background: url(images/db.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_swf { background: url(images/flash.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_tif { background: url(images/picture.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_tiff { background: url(images/picture.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_txt { background: url(images/txt.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_vb { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_wav { background: url(images/music.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_wmv { background: url(images/film.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_xls { background: url(images/xls.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_xml { background: url(images/code.png) left top no-repeat; }
|
||||
UL.jqueryFileTree {
|
||||
font-family: Verdana, sans-serif;
|
||||
font-size: 11px;
|
||||
line-height: 18px;
|
||||
padding: 0px;
|
||||
margin: 0px;
|
||||
}
|
||||
|
||||
UL.jqueryFileTree LI {
|
||||
list-style: none;
|
||||
padding: 0px;
|
||||
padding-left: 20px;
|
||||
margin: 0px;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
UL.jqueryFileTree A {
|
||||
color: #333;
|
||||
text-decoration: none;
|
||||
display: block;
|
||||
padding: 0px 2px;
|
||||
}
|
||||
|
||||
UL.jqueryFileTree A:hover {
|
||||
background: #BDF;
|
||||
}
|
||||
|
||||
/* Core Styles */
|
||||
.jqueryFileTree LI.directory { background: url(images/folder-closed.gif) left top no-repeat; }
|
||||
.jqueryFileTree LI.expanded { background: url(images/folder.gif) left top no-repeat; }
|
||||
.jqueryFileTree LI.file { background: url(images/file.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.wait { background: url(images/spinner.gif) left top no-repeat; }
|
||||
/* File Extensions*/
|
||||
.jqueryFileTree LI.ext_3gp { background: url(images/film.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_afp { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_afpa { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_asp { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_aspx { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_avi { background: url(images/film.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_bat { background: url(images/application.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_bmp { background: url(images/picture.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_c { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_cfm { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_cgi { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_com { background: url(images/application.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_cpp { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_css { background: url(images/css.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_doc { background: url(images/doc.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_exe { background: url(images/application.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_gif { background: url(images/picture.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_fla { background: url(images/flash.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_h { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_htm { background: url(images/html.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_html { background: url(images/html.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_jar { background: url(images/java.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_jpg { background: url(images/picture.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_jpeg { background: url(images/picture.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_js { background: url(images/script.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_lasso { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_log { background: url(images/txt.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_m4p { background: url(images/music.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_mov { background: url(images/film.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_mp3 { background: url(images/music.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_mp4 { background: url(images/film.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_mpg { background: url(images/film.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_mpeg { background: url(images/film.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_ogg { background: url(images/music.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_pcx { background: url(images/picture.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_pdf { background: url(images/pdf.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_php { background: url(images/php.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_png { background: url(images/picture.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_ppt { background: url(images/ppt.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_psd { background: url(images/psd.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_pl { background: url(images/script.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_py { background: url(images/script.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_rb { background: url(images/ruby.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_rbx { background: url(images/ruby.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_rhtml { background: url(images/ruby.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_rpm { background: url(images/linux.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_ruby { background: url(images/ruby.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_sql { background: url(images/db.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_swf { background: url(images/flash.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_tif { background: url(images/picture.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_tiff { background: url(images/picture.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_txt { background: url(images/txt.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_vb { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_wav { background: url(images/music.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_wmv { background: url(images/film.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_xls { background: url(images/xls.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_xml { background: url(images/code.png) left top no-repeat; }
|
||||
.jqueryFileTree LI.ext_zip { background: url(images/zip.png) left top no-repeat; }
|
@ -1442,6 +1442,13 @@ <h5>${$.i18n.prop('repository.groups.available.repositories')}</h5>
|
||||
data-bind="value: repositoryGroup.mergedIndexPath"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="control-group">
|
||||
<label class="control-label" for="mergedIndexPath">${$.i18n.prop('repository.group.mergedIndexTtl')}</label>
|
||||
<div class="controls">
|
||||
<input type="text" class="input-large required" id="mergedIndexTtl" name="mergedIndexTtl"
|
||||
data-bind="value: repositoryGroup.mergedIndexTtl"/>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<a href="${window.archivaRuntimeInfo.baseUrl}/repository/${repositoryGroup.id()}" target="_blank">
|
||||
{{if repositoryGroup.id()}}
|
||||
|
@ -23,7 +23,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-web</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>archiva-webdav</artifactId>
|
||||
|
@ -1202,8 +1202,7 @@ protected File buildMergedIndexDirectory( List<String> repositories, String acti
|
||||
|
||||
if ( tmp != null && tmp.getDirectory() != null && tmp.getDirectory().exists() )
|
||||
{
|
||||
if ( System.currentTimeMillis() - tmp.getCreationTime() > ( indexMerger.getGroupMergedIndexTtl() * 60
|
||||
* 1000 ) )
|
||||
if ( System.currentTimeMillis() - tmp.getCreationTime() > ( repositoryGroupConfiguration.getMergedIndexTtl() * 60 * 1000 ) )
|
||||
{
|
||||
log.debug( MarkerFactory.getMarker( "group.merged.index" ),
|
||||
"tmp group index '{}' is too old so delete it", repositoryGroupConfiguration.getId() );
|
||||
@ -1241,11 +1240,11 @@ protected File buildMergedIndexDirectory( List<String> repositories, String acti
|
||||
repositoryGroupConfiguration.getId(), authzRepos );
|
||||
IndexingContext indexingContext = indexMerger.buildMergedIndex(
|
||||
new IndexMergerRequest( authzRepos, true, repositoryGroupConfiguration.getId(),
|
||||
repositoryGroupConfiguration.getMergedIndexPath() ) );
|
||||
repositoryGroupConfiguration.getMergedIndexPath(), repositoryGroupConfiguration.getMergedIndexTtl() ) );
|
||||
File mergedRepoDir = indexingContext.getIndexDirectoryFile();
|
||||
TemporaryGroupIndex temporaryGroupIndex = new TemporaryGroupIndex( mergedRepoDir, indexingContext.getId(),
|
||||
repositoryGroupConfiguration.getId() ).setCreationTime(
|
||||
new Date().getTime() );
|
||||
repositoryGroupConfiguration.getId(),repositoryGroupConfiguration.getMergedIndexTtl() )
|
||||
.setCreationTime(new Date().getTime() );
|
||||
temporaryGroupIndexMap.put( repositoryGroupConfiguration.getId(), temporaryGroupIndex );
|
||||
session.setAttribute( TemporaryGroupIndexSessionCleaner.TEMPORARY_INDEX_SESSION_KEY,
|
||||
temporaryGroupIndexMap );
|
||||
|
@ -174,7 +174,7 @@ public boolean canObtainAccess( Class<?> aClass )
|
||||
return false;
|
||||
}
|
||||
|
||||
public Object obtainAccess( Class<?> aClass )
|
||||
public <T>T obtainAccess( Class<T> aClass )
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
@ -19,7 +19,7 @@
|
||||
<parent>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<artifactId>archiva-modules</artifactId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>archiva-web</artifactId>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>metadata</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>metadata-model-maven2</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
@ -53,7 +53,8 @@
|
||||
</Export-Package>
|
||||
<Import-Package>
|
||||
javax.xml.bind.annotation,
|
||||
org.apache.commons.lang
|
||||
org.apache.commons.lang,
|
||||
javax.persistence
|
||||
</Import-Package>
|
||||
</instructions>
|
||||
</configuration>
|
||||
|
@ -22,12 +22,19 @@
|
||||
<parent>
|
||||
<artifactId>metadata</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>metadata-model</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
<name>Archiva Metadata :: Model</name>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>org.apache.geronimo.specs</groupId>
|
||||
<artifactId>geronimo-jpa_2.0_spec</artifactId>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
@ -41,7 +48,7 @@
|
||||
org.apache.archiva.metadata.model;version=${project.version};-split-package:=merge-first
|
||||
</Export-Package>
|
||||
<Import-Package>
|
||||
javax.xml.bind.annotation
|
||||
javax.xml.bind.annotation,javax.persistence
|
||||
</Import-Package>
|
||||
</instructions>
|
||||
</configuration>
|
||||
|
@ -19,15 +19,19 @@
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
import javax.persistence.Entity;
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* Information about the CI system used by the project.
|
||||
*
|
||||
* @todo considering moving this to a facet - avoid referring to it externally
|
||||
*/
|
||||
@XmlRootElement( name = "ciManagement" )
|
||||
@XmlRootElement(name = "ciManagement")
|
||||
@Entity
|
||||
public class CiManagement
|
||||
implements Serializable
|
||||
{
|
||||
/**
|
||||
* A simple identifier for the type of CI server used, eg <tt>continuum</tt>, <tt>bamboo</tt>, <tt>hudson</tt>, etc.
|
||||
|
@ -20,14 +20,16 @@
|
||||
*/
|
||||
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* Information about a dependency that this project has on another project or artifact.
|
||||
*
|
||||
* @todo will be reviewing what is appropriate for the base here - rest should be in a maven dependency facet - avoid details on it externally
|
||||
*/
|
||||
@XmlRootElement( name = "dependency" )
|
||||
@XmlRootElement(name = "dependency")
|
||||
public class Dependency
|
||||
implements Serializable
|
||||
{
|
||||
/**
|
||||
* The Maven classifier of the dependency.
|
||||
|
@ -19,15 +19,19 @@
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
import javax.persistence.Entity;
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* Information about the issue management system used by the project.
|
||||
*
|
||||
* @todo considering moving this to a facet - avoid referring to it externally
|
||||
*/
|
||||
@XmlRootElement( name = "issueManagement" )
|
||||
@XmlRootElement(name = "issueManagement")
|
||||
@Entity
|
||||
public class IssueManagement
|
||||
implements Serializable
|
||||
{
|
||||
/**
|
||||
* A simple identifier for the type of issue management server used, eg <tt>jira</tt>, <tt>bugzilla</tt>, etc.
|
||||
|
@ -20,12 +20,14 @@
|
||||
*/
|
||||
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* A description of a particular license used by a project.
|
||||
*/
|
||||
@XmlRootElement( name = "license" )
|
||||
@XmlRootElement(name = "license")
|
||||
public class License
|
||||
implements Serializable
|
||||
{
|
||||
/**
|
||||
* The name of the license.
|
||||
|
@ -1,6 +1,7 @@
|
||||
package org.apache.archiva.metadata.model;
|
||||
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
/*
|
||||
@ -27,8 +28,9 @@
|
||||
*
|
||||
* @todo considering moving this to a facet - avoid referring to it externally
|
||||
*/
|
||||
@XmlRootElement( name = "mailingList" )
|
||||
@XmlRootElement(name = "mailingList")
|
||||
public class MailingList
|
||||
implements Serializable
|
||||
{
|
||||
/**
|
||||
* The primary archive URL for this mailing list.
|
||||
|
@ -19,10 +19,14 @@
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
import javax.persistence.Entity;
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
import java.io.Serializable;
|
||||
|
||||
@XmlRootElement( name = "organization" )
|
||||
@XmlRootElement(name = "organization")
|
||||
@Entity
|
||||
public class Organization
|
||||
implements Serializable
|
||||
{
|
||||
private String name;
|
||||
|
||||
|
@ -44,4 +44,14 @@ public void setNamespace( String namespace )
|
||||
{
|
||||
this.namespace = namespace;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString()
|
||||
{
|
||||
final StringBuilder sb = new StringBuilder( "ProjectMetadata{" );
|
||||
sb.append( "namespace='" ).append( namespace ).append( '\'' );
|
||||
sb.append( ", id='" ).append( id ).append( '\'' );
|
||||
sb.append( '}' );
|
||||
return sb.toString();
|
||||
}
|
||||
}
|
||||
|
@ -27,6 +27,9 @@
|
||||
public class ProjectVersionMetadata
|
||||
extends FacetedMetadata
|
||||
{
|
||||
/**
|
||||
* id is the version
|
||||
*/
|
||||
private String id;
|
||||
|
||||
private String url;
|
||||
|
@ -19,10 +19,14 @@
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
import javax.persistence.Entity;
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
import java.io.Serializable;
|
||||
|
||||
@XmlRootElement( name = "scm" )
|
||||
@XmlRootElement(name = "scm")
|
||||
@Entity
|
||||
public class Scm
|
||||
implements Serializable
|
||||
{
|
||||
private String connection;
|
||||
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>metadata</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>metadata-repository-api</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -48,6 +48,12 @@ void updateProjectVersion( String repositoryId, String namespace, String project
|
||||
ProjectVersionMetadata versionMetadata )
|
||||
throws MetadataRepositoryException;
|
||||
|
||||
/**
|
||||
* create the namespace in the repository. (if not exist)
|
||||
* @param repositoryId
|
||||
* @param namespace
|
||||
* @throws MetadataRepositoryException
|
||||
*/
|
||||
void updateNamespace( String repositoryId, String namespace )
|
||||
throws MetadataRepositoryException;
|
||||
|
||||
@ -77,6 +83,14 @@ void removeMetadataFacets( String repositoryId, String facetId )
|
||||
void removeMetadataFacet( String repositoryId, String facetId, String name )
|
||||
throws MetadataRepositoryException;
|
||||
|
||||
/**
|
||||
* if startTime or endTime are <code>null</code> they are not used for search
|
||||
* @param repositoryId
|
||||
* @param startTime can be <code>null</code>
|
||||
* @param endTime can be <code>null</code>
|
||||
* @return
|
||||
* @throws MetadataRepositoryException
|
||||
*/
|
||||
List<ArtifactMetadata> getArtifactsByDateRange( String repositoryId, Date startTime, Date endTime )
|
||||
throws MetadataRepositoryException;
|
||||
|
||||
@ -102,11 +116,12 @@ void removeArtifact( ArtifactMetadata artifactMetadata, String baseVersion )
|
||||
throws MetadataRepositoryException;
|
||||
|
||||
/**
|
||||
* Only remove {@link MetadataFacet} for the artifact
|
||||
* @param repositoryId
|
||||
* @param namespace
|
||||
* @param project
|
||||
* @param version
|
||||
* @param metadataFacet will remove artifacts which have this {@link MetadataFacet} using equals
|
||||
* @param metadataFacet
|
||||
* @throws MetadataRepositoryException
|
||||
* @since 1.4-M3
|
||||
*/
|
||||
@ -134,6 +149,14 @@ void removeNamespace( String repositoryId, String namespace )
|
||||
List<ArtifactMetadata> getArtifacts( String repositoryId )
|
||||
throws MetadataRepositoryException;
|
||||
|
||||
/**
|
||||
* basically just checking it exists not complete data returned
|
||||
* @param repoId
|
||||
* @param namespace
|
||||
* @param projectId
|
||||
* @return
|
||||
* @throws MetadataResolutionException
|
||||
*/
|
||||
ProjectMetadata getProject( String repoId, String namespace, String projectId )
|
||||
throws MetadataResolutionException;
|
||||
|
||||
@ -213,6 +236,6 @@ void close()
|
||||
|
||||
boolean canObtainAccess( Class<?> aClass );
|
||||
|
||||
Object obtainAccess( Class<?> aClass )
|
||||
<T>T obtainAccess( Class<T> aClass )
|
||||
throws MetadataRepositoryException;
|
||||
}
|
||||
|
@ -164,8 +164,9 @@ public void testGetProjectOnly()
|
||||
|
||||
// test that namespace is also constructed
|
||||
|
||||
Assertions.assertThat( repository.getRootNamespaces( TEST_REPO_ID ) ).isNotNull().isNotEmpty().contains(
|
||||
TEST_NAMESPACE ).hasSize( 1 );
|
||||
Collection<String> namespaces = repository.getRootNamespaces( TEST_REPO_ID );
|
||||
|
||||
Assertions.assertThat( namespaces ).isNotNull().isNotEmpty().contains( TEST_NAMESPACE ).hasSize( 1 );
|
||||
}
|
||||
|
||||
@Test
|
||||
@ -187,6 +188,7 @@ public void testGetProjectVersionOnly()
|
||||
// test that namespace and project is also constructed
|
||||
assertEquals( Collections.singletonList( TEST_NAMESPACE ), repository.getRootNamespaces( TEST_REPO_ID ) );
|
||||
ProjectMetadata projectMetadata = repository.getProject( TEST_REPO_ID, TEST_NAMESPACE, TEST_PROJECT );
|
||||
assertNotNull( projectMetadata );
|
||||
assertEquals( TEST_PROJECT, projectMetadata.getId() );
|
||||
assertEquals( TEST_NAMESPACE, projectMetadata.getNamespace() );
|
||||
}
|
||||
@ -348,9 +350,10 @@ public void testGetRepositories()
|
||||
repository.updateNamespace( TEST_REPO_ID, "namespace" );
|
||||
repository.updateNamespace( OTHER_REPO_ID, "namespace" );
|
||||
|
||||
assertEquals( "repository.getRepositories() -> " + repository.getRepositories(),
|
||||
Arrays.asList( TEST_REPO_ID, OTHER_REPO_ID ),
|
||||
new ArrayList<String>( repository.getRepositories() ) );
|
||||
Collection<String> repositories = repository.getRepositories();
|
||||
|
||||
assertEquals( "repository.getRepositories() -> " + repositories, Arrays.asList( TEST_REPO_ID, OTHER_REPO_ID ),
|
||||
new ArrayList<String>( repositories ) );
|
||||
}
|
||||
|
||||
@Test
|
||||
@ -573,8 +576,10 @@ public void testGetMetadataFacet()
|
||||
{
|
||||
repository.addMetadataFacet( TEST_REPO_ID, new TestMetadataFacet( TEST_VALUE ) );
|
||||
|
||||
assertEquals( new TestMetadataFacet( TEST_VALUE ),
|
||||
repository.getMetadataFacet( TEST_REPO_ID, TEST_FACET_ID, TEST_NAME ) );
|
||||
TestMetadataFacet test =
|
||||
(TestMetadataFacet) repository.getMetadataFacet( TEST_REPO_ID, TEST_FACET_ID, TEST_NAME );
|
||||
|
||||
assertEquals( new TestMetadataFacet( TEST_VALUE ), test );
|
||||
}
|
||||
|
||||
@Test
|
||||
@ -806,9 +811,10 @@ public void testGetArtifactVersionsMultipleArtifactsSingleVersion()
|
||||
repository.updateArtifact( TEST_REPO_ID, TEST_NAMESPACE, TEST_PROJECT, TEST_PROJECT_VERSION, artifact1 );
|
||||
repository.updateArtifact( TEST_REPO_ID, TEST_NAMESPACE, TEST_PROJECT, TEST_PROJECT_VERSION, artifact2 );
|
||||
|
||||
assertEquals( Collections.singleton( TEST_PROJECT_VERSION ),
|
||||
repository.getArtifactVersions( TEST_REPO_ID, TEST_NAMESPACE, TEST_PROJECT,
|
||||
TEST_PROJECT_VERSION ) );
|
||||
Collection<String> versions =
|
||||
repository.getArtifactVersions( TEST_REPO_ID, TEST_NAMESPACE, TEST_PROJECT, TEST_PROJECT_VERSION );
|
||||
|
||||
assertEquals( Collections.singleton( TEST_PROJECT_VERSION ), versions );
|
||||
}
|
||||
|
||||
@Test
|
||||
@ -819,8 +825,9 @@ public void testGetArtifactsByDateRangeOpen()
|
||||
repository.updateArtifact( TEST_REPO_ID, TEST_NAMESPACE, TEST_PROJECT, TEST_PROJECT_VERSION, artifact );
|
||||
repository.save();
|
||||
|
||||
assertEquals( Collections.singletonList( artifact ),
|
||||
repository.getArtifactsByDateRange( TEST_REPO_ID, null, null ) );
|
||||
List<ArtifactMetadata> artifacts = repository.getArtifactsByDateRange( TEST_REPO_ID, null, null );
|
||||
|
||||
assertEquals( Collections.singletonList( artifact ), artifacts );
|
||||
}
|
||||
|
||||
@Test
|
||||
@ -833,8 +840,9 @@ public void testGetArtifactsByDateRangeSparseNamespace()
|
||||
repository.updateArtifact( TEST_REPO_ID, namespace, TEST_PROJECT, TEST_PROJECT_VERSION, artifact );
|
||||
repository.save();
|
||||
|
||||
assertEquals( Collections.singletonList( artifact ),
|
||||
repository.getArtifactsByDateRange( TEST_REPO_ID, null, null ) );
|
||||
List<ArtifactMetadata> artifacts = repository.getArtifactsByDateRange( TEST_REPO_ID, null, null );
|
||||
|
||||
assertEquals( Collections.singletonList( artifact ), artifacts );
|
||||
}
|
||||
|
||||
@Test
|
||||
@ -846,8 +854,10 @@ public void testGetArtifactsByDateRangeLowerBound()
|
||||
repository.save();
|
||||
|
||||
Date date = new Date( artifact.getWhenGathered().getTime() - 10000 );
|
||||
assertEquals( Collections.singletonList( artifact ),
|
||||
repository.getArtifactsByDateRange( TEST_REPO_ID, date, null ) );
|
||||
|
||||
List<ArtifactMetadata> artifacts = repository.getArtifactsByDateRange( TEST_REPO_ID, date, null );
|
||||
|
||||
assertEquals( Collections.singletonList( artifact ), artifacts );
|
||||
}
|
||||
|
||||
@Test
|
||||
@ -858,7 +868,10 @@ public void testGetArtifactsByDateRangeLowerBoundOutOfRange()
|
||||
repository.updateArtifact( TEST_REPO_ID, TEST_NAMESPACE, TEST_PROJECT, TEST_PROJECT_VERSION, artifact );
|
||||
|
||||
Date date = new Date( artifact.getWhenGathered().getTime() + 10000 );
|
||||
assertTrue( repository.getArtifactsByDateRange( TEST_REPO_ID, date, null ).isEmpty() );
|
||||
|
||||
List<ArtifactMetadata> artifacts = repository.getArtifactsByDateRange( TEST_REPO_ID, date, null );
|
||||
|
||||
Assertions.assertThat( artifacts ).isNotNull().isEmpty();
|
||||
}
|
||||
|
||||
@Test
|
||||
@ -871,8 +884,10 @@ public void testGetArtifactsByDateRangeLowerAndUpperBound()
|
||||
|
||||
Date lower = new Date( artifact.getWhenGathered().getTime() - 10000 );
|
||||
Date upper = new Date( artifact.getWhenGathered().getTime() + 10000 );
|
||||
assertEquals( Collections.singletonList( artifact ),
|
||||
repository.getArtifactsByDateRange( TEST_REPO_ID, lower, upper ) );
|
||||
|
||||
List<ArtifactMetadata> artifacts = repository.getArtifactsByDateRange( TEST_REPO_ID, lower, upper );
|
||||
|
||||
assertEquals( Collections.singletonList( artifact ), artifacts );
|
||||
}
|
||||
|
||||
@Test
|
||||
@ -884,8 +899,10 @@ public void testGetArtifactsByDateRangeUpperBound()
|
||||
repository.save();
|
||||
|
||||
Date upper = new Date( artifact.getWhenGathered().getTime() + 10000 );
|
||||
assertEquals( Collections.singletonList( artifact ),
|
||||
repository.getArtifactsByDateRange( TEST_REPO_ID, null, upper ) );
|
||||
|
||||
List<ArtifactMetadata> artifacts = repository.getArtifactsByDateRange( TEST_REPO_ID, null, upper );
|
||||
|
||||
assertEquals( Collections.singletonList( artifact ), artifacts );
|
||||
}
|
||||
|
||||
@Test
|
||||
@ -897,7 +914,12 @@ public void testGetArtifactsByDateRangeUpperBoundOutOfRange()
|
||||
repository.save();
|
||||
|
||||
Date upper = new Date( artifact.getWhenGathered().getTime() - 10000 );
|
||||
assertTrue( repository.getArtifactsByDateRange( TEST_REPO_ID, null, upper ).isEmpty() );
|
||||
|
||||
List<ArtifactMetadata> artifacts = repository.getArtifactsByDateRange( TEST_REPO_ID, null, upper );
|
||||
|
||||
//assertTrue( .isEmpty() );
|
||||
|
||||
Assertions.assertThat( artifacts ).isNotNull().isEmpty();
|
||||
}
|
||||
|
||||
@Test
|
||||
@ -908,7 +930,9 @@ public void testGetArtifactsByRepoId()
|
||||
repository.updateArtifact( TEST_REPO_ID, TEST_NAMESPACE, TEST_PROJECT, TEST_PROJECT_VERSION, artifact );
|
||||
repository.save();
|
||||
|
||||
assertEquals( Collections.singletonList( artifact ), repository.getArtifacts( TEST_REPO_ID ) );
|
||||
List<ArtifactMetadata> artifacts = repository.getArtifacts( TEST_REPO_ID );
|
||||
|
||||
assertEquals( Collections.singletonList( artifact ), artifacts );
|
||||
}
|
||||
|
||||
@Test
|
||||
@ -1191,13 +1215,17 @@ public void deleteArtifact()
|
||||
|
||||
repository.updateArtifact( TEST_REPO_ID, TEST_NAMESPACE, TEST_PROJECT, TEST_PROJECT_VERSION, artifact );
|
||||
|
||||
assertEquals( Collections.singletonList( artifact ), new ArrayList<ArtifactMetadata>(
|
||||
repository.getArtifacts( TEST_REPO_ID, TEST_NAMESPACE, TEST_PROJECT, TEST_PROJECT_VERSION ) ) );
|
||||
Collection<ArtifactMetadata> artifacts =
|
||||
repository.getArtifacts( TEST_REPO_ID, TEST_NAMESPACE, TEST_PROJECT, TEST_PROJECT_VERSION );
|
||||
|
||||
assertEquals( Collections.singletonList( artifact ), new ArrayList<ArtifactMetadata>( artifacts ) );
|
||||
|
||||
repository.removeArtifact( TEST_REPO_ID, TEST_NAMESPACE, TEST_PROJECT, TEST_PROJECT_VERSION, artifact.getId() );
|
||||
|
||||
assertTrue(
|
||||
repository.getArtifacts( TEST_REPO_ID, TEST_NAMESPACE, TEST_PROJECT, TEST_PROJECT_VERSION ).isEmpty() );
|
||||
artifacts =
|
||||
repository.getArtifacts( TEST_REPO_ID, TEST_NAMESPACE, TEST_PROJECT, TEST_PROJECT_VERSION );
|
||||
|
||||
Assertions.assertThat( artifacts ).isNotNull().isEmpty();
|
||||
}
|
||||
|
||||
@Test
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>archiva-modules</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>metadata</artifactId>
|
||||
<name>Archiva :: Metadata</name>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>metadata</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>test-repository</artifactId>
|
||||
<name>Archiva Metadata :: Repository for Testing</name>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>plugins</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>audit</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>plugins</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>generic-metadata-support</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -23,7 +23,7 @@
|
||||
<parent>
|
||||
<artifactId>plugins</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>maven1-repository</artifactId>
|
||||
<name>Archiva Core Plugins :: Maven 1.x Repository Support</name>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>plugins</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>maven2-repository</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -176,27 +176,27 @@ public Collection<ArtifactMetadata> getArtifacts( String repoId, String namespac
|
||||
|
||||
public void save()
|
||||
{
|
||||
//To change body of implemented methods use File | Settings | File Templates.
|
||||
//
|
||||
}
|
||||
|
||||
public void close()
|
||||
{
|
||||
//To change body of implemented methods use File | Settings | File Templates.
|
||||
//
|
||||
}
|
||||
|
||||
public void revert()
|
||||
{
|
||||
//To change body of implemented methods use File | Settings | File Templates.
|
||||
//
|
||||
}
|
||||
|
||||
public boolean canObtainAccess( Class<?> aClass )
|
||||
{
|
||||
return false; //To change body of implemented methods use File | Settings | File Templates.
|
||||
return false;
|
||||
}
|
||||
|
||||
public Object obtainAccess( Class<?> aClass )
|
||||
public <T>T obtainAccess( Class<T> aClass )
|
||||
{
|
||||
return null; //To change body of implemented methods use File | Settings | File Templates.
|
||||
return null;
|
||||
}
|
||||
|
||||
public void removeArtifact( String repositoryId, String namespace, String project, String version,
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>plugins</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>metadata-store-file</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -559,7 +559,7 @@ public boolean canObtainAccess( Class<?> aClass )
|
||||
return false;
|
||||
}
|
||||
|
||||
public Object obtainAccess( Class<?> aClass )
|
||||
public <T>T obtainAccess( Class<T> aClass )
|
||||
{
|
||||
throw new IllegalArgumentException(
|
||||
"Access using " + aClass + " is not supported on the file metadata storage" );
|
||||
|
@ -23,7 +23,7 @@
|
||||
<parent>
|
||||
<artifactId>plugins</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>metadata-store-jcr</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -1256,14 +1256,14 @@ public boolean canObtainAccess( Class<?> aClass )
|
||||
return aClass == Session.class;
|
||||
}
|
||||
|
||||
public Object obtainAccess( Class<?> aClass )
|
||||
public <T>T obtainAccess( Class<T> aClass )
|
||||
throws MetadataRepositoryException
|
||||
{
|
||||
if ( aClass == Session.class )
|
||||
{
|
||||
try
|
||||
{
|
||||
return getJcrSession();
|
||||
return (T) getJcrSession();
|
||||
}
|
||||
catch ( RepositoryException e )
|
||||
{
|
||||
|
@ -23,7 +23,7 @@
|
||||
<parent>
|
||||
<artifactId>plugins</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>npanday-support</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>archiva-modules</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>plugins</artifactId>
|
||||
<name>Archiva :: Core Plugins</name>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<parent>
|
||||
<artifactId>plugins</artifactId>
|
||||
<groupId>org.apache.archiva</groupId>
|
||||
<version>1.4-M4-SNAPSHOT</version>
|
||||
<version>1.4-M5-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>problem-reports</artifactId>
|
||||
<packaging>bundle</packaging>
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user