geth/docs/adr/0011-kv-iroh-documents.md

24 lines
927 B
Markdown

# ADR 0011: KV With Iroh Documents
## Status
Accepted.
## Decision
KV resources will use Iroh Documents namespaces for small replicated state,
configuration, metadata, preferences, and script state. Authorization can include
prefix-scoped capabilities.
## Consequences
The prototype keeps SQLite as the durable local KV index and mirrors each named
KV store into an Iroh Documents namespace on the daemon-owned `iroh 1.0.0`
endpoint. Remote `geth kv sync` still uses geth control as the authorization
preflight. If the caller has `kv.read` on the remote `resource:kv:<name>`, the
remote daemon returns a read-only Iroh Documents ticket and the requester imports
entries through `iroh-docs 0.101.0`.
The daemon must not hand out Iroh Documents write capabilities as a substitute
for geth authorization. Write authority remains modeled through geth resource
capabilities such as `kv.write` and `kv.write_prefix:<prefix>`.