From 96c8a4c57cd05f8d25ff6452fa2d9659f7357c22 Mon Sep 17 00:00:00 2001 From: Simeon Warner Date: Thu, 19 Sep 2024 09:18:21 +0200 Subject: [PATCH] Initial extension (#80) * Initial extension * Updates from editors' review * Editors suggestion --- docs/index.md | 1 + docs/initial.md | 45 +++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 46 insertions(+) create mode 100644 docs/initial.md diff --git a/docs/index.md b/docs/index.md index 8a533ad..6eac2ca 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,5 +1,6 @@ # OCFL Community Extensions + * [Initial Extension](initial.md) * [0001: Digest Algorithms](0001-digest-algorithms.md) * [0002: Flat Direct Storage Layout](0002-flat-direct-storage-layout.md) * [0003: Hashed Truncated N-tuple Trees with Encapsulating Directory for OCFL Storage Hierarchies](0003-hash-and-id-n-tuple-storage-layout.md) diff --git a/docs/initial.md b/docs/initial.md new file mode 100644 index 0000000..376543e --- /dev/null +++ b/docs/initial.md @@ -0,0 +1,45 @@ +# OCFL Community Extension `initial`: Initial Extension + + * **Extension Name:** `initial` + * **Authors:** OCFL Editors + * **Minimum OCFL Version:** 1.0 + * **OCFL Community Extensions Version:** 1.0 + * **Obsoletes:** n/a + * **Obsoleted by:** n/a + +## Overview + +This extension allows indication that the semantics of a particular extension takes precedence over all other extensions. It ensures that the special extension name `initial` is a registered extension name and thus that an extension directory `initial` is also valid in both objects and storage roots. + +An extension directory MAY contain an `initial` extension identified by the extension directory name `initial`. If it exists, the `initial` extension specifies another extension that MUST be applied before all other extensions in the directory. + +The extension configuration file indicates the functional extension to be applied first by specifying that extension's name in the `extension` parameter (not `initial`). This extension can be used to address otherwise undefined behaviors, such as: + + * Should extensions be applied in a specific order? + * Is an extension deactivated, only applying to earlier versions of the object? + * Does one extension depend on another? + +## Parameter + + * **Name:** `extension` + * **Description:** The name of the extension to be applied first + * **Type:** string + * **Constraints:** Must be a valid extension name + * **Default:** Not applicable + +## Example + +The following `config.json` configuration file indicates that the extension named `NNNN-functional-extension-name` should be applied first. + +``` +{ + "extensionName": "initial", + "extension": "NNNN-functional-extension-name" +} +``` + +## Revision History + +| Date | Description | +| ---- | ----------- | +| 2024-09-19 | First published |