Uploaded image for project: 'MyCoRe'
  1. MCR-1325

MCRMODSLinksEventHandler throws FileNotFoundException

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Medium
    • Resolution: Duplicate
    • Affects Version/s: 2016.06.0, 2016.12
    • Fix Version/s: 2018.05, 2017.06.0.1
    • Component/s: mycore-mods
    • Labels:
      None
    • Sprint:

      Description

      If someone tries to import a MODS MyCoRe Object with child objects,
      before the children are created, he might get the following exception:

      The event handler should only proceed, if the child object really exists.

      MyCoRe: org.apache.commons.vfs2.FileNotFoundException: Could not read from "file:///opt/mycore/data/rosdok/metadata/rosdok/document/000000/00/rosdok_document_0000000022.xml" because it is not a file.
      at org.apache.commons.vfs2.provider.AbstractFileObject.getInputStream(AbstractFileObject.java:1309)
      at org.apache.commons.vfs2.provider.DefaultFileContent.getInputStream(DefaultFileContent.java:411)
      at org.mycore.common.content.MCRVFSContent.getInputStream(MCRVFSContent.java:77)
      at org.mycore.common.content.MCRContent.getInputSource(MCRContent.java:209)
      at org.mycore.common.xml.MCRXMLParserImpl.parseXML(MCRXMLParserImpl.java:82)
      at org.mycore.common.content.MCRContent.asXML(MCRContent.java:286)
      at org.mycore.datamodel.common.MCRXMLMetadataManager.retrieveXML(MCRXMLMetadataManager.java:495)
      at org.mycore.datamodel.metadata.MCRMetadataManager.retrieveMCRObject(MCRMetadataManager.java:665)
      at org.mycore.datamodel.metadata.MCRMetadataManager.retrieve(MCRMetadataManager.java:699)
      at org.mycore.mods.MCRMODSLinksEventHandler.handleObjectUpdated(MCRMODSLinksEventHandler.java:94)
      at org.mycore.common.events.MCREventHandlerBase.doHandleEvent(MCREventHandlerBase.java:63)

        Attachments

          Issue links

            Activity

              People

              • Assignee:
                mcrsteph Robert Stephan
                Reporter:
                mcrsteph Robert Stephan
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: