Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Scenario 1: Read Non-Fedora-generated OCFL containing RDF. 

Fedora is smart about extracting LDP structure

Starting with an OCFL like this:

...

Scenario 1.A.1:  myobject1.ttl contains relative subjects 

Code Block
@prefix dcterms: <http://purl.org/dc/terms/>.
</myroot/myobject1> <predicate> <object> dcterms:title "my object 1" .


Code Block
curl -X GET http://localhost:8080/root/myobject
curl -i http://localhost:8080/rest/myroot/myobject1
HTTP/1.1 200 OK
Date: Thu, 07 Mar 2019 23:46:18 GMT
ETag: W/"243866ce79cb4bdea2baf53f764c107a04312bf1"
Last-Modified: Thu, 07 Mar 2019 23:44:00 GMT
Link: <http://www.w3.org/ns/ldp#Resource>;rel="type"
Link: <http://www.w3.org/ns/ldp#Container>;rel="type"
Link: <http://www.w3.org/ns/ldp#RDFSource>; rel="type"
Link: <http://www.w3.org/ns/ldp#BasicContainer>;rel="type"
Link: <http://localhost:8080/rest/myroot/myobject1>; rel="timegate"
Link: <http://localhost:8080/rest/myroot/myobject1>; rel="original"
Link: <http://localhost:8080/rest/myroot/myobject1/fcr:versions>; rel="timemap"
Link: <http://mementoweb.org/ns#OriginalResource>; rel="type"
Link: <http://mementoweb.org/ns#TimeGate>; rel="type"
Accept-External-Content-Handling: copy,redirect,proxy
Accept-Patch: application/sparql-update
Accept-Post: text/turtle,text/rdf+n3,text/n3,application/rdf+xml,application/n-triples,application/ld+json
Allow: MOVE,COPY,DELETE,POST,HEAD,GET,PUT,PATCH,OPTIONS
Link: <http://localhost:8080/rest/myroot/myobject1/fcr:acl>; rel="acl"
Preference-Applied: return=representation
Vary: Prefer
Vary: Accept
Vary: Range
Vary: Accept-Encoding
Vary: Accept-Language
Vary: Accept-Datetime
Content-Type: text/turtle;charset=utf-8
Content-Length: 860
Server: Jetty(9.3.25.v20180904)

@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix fedora: <http://fedora.info/definitions/v4/repository#> .
@prefix ldp: <http://www.w3.org/ns/ldp#> .
@prefix dcterms: <http://purl.org/dc/terms/> .

<http://localhost:8080/rest/myroot/myobject1>
rdf:type fedora:Container ;
rdf:type fedora:Resource ;
rdf:type ldp:BasicContainer ;
fedora:lastModifiedBy "bypassAdmin" ;
fedora:createdBy "bypassAdmin" ;
fedora:created "2019-03-07T23:43:44.13Z"^^<http://www.w3.org/2001/XMLSchema#dateTime> ;
fedora:lastModified "2019-03-07T23:44:00.991Z"^^<http://www.w3.org/2001/XMLSchema#dateTime> ;
dcterms:title "my object title1" ;
rdf:type ldp:RDFSource ;
rdf:type ldp:Container .

...

  1. Where do the server managed triples come from if they are not specified in the RDF? Ie on import are they added to .fcrepo/server-managed.ttl and automatically versioned?  

Scenario 1.A.2:  myobject1.ttl contains relative subjects 

...

  1.    
    One possibility:  when fedora starts up on an previously unread OCFL,  it performs an indexing task.  If the OCFL lacks .fcrepo directories, then Fedora will add any necessary server managed triples to the .fcrepo and automatically create a new version with the fedora updates.
  2. Do we 
    1. need to maintain the current Fedora 5x behavior of returning the URL in the subject? ie subject = <http://localhost:8080/rest/

...

    1. myroot/

...

    1. myobject1>
    2. return  the non-server managed subjects exactly as we found them?   ie subject = </myroot/myobject1>
    3. return  the non-server managed subjects modified to include the context path (  resource relative to the host) e.g. subject = <

...

    1. /rest/myroot/myobject1>

...

Scenario 1b:  myobject1.ttl contains external URL subjects

Code Block
@prefix dcterms: <http://purl.org/dc/terms/>.
<http://non-fedora-host:port/context/myobject>myobject1> dcterms:title "my object 1".
                    

curl -X GET http://localhost:8080/root/myobject

Code Block
curl -X GET http://localhost:8080/root/myobject
curl -i http://localhost:8080/rest/myroot/myobject1
HTTP/1.1 200 OK
Date: Thu, 07 Mar 2019 23:46:18 GMT
ETag: W/"243866ce79cb4bdea2baf53f764c107a04312bf1"
Last-Modified: Thu, 07 Mar 2019 23:44:00 GMT
Link: <http://www.w3.org/ns/ldp#Resource>;rel="type"
Link: <http://www.w3.org/ns/ldp#Container>;rel="type"
Link: <http://www.w3.org/ns/ldp#RDFSource>; rel="type"
Link: <http://www.w3.org/ns/ldp#BasicContainer>;rel="type"
Link: <http://localhost:8080/rest/myroot/myobject1>; rel="timegate"
Link: <http://localhost:8080/rest/myroot/myobject1>; rel="original"
Link: <http://localhost:8080/rest/myroot/myobject1/fcr:versions>; rel="timemap"
Link: <http://mementoweb.org/ns#OriginalResource>; rel="type"
Link: <http://mementoweb.org/ns#TimeGate>; rel="type"
Accept-External-Content-Handling: copy,redirect,proxy
Accept-Patch: application/sparql-update
Accept-Post: text/turtle,text/rdf+n3,text/n3,application/rdf+xml,application/n-triples,application/ld+json
Allow: MOVE,COPY,DELETE,POST,HEAD,GET,PUT,PATCH,OPTIONS
Link: <http://localhost:8080/rest/myroot/myobject1/fcr:acl>; rel="acl"
Preference-Applied: return=representation
Vary: Prefer
Vary: Accept
Vary: Range
Vary: Accept-Encoding
Vary: Accept-Language
Vary: Accept-Datetime
Content-Type: text/turtle;charset=utf-8
Content-Length: 860
Server: Jetty(9.3.25.v20180904)

@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix fedora: <http://fedora.info/definitions/v4/repository#> .
@prefix ldp: <http://www.w3.org/ns/ldp#> .
@prefix dcterms: <http://purl.org/dc/terms/> .

<http://non-fedora-host:port/context/myobject> myobject1>
dcterms:title "my object 1" ;

<http://localhost:8080/rest/myroot/myobject1>
rdf:type fedora:Container ;
rdf:type fedora:Resource ;
rdf:type ldp:BasicContainer ;
fedora:lastModifiedBy "bypassAdmin" ;
fedora:createdBy "bypassAdmin" ;
fedora:created "2019-03-07T23:43:44.13Z"^^<http://www.w3.org/2001/XMLSchema#dateTime> ;
fedora:lastModified "2019-03-07T23:44:00.991Z"^^<http://www.w3.org/2001/XMLSchema#dateTime> ;
rdf:type ldp:RDFSource ;
rdf:type ldp:Container .

Questions/Notes:

  1. Subject of the original RDF is maintained as is.
  2. Server managed triples use the Fedora resource URL


Scenario 1c:  myobject1.ttl contains LDP type and containment info 

...

Scenario 2:  Update resources originally imported from non-Fedora OCFL

To be fleshed out.