Skip to content

Commit 2e40098

Browse files
authored
Add the notion of a key suffix to metadata documents (#98)
Closes #63 The rational is that backends may be explored by non zarr-aware tools, like a filesytem and a GUI browser like Finder/Explorer/Nautilus, and the `.json` extension will help to view/edit json in those. While it may seem like this shoudl be store specific, once again the fact that a zarr-hierarchy can be copied from one storage to another by non-zarr-aware tool indicate that this shoudl be handled above the sotre level.
1 parent 40f4944 commit 2e40098

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

docs/protocol/core/v3.0.rst

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -736,6 +736,16 @@ containing the following names:
736736
For document using the default JSON encoding and format describe in this document
737737
then the value must be ``"https://purl.org/zarr/spec/protocol/core/3.0``.
738738

739+
``metadata_key_suffix``
740+
741+
A string containing a suffix to add to the metadata keys when saving into
742+
the store. By default ``".json"``.
743+
744+
.. note::
745+
746+
This suffix is used is used to allow non hierarchy
747+
browsing and edditign by non-zarr-aware tools.
748+
739749
``extensions``
740750

741751
An array containing zero or more objects, each of which identifies
@@ -762,6 +772,7 @@ JSON is being used for encoding of group and array metadata::
762772
{
763773
"zarr_format": "https://purl.org/zarr/spec/protocol/core/3.0",
764774
"metadata_encoding": "https://purl.org/zarr/spec/protocol/core/3.0",
775+
"metadata_key_suffix" : ".json",
765776
"extensions": []
766777
}
767778

@@ -772,6 +783,7 @@ ignored if not understood::
772783
{
773784
"zarr_format": "https://purl.org/zarr/spec/protocol/core/3.0",
774785
"metadata_encoding": "https://purl.org/zarr/spec/protocol/core/3.0",
786+
"metadata_key_suffix" : ".json",
775787
"extensions": [
776788
{
777789
"extension": "http://example.org/zarr/extension/foo",

0 commit comments

Comments
 (0)