Discussion:
[jira] [Created] (MRM-1917) REST API doesn't work the second time with v=LATEST
Mohamed (JIRA)
2016-07-04 14:21:11 UTC
Permalink
Mohamed created MRM-1917:
-----------------------------

Summary: REST API doesn't work the second time with v=LATEST
Key: MRM-1917
URL: https://issues.apache.org/jira/browse/MRM-1917
Project: Archiva
Issue Type: Bug
Reporter: Mohamed



Please find below the URL I use to get the latest version of artifacts. The URL is working fine the first time, and when I retry it seems broken nothing is received by the browser or by CURL script.
http://archiva.company.com/restServices/archivaServices/searchService/artifact?g=com.company&a=company-artifact&v=LATEST&p=jar&r=snapshots 

We use this API to get the latest version of artifacts it is a main part in our infrastructure for continuous delivery.

Could you please check that? There is no simple manner to handle that ?
Thnak you



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
Mohamed (JIRA)
2016-07-04 14:22:10 UTC
Permalink
[ https://issues.apache.org/jira/browse/MRM-1917?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mohamed updated MRM-1917:
--------------------------
Affects Version/s: 2.2.0
Priority: Critical (was: Major)
Description:
Please find below the URL I use to get the latest version of artifacts. The URL is working fine the first time, and when I retry it seems broken nothing is received by the browser or by CURL script.
http://archiva.company.com/restServices/archivaServices/searchService/artifact?g=com.company&a=company-artifact&v=LATEST&p=jar&r=snapshots 

We use this API to get the latest version of artifacts it is a main part in our infrastructure for continuous delivery.

Could you please check that? There is no simple manner to handle that ?
Thnak you

was:

Please find below the URL I use to get the latest version of artifacts. The URL is working fine the first time, and when I retry it seems broken nothing is received by the browser or by CURL script.
http://archiva.company.com/restServices/archivaServices/searchService/artifact?g=com.company&a=company-artifact&v=LATEST&p=jar&r=snapshots 

We use this API to get the latest version of artifacts it is a main part in our infrastructure for continuous delivery.

Could you please check that? There is no simple manner to handle that ?
Thnak you

Component/s: rest services
Post by Mohamed (JIRA)
REST API doesn't work the second time with v=LATEST
---------------------------------------------------
Key: MRM-1917
URL: https://issues.apache.org/jira/browse/MRM-1917
Project: Archiva
Issue Type: Bug
Components: rest services
Affects Versions: 2.2.0
Reporter: Mohamed
Priority: Critical
Please find below the URL I use to get the latest version of artifacts. The URL is working fine the first time, and when I retry it seems broken nothing is received by the browser or by CURL script.
http://archiva.company.com/restServices/archivaServices/searchService/artifact?g=com.company&a=company-artifact&v=LATEST&p=jar&r=snapshots 
We use this API to get the latest version of artifacts it is a main part in our infrastructure for continuous delivery.
Could you please check that? There is no simple manner to handle that ?
Thnak you
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
ganthore (JIRA)
2016-09-13 18:07:20 UTC
Permalink
[ https://issues.apache.org/jira/browse/MRM-1917?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15487943#comment-15487943 ]

ganthore commented on MRM-1917:
-------------------------------

I'm experiencing a similar problem with a brand new setup. I've tested against both 2.2.0 and 2.2.1 so far using the standalone distribution that runs through jetty.

It seems like the API is non-functional. I can consistently reproduce a 204 error, but when I browse to the autoindex via http, the content loads fine (http://archiva.foo.bar.com/repository/internal/com/bar/foo/myArtifact/7.2.0/)

Note that 7.2.0 is the latest and ONLY artifact in the folder right now. I also tried using v=7.2.0 but it still throws a 204.

Curl output shows:

{code}
curl -i -v http://archiva.foo.bar.com:8080/restServices/archivaServices/searchService/artifact?g=com.bar.foo&a=myArtifact&v=LATEST&p=zip
* Trying 10.x.x.x...
* Connected to archiva.foo.bar.com (10.x.x.x) port 8080 (#0)
GET /restServices/archivaServices/searchService/artifact?g=com.bar.foo HTTP/1.1
Host: archiva.foo.bar.com:8080
User-Agent: curl/7.43.0
Accept: */*
< HTTP/1.1 204 No Content
HTTP/1.1 204 No Content
< Date: Tue, 13 Sep 2016 17:57:45 GMT
Date: Tue, 13 Sep 2016 17:57:45 GMT
< Set-Cookie: JSESSIONID=13ft4pukpyn7j8d8y0yggdcz;Path=/
Set-Cookie: JSESSIONID=13ft4pukpyn7j8d8y0yggdcz;Path=/
< Expires: Thu, 01 Jan 1970 00:00:00 GMT
Expires: Thu, 01 Jan 1970 00:00:00 GMT
< Content-Length: 0
Content-Length: 0
< Date: Tue, 13 Sep 2016 17:57:45 GMT
Date: Tue, 13 Sep 2016 17:57:45 GMT
< Server: Jetty(8.1.14.v20131031)
Server: Jetty(8.1.14.v20131031)

<
* Connection #0 to host archiva.foo.bar.com left intact
{code}
REST API doesn't work the second time with v=LATEST
---------------------------------------------------
Key: MRM-1917
URL: https://issues.apache.org/jira/browse/MRM-1917
Project: Archiva
Issue Type: Bug
Components: rest services
Affects Versions: 2.2.0
Reporter: Mohamed
Priority: Critical
Please find below the URL I use to get the latest version of artifacts. The URL is working fine the first time, and when I retry it seems broken nothing is received by the browser or by CURL script.
http://archiva.company.com/restServices/archivaServices/searchService/artifact?g=com.company&a=company-artifact&v=LATEST&p=jar&r=snapshots 
We use this API to get the latest version of artifacts it is a main part in our infrastructure for continuous delivery.
Could you please check that? There is no simple manner to handle that ?
Thnak you
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
Martin Stockhammer (JIRA)
2016-09-16 19:48:20 UTC
Permalink
[ https://issues.apache.org/jira/browse/MRM-1917?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15497200#comment-15497200 ]

Martin Stockhammer commented on MRM-1917:
-----------------------------------------

I cannot reproduce the problem. Could you please provide more information:
- How many repositories do you have in your configuration?
- Did you check the permissions of your repository?
- What type of content storage do you use?
- How many versions of your artifact are stored in your repository
- What is the configured cron string of your repository?

[~ganthore]: if you get always the 204, then I think the artifact is not indexed. Do you find your artifact by the Search form in the Web UI?
Post by Mohamed (JIRA)
REST API doesn't work the second time with v=LATEST
---------------------------------------------------
Key: MRM-1917
URL: https://issues.apache.org/jira/browse/MRM-1917
Project: Archiva
Issue Type: Bug
Components: rest services
Affects Versions: 2.2.0
Reporter: Mohamed
Priority: Critical
Please find below the URL I use to get the latest version of artifacts. The URL is working fine the first time, and when I retry it seems broken nothing is received by the browser or by CURL script.
http://archiva.company.com/restServices/archivaServices/searchService/artifact?g=com.company&a=company-artifact&v=LATEST&p=jar&r=snapshots 
We use this API to get the latest version of artifacts it is a main part in our infrastructure for continuous delivery.
Could you please check that? There is no simple manner to handle that ?
Thnak you
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
Martin Stockhammer (JIRA)
2018-05-13 17:28:00 UTC
Permalink
[ https://issues.apache.org/jira/browse/MRM-1917?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Martin Stockhammer resolved MRM-1917.
-------------------------------------
Resolution: Cannot Reproduce

No answer to my questions. Closing the issue.
Post by Mohamed (JIRA)
REST API doesn't work the second time with v=LATEST
---------------------------------------------------
Key: MRM-1917
URL: https://issues.apache.org/jira/browse/MRM-1917
Project: Archiva
Issue Type: Bug
Components: rest services
Affects Versions: 2.2.0
Reporter: Mohamed
Priority: Critical
Please find below the URL I use to get the latest version of artifacts. The URL is working fine the first time, and when I retry it seems broken nothing is received by the browser or by CURL script.
http://archiva.company.com/restServices/archivaServices/searchService/artifact?g=com.company&a=company-artifact&v=LATEST&p=jar&r=snapshots 
We use this API to get the latest version of artifacts it is a main part in our infrastructure for continuous delivery.
Could you please check that? There is no simple manner to handle that ?
Thnak you
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Loading...