You will probably need to add " &p=zip" at end as defaults to jar.
 
Direct:  
-----Original Message-----
From: Olivier Lamy [mailto:ol...@apache.org] 
Sent: 17 June 2015 01:40
To: users@archiva.apache.org
Subject: Re: 404 error when attempting to query artifact

Hi,
I think documentation is wrong as now Archiva is per default on / so use

wget "
http://hamlet:8080/restServices/archivaServices/searchService/artifact?g=my-demos&a=JavaDemos&v=LATEST
<http://hamlet:8080/archiva/restServices/archivaServices/searchService/artifact?g=my-demos&a=JavaDemos&v=LATEST>
"
Please note for this url you will have a redirect to download the artifact.

Olivier


On 17 June 2015 at 06:55, Thad Humphries <thad.humphr...@gmail.com> wrote:

> I have a ZIP file stored on my Archiva 2.2 server. Anyone here can 
> reach it through a browser at
>
> http://hamlet:8080/#artifact-details-download-content/my-demos/JavaDem
> os/8.1 and download it without being logged in by clicking the 
> removable media icon.
>
> I'd like to download this file from a script, so I try the wget 
> described
> at:
>
> http://archiva.apache.org/docs/2.2.0/userguide/querying-artifacts.html
>
>
> but I get a 404 error:
>
> $ wget "
>
> http://hamlet:8080/archiva/restServices/archivaServices/searchService/
> artifact?g=my-demos&a=JavaDemos&v=LATEST
> "
>
> --2015-06-16 16:42:33--
>
> http://hamlet:8080/archiva/restServices/archivaServices/searchService/
> artifact?g=my-demos&a=JavaDemos&v=LATEST
>
> Resolving hamlet (hamlet)... 10.1.2.1
>
> Connecting to hamlet (hamlet)|10.1.2.1|:8080... connected.
>
> HTTP request sent, awaiting response... 404 Not Found
>
> 2015-06-16 16:42:33 ERROR 404: Not Found.
>
>
> What is the problem and how do I correct it?
>
> --
> "Hell hath no limits, nor is circumscrib'd In one self-place; but 
> where we are is hell, And where hell is, there must we ever be" 
> --Christopher Marlowe, *Doctor Faustus* (v. 121-24)
>



--
Olivier Lamy
http://twitter.com/olamy | http://linkedin.com/in/olamy

Reply via email to