Uploaded image for project: 'DSpace'
  1. DSpace
  2. DS-4085

Sword v2 endpoint returns HTTP 500 when creating an item

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 5.9, 5.10
    • Fix Version/s: 5.11
    • Component/s: SWORD
    • Labels:
      None
    • Attachments:
      0
    • Comments:
      3
    • Documentation Status:
      Not Required

      Description

      The following interaction with the Sword V2 endpoint always triggers a 500 error:

      curl --header "Content-Type: application/atom+xml; charset=utf-8" --header "In-Progress: true" \
          --request POST \
          --data '<?xml version="1.0" encoding="UTF-8"?><entry xmlns="http://www.w3.org/2005/Atom"><title>Test</title></entry>' \
          --user "admin:admin" \
          http://localhost:8080/swordv2/collection/123456789/1 

      The following error can be found in the logs:

       

      Nov 15, 2018 3:55:28 PM org.apache.catalina.core.StandardWrapperValve invoke
      SEVERE: Servlet.service() for servlet [collection] in context with path [/swordv2] threw exception [Servlet execution threw an exception] with root cause
      java.lang.VerifyError: org/apache/abdera/parser/stax/FOMBuilder
              at org.apache.abdera.parser.stax.FOMParser.parse(FOMParser.java:190)
              at org.apache.abdera.parser.stax.FOMParser.parse(FOMParser.java:124)
              at org.apache.abdera.util.AbstractParser.parse(AbstractParser.java:65)
              at org.swordapp.server.SwordAPIEndpoint.addDepositPropertiesFromEntry(SwordAPIEndpoint.java:355)
              at org.swordapp.server.CollectionAPI.post(CollectionAPI.java:156)
              at org.swordapp.server.servlets.CollectionServletDefault.doPost(CollectionServletDefault.java:48)
              at javax.servlet.http.HttpServlet.service(HttpServlet.java:650)
              at javax.servlet.http.HttpServlet.service(HttpServlet.java:731)
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
              at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:219)
              at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:110)
              at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:494)
              at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:169)
              at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
              at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:1025)
              at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)
              at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:445)
              at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1137)
              at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:637)
              at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:316)
              at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1152)
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:622)
              at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
              at java.lang.Thread.run(Thread.java:748) 

      This work updates the abdera-client dependency.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              andrewb Andrew Bennet
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: