Current Release

This documentation covers the current version of Fedora. Looking for another version? See all documentation.

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 7 Next »

Fedora stores all of the repository content in OCFL objects.

This content consists of three types of files:

  1. The user-content files (such as PDF, TIFF, TXT, MP4, etc.)
  2. RDF files containing user-properties related to the OCFL object and/or user's content files
  3. Fedora-specific JSON "header" files containing system-properties related to the OCFL object and/or user's content files

For each user-content and RDF user-properties file, Fedora needs to retain system metadata to have a full interpretation of the file. These "system metadata" files are call Fedora Header Files.

This document describes the format and elements contained within Fedora Header Files. The location and naming conventions for these header files is described in the Design - Fedora OCFL Object Structure wiki page.

General

All header files are serialized as JSON documents according to the following JSON Schema:

{
  "$schema": "http://json-schema.org/draft/2019-09/schema#",
  "$id": "https://fedora.info/schemas/2020/06/06/headers.json",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uri"
    },
    "parent": {
      "type": "string",
      "format": "uri"
    },
    "stateToken": {
      "type": "string"
    },
    "interactionModel": {
      "type": "string",
      "format": "uri",
      "enum": [
        "http://www.w3.org/ns/ldp#NonRDFSource",
        "http://www.w3.org/ns/ldp#RDFSource",
        "http://www.w3.org/ns/ldp#RDFSource",
        "http://www.w3.org/ns/ldp#Container",
        "http://www.w3.org/ns/ldp#BasicContainer",
        "http://www.w3.org/ns/ldp#DirectContainer",
        "http://www.w3.org/ns/ldp#IndirectContainer",
        "http://fedora.info/definitions/v4/repository#ArchivalGroup",
        "http://fedora.info/definitions/v4/repository#NonRdfSourceDescription",
        "http://fedora.info/definitions/v4/webac#Acl"
      ]
    },
    "createdDate": {
      "type": "string",
      "format": "date-time"
    },
    "createdBy": {
      "type": "string"
    },
    "lastModifiedDate": {
      "type": "string",
      "format": "date-time"
    },
    "lastModifiedBy": {
      "type": "string"
    },
    "archivalGroup": {
      "type": "boolean"
    },
    "objectRoot": {
      "type": "boolean"
    },
    "deleted": {
      "type": "boolean"
    }
  },
  "required": [
    "id",
    "parent",
    "stateToken",
    "interactionModel",
    "createdDate",
    "lastModifiedDate",
    "archivalGroup",
    "objectRoot",
    "deleted"
  ],
  "$comment": "NonRDFSource resources have additional properties",
  "if": {
    "properties": {
      "interactionModel": {
        "const": "http://www.w3.org/ns/ldp#NonRDFSource"
      }
    }
  },
  "then": {
    "properties": {
      "mimeType": {
        "type": "string"
      },
      "filename": {
        "type": "string"
      },
      "contentSize": {
        "type": "integer"
      },
      "digests": {
        "type": "array",
        "items": {
          "type": "string",
          "format": "uri"
        }
      },
      "externalUrl": {
        "type": "string",
        "format": "uri"
      },
      "externalHandling": {
        "type": "string",
        "enum": [
          "proxy",
          "copy",
          "redirect"
        ]
      }
    },
    "required": [
      "mimeType",
      "filename",
      "contentSize",
      "digests"
    ]
  }
}

Property Descriptions

id

The Fedora resource's ID will typically be of the form: <prefix>/url/path/elements/to/resource, where "prefix" is "info:fedora".

parent

The Fedora ID of the container resource in which this resource was created. If this resource is at the top of the repository, then the "parent" will be the repository root, "info:fedora".

stateToken

interactionModel

createdDate

createdBy

lastModifiedDate

lastModifiedBy

archivalGroup

objectRoot

deleted

mimeType

filename

contentSize

digests

externalurl

externalHandling

Examples

For reference, below are examples of header files associate with: user-content and RDF user-properties

Header File Example - User-Content

Header files associated with user-content files

{
  "parent": "info:fedora",
  "id": "info:fedora/binary",
  "filename": "",
  "mimeType": "application/x-www-form-urlencoded",
  "interactionModel": "http://www.w3.org/ns/ldp#NonRDFSource",
  "lastModifiedDate": "2020-06-03T23:59:00.284677Z",
  "createdDate": "2020-06-03T23:59:00.284677Z",
  "stateToken": "5F789A9AAD061811FBB9BB0DE4B998C8",
  "contentSize": 9,
  "digests": [],
  "deleted": false,
  "archivalGroup": false,
  "objectRoot": true
}

Header File Example - RDF User-Properties

Header files associated with RDF user-properties files

  1. Containers
    1. {
        "parent": "info:fedora",
        "id": "info:fedora/container",
        "interactionModel": "http://www.w3.org/ns/ldp#BasicContainer",
        "lastModifiedDate": "2020-06-03T23:58:03.148409Z",
        "createdDate": "2020-06-03T23:58:03.148409Z",
        "stateToken": "DCEF22546A9D93D0203E96D1682DF9F8",
        "deleted": false,
        "archivalGroup": false,
        "objectRoot": true
      }
  2. Binary descriptions
    1. {
        "parent": "info:fedora/binary",
        "id": "info:fedora/binary/fcr:metadata",
        "interactionModel": "http://fedora.info/definitions/v4/repository#NonRdfSourceDescription",
        "lastModifiedDate": "2020-06-03T23:59:00.280677Z",
        "createdDate": "2020-06-03T23:59:00.280677Z",
        "stateToken": "74A51841F559D31E3EBD40EFE2DE29E3",
        "deleted": false,
        "archivalGroup": false,
        "objectRoot": false
      }
  3. ACLs
    1. {
        "parent": "info:fedora/new",
        "id": "info:fedora/new/fcr:acl",
        "lastModifiedDate": "2020-06-05T01:15:29.406689Z",
        "deleted": false,
        "interactionModel": "http://fedora.info/definitions/v4/webac#Acl",
        "createdBy": "fedoraAdmin",
        "createdDate": "2020-06-05T01:15:29.406689Z",
        "lastModifiedBy": "fedoraAdmin",
        "stateToken": "FF048B326D1DED62BDCB84D38DC7CB41",
        "archivalGroup": false,
        "objectRoot": false
      }



  • No labels