Skip to content
This repository has been archived by the owner on Jun 29, 2022. It is now read-only.

feat: require deterministic map serialization #235

Closed
wants to merge 3 commits into from
Closed
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions data-model-layer/data-model.md
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,8 @@ Map is a recursive kind.
Values in maps are accessed by their "key". Maps can also be iterated over,
yielding key+value pairs.

Maps must be serialized in a deterministic way (key sorting should be consistent regardless of insertion order or language specific sorting). The sorting is not defined by the data model, each codec should find the best sorting algorithm, but the sorting must be consitent between languages and is most often implemented as additional code during serialization since most formats do not already have deterministic maps.
mikeal marked this conversation as resolved.
Show resolved Hide resolved

#### Link kind

A link represents a link to another IPLD Block. The link reference
Expand Down