You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@archiva.apache.org by "Martin Schreier (Jira)" <ji...@apache.org> on 2022/01/06 18:55:00 UTC

[jira] [Closed] (MRM-1980) Rest documentation & Rest services don't work

     [ https://issues.apache.org/jira/browse/MRM-1980?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Martin Schreier closed MRM-1980.
--------------------------------
    Resolution: Won't Fix

We are switching to OpenAP for REST API v2 in the new release. No further investigation for the old service interface.

> Rest documentation & Rest services don't work
> ---------------------------------------------
>
>                 Key: MRM-1980
>                 URL: https://issues.apache.org/jira/browse/MRM-1980
>             Project: Archiva
>          Issue Type: Bug
>          Components: rest services
>    Affects Versions: 2.2.3
>            Reporter: Finn
>            Assignee: Martin Schreier
>            Priority: Major
>             Fix For: 3.0.0
>
>
> I started Archive on a Linux server as well as on my local windows machine, and in both cases the url +[http://host:8080/#rest-docs-archiva-rest-api/application.wadl|http://host:8080/#rest-docs-archiva-rest-api/application.wadl+]+ will result in an error:
> {noformat}
> An error has happened you must contact the administrator to check the logs.{noformat}
> Accessing the rest service via +[http://host:8080/restServices|http://host:8080/restServices+]+ works, but following any link will result in an empty page and a 404 status code. My first assumption was a configuration issue, but I could not find ANY information about this and the existing docs don't mention any configuration requirements to use the REST API
> Additionally the wrapper.logs show the following exception:
>  
> {noformat}
> INFO   | jvm 1    | 2018/06/13 12:35:36 | 2018-06-13 12:35:35.992:WARN:oejs.ServletHandler:/rest-docs/rest-docs-archiva-rest-api/application.wadl
> INFO   | jvm 1    | 2018/06/13 12:35:36 | java.lang.IllegalArgumentException: Object must not be null
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.jsoup.helper.Validate.notNull(Validate.java:16)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.jsoup.nodes.Element.appendChild(Element.java:262)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.apache.archiva.web.docs.RestDocsServlet.doGet(RestDocsServlet.java:110)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at javax.servlet.http.HttpServlet.service(HttpServlet.java:735)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:684)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:501)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:137)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:557)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:231)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1086)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:428)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:193)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1020)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:135)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:255)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:154)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:116)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.server.Server.handle(Server.java:370)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:494)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.server.AbstractHttpConnection.headerComplete(AbstractHttpConnection.java:971)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.headerComplete(AbstractHttpConnection.java:1033)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:644)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:235)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.server.AsyncHttpConnection.handle(AsyncHttpConnection.java:82)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:667)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:52)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:608)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:543)
> INFO   | jvm 1    | 2018/06/13 12:35:36 |     at java.lang.Thread.run(Thread.java:748){noformat}
> And the archiva.log shows:
>  
> {noformat}
>  
> 2018-06-13 12:36:41,136 [qtp767343233-28] WARN  org.apache.cxf.jaxrs.interceptor.JAXRSInInterceptor [] - No root resource matching request path /restServices/archivaServices has been found, Relative Path: /. Please enable FINE/TRACE log level for more details.
> 2018-06-13 12:36:41,137 [qtp767343233-28] WARN  org.apache.cxf.jaxrs.impl.WebApplicationExceptionMapper [] - javax.ws.rs.NotFoundException: HTTP 404 Not Found
>     at org.apache.cxf.jaxrs.utils.SpecExceptions.toNotFoundException(SpecExceptions.java:89)
>     at org.apache.cxf.jaxrs.utils.ExceptionUtils.toNotFoundException(ExceptionUtils.java:126)
>     at org.apache.cxf.jaxrs.interceptor.JAXRSInInterceptor.processRequest(JAXRSInInterceptor.java:169)
>     at org.apache.cxf.jaxrs.interceptor.JAXRSInInterceptor.handleMessage(JAXRSInInterceptor.java:77)
>     at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:307)
>     at org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121)
>     at org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractHTTPDestination.java:251)
>     at org.apache.cxf.transport.servlet.ServletController.invokeDestination(ServletController.java:223)
>     at org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.java:197)
>     at org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.java:149)
>     at org.apache.cxf.transport.servlet.CXFNonSpringServlet.invoke(CXFNonSpringServlet.java:171)
>     at org.apache.cxf.transport.servlet.AbstractHTTPServlet.handleRequest(AbstractHTTPServlet.java:290)
>     at org.apache.cxf.transport.servlet.AbstractHTTPServlet.doGet(AbstractHTTPServlet.java:214)
>     at javax.servlet.http.HttpServlet.service(HttpServlet.java:735)
>     at org.apache.cxf.transport.servlet.AbstractHTTPServlet.service(AbstractHTTPServlet.java:265)
>     at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:684)
>     at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1496)
>     at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:85)
>     at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
>     at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1476)
>     at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:499)
>     at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:137)
>     at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:557)
>     at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:231)
>     at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1086)
>     at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:428)
>     at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:193)
>     at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1020)
>     at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:135)
>     at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:255)
>     at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:154)
>     at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:116)
>     at org.eclipse.jetty.server.Server.handle(Server.java:370)
>     at org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:494)
>     at org.eclipse.jetty.server.AbstractHttpConnection.headerComplete(AbstractHttpConnection.java:971)
>     at org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.headerComplete(AbstractHttpConnection.java:1033)
>     at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:644)
>     at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:235)
>     at org.eclipse.jetty.server.AsyncHttpConnection.handle(AsyncHttpConnection.java:82)
>     at org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:667)
>     at org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:52)
>     at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:608)
>     at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:543)
>     at java.lang.Thread.run(Thread.java:748)
> {noformat}
>  



--
This message was sent by Atlassian Jira
(v8.20.1#820001)