Hi Ying, Looking at the code it looks like you need to specify the full URL if you use the LOCTYPE = URL in the FLocat for your METS:file but if you use any other value for LOCTYPE it will try and upload a local file to Fedora then ingest the object with a reference to the uploaded file. Its been a while since I looked at this so let me know if that works.
Thanks Glen On 29 Mar 2012, at 22:58, Ying Jin wrote: > Hi Glen, > > Thanks for pointing out this possibility. Robin and Mark, thank you for the > continue support. > > I tried an AIP mets and get following error messages in my log - > > ERROR 2012-03-29 16:33:11.068 [http-8080-3] (FedoraAPIMBindingSOAPHTTPImpl) > Error ingesting > org.fcrepo.server.errors.ObjectIntegrityException: FOXML IO stream was bad : > Malformed URL: bitstream_613090.jpeg > at > org.fcrepo.server.storage.translation.FOXMLDODeserializer.deserialize(FOXMLDODeserializer.java:258) > [fcrepo-server-3.4.2.jar:na] > at > org.fcrepo.server.storage.translation.DOTranslatorImpl.deserialize(DOTranslatorImpl.java:75) > [fcrepo-server-3.4.2.jar:na] > at > org.fcrepo.server.storage.translation.DOTranslatorModule.deserialize(DOTranslatorModule.java:126) > [fcrepo-server-3.4.2.jar:na] > at > org.fcrepo.server.storage.DefaultDOManager.getIngestWriter(DefaultDOManager.java:802) > [fcrepo-server-3.4.2.jar:na] > at > org.fcrepo.server.management.DefaultManagement.ingest(DefaultManagement.java:160) > [fcrepo-server-3.4.2.jar:na] > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > [na:1.6.0_23] > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > [na:1.6.0_23] > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > [na:1.6.0_23] > at java.lang.reflect.Method.invoke(Method.java:616) [na:1.6.0_23] > at > org.fcrepo.server.messaging.NotificationInvocationHandler.invoke(NotificationInvocationHandler.java:68) > [fcrepo-server-3.4.2.jar:na] > at $Proxy4.ingest(Unknown Source) [na:na] > at > org.fcrepo.server.management.ManagementModule.ingest(ManagementModule.java:354) > [fcrepo-server-3.4.2.jar:na] > at > org.fcrepo.server.management.FedoraAPIMBindingSOAPHTTPImpl.ingest(FedoraAPIMBindingSOAPHTTPImpl.java:83) > [fcrepo-server-3.4.2.jar:na] > at > org.fcrepo.server.management.FedoraAPIMBindingSOAPHTTPSkeleton.ingest(FedoraAPIMBindingSOAPHTTPSkeleton.java:355) > [fcrepo-common-3.4.2.jar:na] > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > [na:1.6.0_23] > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > [na:1.6.0_23] > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > [na:1.6.0_23] > at java.lang.reflect.Method.invoke(Method.java:616) [na:1.6.0_23] > at > org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:397) > [axis-1.3-PATCHED.jar:na] > at > org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:186) > [axis-1.3-PATCHED.jar:na] > at > org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323) > [axis-1.3-PATCHED.jar:na] > at > org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32) > [axis-1.3-PATCHED.jar:na] > at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118) > [axis-1.3-PATCHED.jar:na] > at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83) > [axis-1.3-PATCHED.jar:na] > at > org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453) > [axis-1.3-PATCHED.jar:na] > at org.apache.axis.server.AxisServer.invoke(AxisServer.java:281) > [axis-1.3-PATCHED.jar:na] > at > org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699) > [axis-1.3-PATCHED.jar:na] > at javax.servlet.http.HttpServlet.service(HttpServlet.java:637) > [servlet-api.jar:na] > at > org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327) > [axis-1.3-PATCHED.jar:na] > at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) > [servlet-api.jar:na] > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) > [catalina.jar:na] > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > [catalina.jar:na] > at > org.fcrepo.server.security.servletfilters.FilterSetup.doFilter(FilterSetup.java:235) > [fcrepo-server-3.4.2.jar:na] > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) > [catalina.jar:na] > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > [catalina.jar:na] > at > org.fcrepo.server.security.servletfilters.FilterSetup.doFilter(FilterSetup.java:235) > [fcrepo-server-3.4.2.jar:na] > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) > [catalina.jar:na] > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > [catalina.jar:na] > at > org.fcrepo.server.security.servletfilters.FilterSetup.doFilter(FilterSetup.java:235) > [fcrepo-server-3.4.2.jar:na] > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) > [catalina.jar:na] > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > [catalina.jar:na] > at > org.fcrepo.server.security.servletfilters.FilterSetup.doFilter(FilterSetup.java:235) > [fcrepo-server-3.4.2.jar:na] > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) > [catalina.jar:na] > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > [catalina.jar:na] > at > org.fcrepo.server.security.servletfilters.FilterSetup.doFilter(FilterSetup.java:235) > [fcrepo-server-3.4.2.jar:na] > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) > [catalina.jar:na] > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > [catalina.jar:na] > at > org.fcrepo.server.security.servletfilters.FilterSetup.doFilter(FilterSetup.java:235) > [fcrepo-server-3.4.2.jar:na] > at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) > [catalina.jar:na] > at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) > [catalina.jar:na] > at > org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) > [catalina.jar:na] > at > org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) > [catalina.jar:na] > at > org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:525) > [catalina.jar:na] > at > org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) > [catalina.jar:na] > at > org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) > [catalina.jar:na] > at > org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) > [catalina.jar:na] > at > org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293) > [catalina.jar:na] > at > org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:849) > [tomcat-coyote.jar:na] > at > org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583) > [tomcat-coyote.jar:na] > at > org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:454) > [tomcat-coyote.jar:na] > at java.lang.Thread.run(Thread.java:679) [na:1.6.0_23] > Caused by: org.xml.sax.SAXException: Malformed URL: bitstream_613090.jpeg > at > org.fcrepo.server.storage.translation.FOXMLDODeserializer.startElement(FOXMLDODeserializer.java:453) > [fcrepo-server-3.4.2.jar:na] > at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown > Source) [xercesImpl-2.9.1.jar:na] > at > org.apache.xerces.parsers.AbstractXMLDocumentParser.emptyElement(Unknown > Source) [xercesImpl-2.9.1.jar:na] > at > org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown > Source) [xercesImpl-2.9.1.jar:na] > at > org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown > Source) [xercesImpl-2.9.1.jar:na] > at > org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown > Source) [xercesImpl-2.9.1.jar:na] > at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) > [xercesImpl-2.9.1.jar:na] > at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) > [xercesImpl-2.9.1.jar:na] > at org.apache.xerces.parsers.XMLParser.parse(Unknown Source) > [xercesImpl-2.9.1.jar:na] > at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source) > [xercesImpl-2.9.1.jar:na] > at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown > Source) [xercesImpl-2.9.1.jar:na] > at org.apache.xerces.jaxp.SAXParserImpl.parse(Unknown Source) > [xercesImpl-2.9.1.jar:na] > at javax.xml.parsers.SAXParser.parse(SAXParser.java:195) [na:1.6.0_23] > at > org.fcrepo.server.storage.translation.FOXMLDODeserializer.deserialize(FOXMLDODeserializer.java:253) > [fcrepo-server-3.4.2.jar:na] > ... 60 common frames omitted > > I suspect that fedora SWORD is expecting a URL link to the file instead of a > local file name. However, if that's the case, should be a easy fix in the > code. > > Thanks, > Ying > On Mar 29, 2012, at 11:22 AM, Glen Robson wrote: > >> Hi Robin and Ying, >> >> I've just looked through the sword-fedora implementation (for SWORD version >> 1.2) and it looks like if you submit the mime-type as text/xml and the >> packaging as 'http://www.loc.gov/METS/' it will extract any METS dmdSecs and >> store them as Fedora datastreams then go through the file section and add >> those as datastreams to an object in Fedora. I'm not sure how that would >> look in Islandora but if you have a METS document containing MODS and links >> to files you should get them pulled into a Fedora object. >> >> When I developed the METS handler for Fedora SWORD it was meant to handle a >> generic METS documents rather than any specific profile but I'm afraid I >> don't know much about the METSDSpaceSIP so I'm not quite sure whats missing. >> >> Hope that helps. >> >> Glen >> >> On 29 Mar 2012, at 15:56, Robin Taylor wrote: >>> Hi Ying, >>> >>> So the fact that the ServiceDocument contains... >>> >>> <sword:acceptPackaging >>> q="0.9">http://purl.org/net/sword-types/METSDSpaceSIP</sword:acceptPackaging> >>> >>> ...means that in theory it should be happy with a Mets package with Mods >>> metadata. In practice I'll bet that the Fedora Sword implementation >>> expects SWAP metadata. I don't know if there are any Fedora experts >>> listening in who could confirm ? >>> >>> However, Mark makes a good point that SWORD may not be the best vehicle >>> for a bulk transfer of data. You might be best to find out what tools >>> Fedora has for bulk import and aim to export and transform your DSpace >>> data into the required format. >>> >>> Cheers, Robin. >>> >>> >>> >>> On 28/03/12 15:47, Ying Jin wrote: >>>> Hi Robin, >>>> >>>> Thanks for your reply. Here is the service document. I am running >>>> SWORD-Fedora 1.2 - >>>> >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> ======================================================================== >>>> <?xml version="1.0" encoding="UTF-8"?> >>>> <app:service xmlns:atom="http://www.w3.org/2005/Atom" >>>> xmlns:app="http://www.w3.org/2007/app >>>> " xmlns:sword="http://purl.org/net/sword/" >>>> xmlns:dcterms="http://purl.org/dc/terms/ >>>> "> >>>> <sword:version>1.3</sword:version> >>>> <sword:verbose>true</sword:verbose> >>>> <sword:noOp>true</sword:noOp> >>>> <app:workspace> >>>> <atom:title type="text">Fedora SWORD Workspace</atom:title> >>>> <app:collection href="http://localhost:8080/sword/ >>>> collection:open"> >>>> <atom:title type="text">Open Collection</atom:title> >>>> <app:accept>text/xml</app:accept> >>>> <app:accept>application/zip</app:accept> >>>> <app:accept>application/x-zip-compressed</app:accept> >>>> <app:accept>application/atom+xml</app:accept> >>>> <app:accept>image/gif</app:accept> >>>> <app:accept>image/jpeg</app:accept> >>>> <app:accept>image/jpg</app:accept> >>>> <app:accept>application/pdf</app:accept> >>>> <sword:acceptPackaging >>>> q="0.9">http://purl.org/net/sword-types/METSDSpaceSIP >>>> </sword:acceptPackaging> >>>> <sword:acceptPackaging q="0.9">http://www.loc.gov/METS/</ >>>> sword:acceptPackaging> >>>> <sword:collectionPolicy>This collection accepts any deposit >>>> from anyone</sword:collectionPolicy> >>>> <dcterms:abstract>This is a collection of objects which can >>>> be freely deposited to. This is aviable for the SWORD test project</ >>>> dcterms:abstract> >>>> <sword:mediation>true</sword:mediation> >>>> <sword:treatment>Preservation actions may occur on submited >>>> deposits</sword:treatment> >>>> </app:collection> >>>> <app:collection href="http://localhost:8080/sword/geography-collection >>>> "> >>>> <atom:title type="text">Geography Collection</atom:title> >>>> <app:accept>application/zip</app:accept> >>>> <sword:acceptPackaging >>>> q="0.9">http://purl.org/net/sword-types/METSDSpaceSIP >>>> </sword:acceptPackaging> >>>> <sword:collectionPolicy>This collection accepts any deposit >>>> </sword:collectionPolicy> >>>> <dcterms:abstract>This is a nested collection of geography >>>> objects</dcterms:abstract> >>>> >>>> <sword:service>http://localhost:8080/sword/servicedocument/geography.xml >>>> </sword:service> >>>> <sword:mediation>true</sword:mediation> >>>> <sword:treatment>Preservation actions may occur on submited >>>> deposits</sword:treatment> >>>> </app:collection> >>>> </app:workspace> >>>> </app:service> >>>> >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> = >>>> ======================================================================== >>>> >>>> It shows METSDSpaceSIP as accepting package. However, it doesn't work. >>>> >>>> Best, >>>> Ying >>>> >>>> On Mar 28, 2012, at 4:35 AM, Robin Taylor wrote: >>>> >>>>> Hi Ying, >>>>> >>>>> If you send a request to the Fedora Sword Server for a Sword >>>>> ServiceDocument it should tell you what package formats it supports. >>>>> Would it be possible to do so and post the results here ? >>>>> >>>>> Thanks, Robin. >>>>> >>>>> >>>>> On 27/03/12 21:22, Ying Jin wrote: >>>>>> Hi, >>>>>> >>>>>> I'm working on our DSpace repository and trying to migrate items from >>>>>> DSpace to Fedora (we are going to use Islandora). It looks like SWORD >>>>>> might be a good approach. Here is the question from my testing >>>>>> migration - >>>>>> >>>>>> I exported an item using DSpace packager in METS format, and then use >>>>>> Fedora Sword module to import the item to Fedora. >>>>>> >>>>>> First, I used METSDSpaceSIP packaging, and the ingested item shows a >>>>>> zip file only. >>>>>> Then I tried METS packaging and only content files are uploaded. >>>>>> Obviously, it can't understand dspace mets. >>>>>> >>>>>> I think METSDSpaceSIP packaging is the right way to go but it doesn't >>>>>> seem to work properly. Is there anything I may need to setup for >>>>>> having this work? >>>>>> >>>>>> Thanks any suggestions and helps, >>>>>> Ying >>>>>> >>>>>> ------------------- >>>>>> CDS@Rice University >>>>>> >>>>>> ------------------------------------------------------------------------------ >>>>>> This SF email is sponsosred by: >>>>>> Try Windows Azure free for 90 days Click Here >>>>>> http://p.sf.net/sfu/sfd2d-msazure >>>>>> _______________________________________________ >>>>>> sword-app-tech mailing list >>>>>> sword-app-tech@lists.sourceforge.net >>>>>> https://lists.sourceforge.net/lists/listinfo/sword-app-tech >>>>> >>>>> >>>>> >>>>> -- >>>>> The University of Edinburgh is a charitable body, registered in >>>>> Scotland, with registration number SC005336. >>>>> >>>>> >>>>> ------------------------------------------------------------------------------ >>>>> This SF email is sponsosred by: >>>>> Try Windows Azure free for 90 days Click Here >>>>> http://p.sf.net/sfu/sfd2d-msazure >>>>> _______________________________________________ >>>>> sword-app-tech mailing list >>>>> sword-app-tech@lists.sourceforge.net >>>>> https://lists.sourceforge.net/lists/listinfo/sword-app-tech >>>>> >>> >>> >>> -- >>> The University of Edinburgh is a charitable body, registered in >>> Scotland, with registration number SC005336. >>> >>> >>> ------------------------------------------------------------------------------ >>> This SF email is sponsosred by: >>> Try Windows Azure free for 90 days Click Here >>> http://p.sf.net/sfu/sfd2d-msazure >>> _______________________________________________ >>> sword-app-tech mailing list >>> sword-app-tech@lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/sword-app-tech >> >> >> ------------------------------------------------------------------------------ >> This SF email is sponsosred by: >> Try Windows Azure free for 90 days Click Here >> http://p.sf.net/sfu/sfd2d-msazure >> _______________________________________________ >> sword-app-tech mailing list >> sword-app-tech@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/sword-app-tech >> > ------------------------------------------------------------------------------ This SF email is sponsosred by: Try Windows Azure free for 90 days Click Here http://p.sf.net/sfu/sfd2d-msazure _______________________________________________ sword-app-tech mailing list sword-app-tech@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sword-app-tech