Versions Compared

Key

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

...

  • Upon Resource Creation: if a Link: rel="type" header of type http://fedora.info/definitions/fcrepo#VersionedResource is provided when creating a resource, it will be created with versioning turned on. 
    • A LDPR will be created with the versioning interaction model (therefore it will be an LDPRv)
    • A LDPCv will be created, from which a TimeMap can be generated.
    • A LDPRm will be generated, contained by the LDPCv.
    • Any subsequent responses from the LDPRv will include the appropriate memento links in the header: timegate, timemap
  • On Existing Resource: if a PUT request is made against an existing resource with a link header ( Link: rel="type") specifying type of http://fedora.info/definitions/fcrepo#VersionedResource included the resource will become versionable. 
    • The versioning interaction model will be added to the LDPR, making it a LDPRv.
    • A LDCPv will be created, from which a TimeMap can be generated.
    • A LDPRm will be generated, contained by the LDPCv.
    • Any subsequent responses from the LDPRv will include the appropriate memento links in the header: timegate, timemap

...

Internal Representation of resources

LDPCv - Memento Container (

...

TimeMap)


Code Block
titleTimeMap (LDPCv)
@prefix acl:  <http://www.w3.org/ns/auth/acl#> .
@prefix iana:  <http://www.iana.org/assignments/relation/> .
@prefix ldp:  <http://www.w3.org/ns/ldp#> .
@prefix memento:  <http://example.com/memento#> .
@prefix rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix time: <http://www.w3.org/2006/time#> .

</path/to/resource/xyz/timemap>fcr:versions> a memento:TimeMap, ldp:Container ;
   acl:hasAccessControl </path/to/acls> ;    # this is for the LDPCv itself, for the TimeMap retrieval
   prov:startedAtTime "2017-09-08T21:35:19Z"^^xsd:dateTime ;  # first memento:hasOriginalResource 
   prov:endedAtTime   "2017-09-11T15:41:04Z"^^xsd:dateTime ;  # last memento


   memento:hasAccessControl </path/to/orig/resource/xyz>acls> ;
   memento:hasTimeGatehasOriginalResource  </path/to/orig/resource/xyz> ;  # how else can we represent this? is this a given based on url? 
   memento:hasAccessControlhasTimeGate </path/to/acls> ;orig/resource/xyz> ;           # how else can we represent this? is this a given based on url?
  
   iana:first </path/to/resource/xyz/timemapfcr:versions/12344> ;
   iana:last </path/to/resource/xyz/timemapfcr:versions/12347> ;
   ldp:contains </path/to/resource/xyz/timemapfcr:versions/12344>, </path/to/resource/xyz/timemapfcr:versions/12345>, 
      </path/to/resource/xyz/timemapfcr:versions/12347>, </path/to/resource/xyz/timemapfcr:versions/12346> .


The use of IANA may or may not work here - esp if the original object's snapshot is in this LDPRm directly - we need to make sure that triples don't overlap. If we stick with all memento triples, then we can strip them out and have the version of the resource the user is after.  

...

Code Block
titleMemento (LDPRm)
@prefix acl:  <http://www.w3.org/ns/auth/acl#> .
@prefix iana:  <http://www.iana.org/assignments/relation/> .
@prefix ldp:  <http://www.w3.org/ns/ldp#> .
@prefix memento:  <http://example.com/memento#> .
@prefix rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix time: <http://www.w3.org/2006/time#> .

</path/to/resource/xyz/timemapfcr:versions/12345> a mementoldp:MementoRDFSource , ldpprov:RDFSource InstantaneousEvent;
    mementoprov:datetimeatTime "20010320133610" 2012-04-30T20:40:40"^^xsd:dateTime;
    memento:hasTimegate </path/to/orig/resource/xyz> ;    # how else can we represent this? is this this a #originalgiven resourcebased ==on timegateurl?
    memento:hasOriginalResource </path/to/orig/resource/xyz> ;   # timegate and orig resource could come from LDPCv insteadhow else can we represent this? Is this a given based on url? 
    iana:next </path/to/xyz/timemapfcr:versions/datetimestamp12346>12346> ;   # to memento
    iana:prev </path/to/xyz/timemapfcr:versions/datetimestamp12344>12344> ;   # to memento
    
   ... triples from original resource at the time of the versioning are here as well. 

 versioning... 
 
 or, if we keep them separate, it might look like this:
(I'm not clear on how a binary and it's metadata would be represented)
    ldp:contains </path/to/xyz/fcr:versions/12345/version> ,
        </path/to/xyz/fcr:versions/12345/version/fcr:metadata> ;   
    

Open Design Questions

  • Do we need a separate memento ontology or can we use PROV-O for most things? 
  • For information about TimeMap and TimeGate can these resources not list them explicity and just use some known url formatting for this?  We may not need the pointers to the TimeGate  / TimeMap inside the resources.
    • Timegate is LDPRv URL
    • TimeMap is LDPRv URL + "/fcr:versions"  
    • The code that retrieves the memento can construct the "original", "timemap" and "timegate" link headers from it's own URL – is that okay to do? 

Use Cases

Versioning/Authorization Use-Cases

...