diff options
author | olivier lamy <olamy@apache.org> | 2017-08-19 21:37:35 +1000 |
---|---|---|
committer | olivier lamy <olamy@apache.org> | 2017-08-19 21:37:35 +1000 |
commit | 7a2710ec0a566f44a1f135b71176addfdd7047e7 (patch) | |
tree | 48886c9c6e6d66035093df4c6bbb866b83253ead /archiva-modules/archiva-web/archiva-webdav | |
parent | f93a787e74f048fd4fe393819c09d898da63b4f4 (diff) | |
parent | 88385088993b8121099f48371ce9e00689ccb547 (diff) | |
download | archiva-7a2710ec0a566f44a1f135b71176addfdd7047e7.tar.gz archiva-7a2710ec0a566f44a1f135b71176addfdd7047e7.zip |
Merge branch 'feature/jcr_oak'
Diffstat (limited to 'archiva-modules/archiva-web/archiva-webdav')
-rw-r--r-- | archiva-modules/archiva-web/archiva-webdav/pom.xml | 20 | ||||
-rw-r--r-- | archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/util/MavenIndexerCleaner.java | 14 |
2 files changed, 7 insertions, 27 deletions
diff --git a/archiva-modules/archiva-web/archiva-webdav/pom.xml b/archiva-modules/archiva-web/archiva-webdav/pom.xml index 33c876011..1a2887918 100644 --- a/archiva-modules/archiva-web/archiva-webdav/pom.xml +++ b/archiva-modules/archiva-web/archiva-webdav/pom.xml @@ -95,20 +95,6 @@ <artifactId>archiva-filelock</artifactId> </dependency> <dependency> - <groupId>org.apache.jackrabbit</groupId> - <artifactId>jackrabbit-webdav</artifactId> - <exclusions> - <exclusion> - <groupId>org.slf4j</groupId> - <artifactId>jcl-over-slf4j</artifactId> - </exclusion> - </exclusions> - </dependency> - <dependency> - <groupId>org.apache.jackrabbit</groupId> - <artifactId>jackrabbit-jcr-commons</artifactId> - </dependency> - <dependency> <groupId>joda-time</groupId> <artifactId>joda-time</artifactId> </dependency> @@ -117,6 +103,10 @@ <artifactId>spring-web</artifactId> </dependency> <dependency> + <groupId>org.apache.jackrabbit</groupId> + <artifactId>jackrabbit-webdav</artifactId> + </dependency> + <dependency> <groupId>commons-io</groupId> <artifactId>commons-io</artifactId> </dependency> @@ -302,8 +292,6 @@ org.apache.archiva.metadata.repository.storage;version=${project.version}, org.apache.commons.io;version="[1.4,2)", org.apache.commons.lang;version="[2.4,3)", - org.apache.jackrabbit.util;version="[1,3)", - org.apache.jackrabbit.webdav*;version="[1,3)", org.joda.time*;version="[1.5,2)", org.springframework*;version="[3,4)", org.apache.maven.index*, diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/util/MavenIndexerCleaner.java b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/util/MavenIndexerCleaner.java index 079828fbe..cd59302e7 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/util/MavenIndexerCleaner.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/util/MavenIndexerCleaner.java @@ -18,23 +18,18 @@ package org.apache.archiva.webdav.util; * under the License. */ -import org.apache.archiva.common.plexusbridge.PlexusSisuBridge; -import org.apache.archiva.common.plexusbridge.PlexusSisuBridgeException; import org.apache.maven.index.NexusIndexer; import org.apache.maven.index.context.IndexingContext; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.context.ApplicationContext; import org.springframework.stereotype.Service; -import org.springframework.web.context.WebApplicationContext; -import org.springframework.web.context.support.WebApplicationContextUtils; import javax.annotation.PostConstruct; import javax.annotation.PreDestroy; import javax.inject.Inject; import javax.servlet.ServletContextEvent; import javax.servlet.ServletContextListener; -import java.io.IOException; /** * @author Olivier Lamy @@ -46,15 +41,16 @@ public class MavenIndexerCleaner Logger log = LoggerFactory.getLogger( getClass() ); - private PlexusSisuBridge plexusSisuBridge; @Inject private ApplicationContext applicationContext; + @Inject + NexusIndexer nexusIndexer; + @PostConstruct public void startup() { - plexusSisuBridge = applicationContext.getBean( PlexusSisuBridge.class ); cleanupIndex(); } @@ -70,9 +66,6 @@ public class MavenIndexerCleaner { try { - WebApplicationContext wacu = - WebApplicationContextUtils.getRequiredWebApplicationContext( servletContextEvent.getServletContext() ); - plexusSisuBridge = wacu.getBean( PlexusSisuBridge.class ); cleanupIndex(); } @@ -103,7 +96,6 @@ public class MavenIndexerCleaner log.info( "cleanup IndexingContext" ); try { - NexusIndexer nexusIndexer = plexusSisuBridge.lookup( NexusIndexer.class ); for ( IndexingContext context : nexusIndexer.getIndexingContexts().values() ) { nexusIndexer.removeIndexingContext( context, true ); |