Skip to content

Record that Metadata tracks its own changes in setono/client - #28

Merged
loevgaard merged 1 commit into
2.xfrom
docs/metadata-change-tracking-adr
Nov 23, 2026
Merged

loevgaard merged 1 commit into
2.xfrom
docs/metadata-change-tracking-adr

Conversation

@loevgaard

Copy link
Copy Markdown
Member

This was generated by AI during triage.

Summary

Records the decision from triaging #24: setono/client's Metadata tracks its own changes (hasChanged(), Setono/client#5). The alternatives were the bundle's subclass and a snapshot comparison in a store (#23).

 GLOSSARY.md
   **Metadata**
+  **Changed metadata**   # values or expiry times differ from what was loaded; only changed metadata is stored
 docs/adr/
   0001-the-current-client-is-the-source-of-truth-for-the-client-id.md
+  0002-metadata-tracks-its-own-changes-in-setono-client.md

Evidence

Docs only. The ADR rests on this check against ChangeAwareMetadata and setono/client 1.1.2:

  • Before: the subclass is marked changed when the library drops an expired key in has(), count(), iteration or toArray(), but only because those paths call the overridable remove().
  • After a hypothetical library refactor that drops expired keys with a direct unset(): a key is gone, isDirty() stays false, and the persister skips the write.

Merge Danger

Door: two-way

Blast Radius: none

Documentation only. The code changes follow in Setono/client#5 and #24.

Adds ADR-0002 and the glossary term "changed metadata", decided while
triaging #24.
@loevgaard
loevgaard merged commit cc97e9a into 2.x Nov 23, 2026
19 checks passed
@loevgaard
loevgaard deleted the docs/metadata-change-tracking-adr branch November 23, 2026 10:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant