return path;
}
- private String evaluatePathWithVersion( ArchivaDavResourceLocator archivaLocator,
- ManagedRepositoryContent managedRepositoryContent, String contextPath )
+ private String evaluatePathWithVersion( ArchivaDavResourceLocator archivaLocator, //
+ ManagedRepositoryContent managedRepositoryContent, //
+ String contextPath )
throws DavException
{
String layout = managedRepositoryContent.getRepository() == null
this.applicationContext.getBean( "repositoryStorage#" + layout, RepositoryStorage.class );
try
{
- return repositoryStorage.getFilePathWithVersion( archivaLocator.getResourcePath(),
+ return repositoryStorage.getFilePathWithVersion( archivaLocator.getResourcePath(), //
managedRepositoryContent );
}
catch ( RelocationException e )
import org.apache.archiva.metadata.model.ArtifactMetadata;
import org.apache.archiva.metadata.model.ProjectMetadata;
import org.apache.archiva.metadata.model.ProjectVersionMetadata;
+import org.apache.archiva.metadata.model.facets.RepositoryProblemFacet;
import org.apache.archiva.metadata.repository.filter.Filter;
import org.apache.archiva.metadata.repository.storage.ReadMetadataRequest;
import org.apache.archiva.metadata.repository.storage.RelocationException;
import org.apache.archiva.policies.ProxyDownloadException;
import org.apache.archiva.proxy.common.WagonFactory;
import org.apache.archiva.proxy.model.RepositoryProxyConnectors;
-import org.apache.archiva.metadata.model.facets.RepositoryProblemFacet;
import org.apache.archiva.repository.ManagedRepositoryContent;
import org.apache.archiva.repository.content.PathParser;
import org.apache.archiva.repository.layout.LayoutException;
* within the session in the context of a single managed repository's resolution needs.
* <p/>
*/
-@Service("repositoryStorage#maven2")
+@Service( "repositoryStorage#maven2" )
public class Maven2RepositoryStorage
implements RepositoryStorage
{
private NetworkProxyAdmin networkProxyAdmin;
@Inject
- @Named("repositoryPathTranslator#maven2")
+ @Named( "repositoryPathTranslator#maven2" )
private RepositoryPathTranslator pathTranslator;
@Inject
private ApplicationContext applicationContext;
@Inject
- @Named("pathParser#default")
+ @Named( "pathParser#default" )
private PathParser pathParser;
private static final String METADATA_FILENAME_START = "maven-metadata";
int buildNumber = archivaRepositoryMetadata.getSnapshotVersion().getBuildNumber();
String timestamp = archivaRepositoryMetadata.getSnapshotVersion().getTimestamp();
+ // MRM-1846
+ if ( buildNumber < 1 && timestamp == null )
+ {
+ return filePath;
+ }
+
// org/apache/archiva/archiva-checksum/1.4-M4-SNAPSHOT/archiva-checksum-1.4-M4-SNAPSHOT.jar
// -> archiva-checksum-1.4-M4-20130425.081822-1.jar