archiva-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Olivier Lamy <ol...@apache.org>
Subject Re: Uploading artifacts using the REST API of Archiva 1.4
Date Wed, 29 May 2013 02:02:08 GMT
Hi,
Deploying mean only using PUT to the correct uri.
No need of rest api :-).


2013/5/29 Lothar Werzinger <lothar@tradescape.biz>:
> Hi,
>
> I am researching Archiva and I tried using the REST API for Archiva 1.4.
>
> I am using 1.4-M3 as well as the staged 1.4-M4 from
> https://dist.apache.org/repos/dist/dev/archiva/1.4-M4
>
> The upload API is a bit confusing, but I could figure out how it works by
> using wireshark and monitoring what the manual upload page did.
> With 1.4-M3 I managed to upload a SNAPSHOT artifact (with the manual upload
> page) to the *internal* repository, rendering it unusable (I had to
> re-install Archiva)
>
> I can now upload an artifact to archiva via the REST API, but the API does
> not return a conclusive result as to the fact that the upload (and
> insertion onto the repository) actually worked or not.
> For my use case I need to present the user with a meaningful error message
> if inserting an artifact into the repository fails, so I am interested to
> hear what the correct way of doing this might be.
>
> As a work-around I tried to search for the just uploaded artifact but I ran
> into some snags there, too.
>
>    - With 1.4-M3 the upload seems to be asynchronous, so I can only wait an
>    arbitrary amount of time before checking if the artifact is there.
>    - With 1.4-M4 the (advanced) search seems to be no longer working at all
>    REST API and search page always return no match although I can verify that
>    the artifact exists by browsing to it.
>

upload using PUT is synchronous.
Note the search api use the indexing. And indexing is async (all
indexing tasks go to a queue) so depending on the load on your system
I can take few minutes.

>
> Any help is highly appreciated.
> Thanks in advance!
> --
>
> Lothar Werzinger
>
> Principal Architect
>
> Tradescape, Inc. - Enabling Efficient Digital Marketplaces
>
> +1-650-931-6719 (direct)
>
> +1-800-697-6068 (main) Ext. 116
>
> lothar@tradescape.biz<https://mail.google.com/mail/?view=cm&fs=1&tf=1&to=lothar@tradescape.biz>
>
> http://www.tradescape.biz
>
>
>
> This message and any attachment (the "message") is intended solely for the
>
> addressees and is confidential. If you receive this message by mistake,
>
> please delete it and notify the sender immediately. Any use not in
>
> accordance with its purpose, any out-spread or disclosure, either as a whole
>
> or partially, is prohibited except with formal approval. Internet cannot
>
> guarantee the integrity of this message, therefore Tradescape will not be
>
> liable for the message if modified.
>
> --
>
>
> This message and any attachment (the "message") is intended solely for the
> addressees and is confidential. If you receive this message by mistake,
> please delete it and notify the sender immediately. Any use not
> in accordance with its purpose, any out-spread or disclosure, either as a
> whole or partially, is prohibited except with formal approval. Internet
> cannot guarantee the integrity of this message, therefore Tradescape will
> not be liable for the message if modified.
>
> -



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

Mime
View raw message