gocfl / ocfl / extensions
In this chapter, we look at the extensions defined directly at the OCFL object level in the extensions/ directory. These control how content is stored within the object and which additional metadata or functions (such as indexing or thumbnails) are active for this specific object.
The example object test42 uses the following extensions:
info.json with object metadata.Here are the specific configurations of the most important extensions:
This extension defines in which subdirectories the different data types are stored within the object.
data/).metadata/).documentation/).{
"extensionName": "NNNN-content-subpath",
"subPath": {
"content": {
"path": "data",
"description": "Payload of archival object"
},
"documentation": {
"path": "documentation",
"description": "documentation of the archival object"
},
"metadata": {
"path": "metadata",
"description": "additional semantic metadata"
}
}
}
Responsible for mapping logical file paths to physical paths in storage. It cleans up special characters and ensures compatibility with various file systems.
:, *, ? etc.) in filenames (here: _)." ").sha512).0).{
"extensionName": "0011-direct-clean-path-layout",
"maxPathnameLen": 32000,
"maxPathSegmentLen": 127,
"replacementString": "_",
"whitespaceReplacementString": " ",
"utfEncode": true,
"fallbackDigestAlgorithm": "sha512",
"fallbackFolder": "fallback",
"numberOfFallbackTuples": 0,
"fallbackTupleSize": 0
}
This extension runs various tools during the ingest process to extract technical metadata.
metadata area (see content-subpath).gzip to save space.{
"extensionName": "NNNN-indexer",
"StorageType": "area",
"StorageName": "metadata",
"Actions": [
"siegfried",
"xml",
"tika",
"ffprobe",
"identify"
],
"Compress": "gzip"
}
Creates an info.json in the metadata area, which summarizes the basic OCFL information.
info.json).{
"extensionName": "NNNN-metafile",
"storageType": "area",
"storageName": "metadata",
"name": "info.json",
"schema": "gocfl-info-1.0.json",
"schemaUrl": "https://raw.githubusercontent.com/ocfl-archive/gocfl/main/gocfl-info-1.0.json"
}
The manager controls the execution order (hooks). This is important because, for example, the layout (0011) must be applied before the path is further subdivided by content-subpath.
0011), then sorted into areas (content-subpath).direct-clean-path-layout and direct-path-layout may not be used simultaneously.{
"extensionName": "NNNN-gocfl-extension-manager",
"sort": {
"ObjectChange": [
"NNNN-indexer",
"NNNN-metafile"
],
"ObjectContentPath": [
"NNNN-direct-clean-path-layout",
"NNNN-content-subpath"
]
},
"exclusion": {
"ObjectContentPath": [
[
"NNNN-direct-clean-path-layout",
"NNNN-direct-path-layout"
]
]
}
}
| Back to Overview: Extensions | Back to Table of Contents |