Background

In wich cases should i use this wagon?

If you use maven 2 and there is a maven repository wich is hosted at sourceforge.net file release area. Then you should use this wagon to download the artifacts from sf file release area.

Important is, for remote repositories maven required checksum files. This means in the file release area must be exists checksum files additional to the artifacts (such as jars).


Which maven repository contains the wagon-http-sourceforge?

This wagon is not available in the standard maven repository. You need entries in your pom.xml and in your settings.xml.

Here are the entries in your pom.xml wich are needed.

	<build>
		<extensions>
			<extension>
				<groupId>net.sf.maven.plugins</groupId>
				<artifactId>wagon-http-sourceforge</artifactId>
				<version>0.4</version>
			</extension>
		</extensions>
		:
	</build>	
				
	<repositories>
		<repository>
			<id>sourceforge-svn</id>
			<name>SF Maven Plugin SVN Repository</name>
			<url>http://sf-mvn-plugins.svn.sourceforge.net/svnroot/sf-mvn-plugins/_m2-repo</url>
		</repository>
	</repositories>


	<pluginRepositories>
		<pluginRepository>
			<id>sourceforge-frs</id>
			<name>SF Maven Plugin Repository</name>
			<url>http://sourceforge.net/projects/sf-mvn-plugins/files/m2-repo</url>
		</pluginRepository>
		<pluginRepository>
			<id>sourceforge-frs</id>
			<name>Your 2. SF Maven Plugin Repository</name>
			<url>http://sourceforge.net/projects/your_path_to_m2_repo</url>
		</pluginRepository>
	</pluginRepositories>
	          

Here are the entries in your settings.xml wich are needed.

   <server>
      <id>sourceforge-frs</id>
      <configuration>
        <wagonProvider>sourceforge</wagonProvider>
     </configuration>
   </server>
               

The repository id in your pom.xml and your settings.xml to download the artifacts from sourceforge file release system must be the same (here: sourceforge-frs)!

For additional sourceforge repositories you can use the same id or add a server part to settings.xml with correct id.

Example to use the wagon-http-sourceforge

Where can i find a example to use?

Download the example project zip from the example website http://sf-mvn-plugins.sourceforge.net/example-1jar-thinlet

Known bugs of Extension/Plugin

Wich bugs are known?
  • The sourceforge site response for missing artifacts is is not 404 page not found. Sourceforge will send a error page within the response. So maven could not be detect a error. This is a big problem. We have tried to solve it with this workaround:
    1. Response Code 302 will be downloaded
    2. Response Code 301 will be canceled