Liking cljdoc? Tell your friends :D

hive-addon.mount.port

DIP seam for the addon mounter — the host registry abstraction.

IMountHost is the port through which the effectful boundary registers, initializes, shuts down, and looks up addon instances. hive-addon ships one in-memory implementation (atom-mount-host) for tests, dry-run, and non-MCP hosts; a real host (an MCP server) supplies its own. resolve-config-default is the identity-ish config resolver — a host may inject a richer one (e.g. hive-di-backed) at the boundary.

register!/shutdown! are no-nuke: a duplicate register! MUST NOT throw and shutdown! MUST NOT delete data.

DIP seam for the addon mounter — the host registry abstraction.

IMountHost is the port through which the effectful boundary registers,
initializes, shuts down, and looks up addon instances. hive-addon ships one
in-memory implementation (atom-mount-host) for tests, dry-run, and non-MCP
hosts; a real host (an MCP server) supplies its own. resolve-config-default
is the identity-ish config resolver — a host may inject a richer one (e.g.
hive-di-backed) at the boundary.

register!/shutdown! are no-nuke: a duplicate register! MUST NOT throw and
shutdown! MUST NOT delete data.
raw docstring

atom-mount-hostclj/s

(atom-mount-host)

Construct an in-memory IMountHost backed by an atom map id->addon. init! calls hive-addon.protocol/initialize!; shutdown! calls hive-addon.protocol/shutdown!.

Construct an in-memory IMountHost backed by an atom map id->addon.
init! calls hive-addon.protocol/initialize!; shutdown! calls
hive-addon.protocol/shutdown!.
sourceraw docstring

IMountHostclj/sprotocol

Abstraction over an addon host registry. The mounter depends on this port, never a concrete registry.

Abstraction over an addon host registry. The mounter depends on this port,
never a concrete registry.

init!clj/s

(init! host addon-id config)

Initialize the registered addon with config. Returns the InitResult map ({:success? bool ...}).

Initialize the registered addon with config. Returns the InitResult map
({:success? bool ...}).

register!clj/s

(register! host addon)

Put an addon instance into the host registry, keyed by its addon-id. Returns host. MUST NOT throw for a normal duplicate (idempotent-ish).

Put an addon instance into the host registry, keyed by its addon-id.
Returns host. MUST NOT throw for a normal duplicate (idempotent-ish).

registeredclj/s

(registered host addon-id)

Fetch a mounted addon instance for sibling injection, or nil.

Fetch a mounted addon instance for sibling injection, or nil.

shutdown!clj/s

(shutdown! host addon-id)

Shutdown the registered addon. Returns nil. MUST NOT delete data.

Shutdown the registered addon. Returns nil. MUST NOT delete data.
sourceraw docstring

resolve-config-defaultclj/s

(resolve-config-default spec)

Default config resolver: a spec's own :addon/config (or {}). The host may inject a richer resolver (fn [spec] -> config-map) at the boundary.

Default config resolver: a spec's own :addon/config (or {}). The host may
inject a richer resolver (fn [spec] -> config-map) at the boundary.
sourceraw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
Move to previous article
Move to next article
Ctrl+/Jump to the search field
× close