@xemahq/backend-slot-registry-adapters
v0.1.3
Published
Adapter wrappers that project existing in-process per-service registries (MountSourceKindRegistry, InquiryKindSchemaRegistry, …) into a BackendSlotRegistry under their ContributionKind. Honours the 'adapt, not rewrite' policy from Xema OS plan §3.5 / §17.
Readme
@xemahq/backend-slot-registry-adapters
Project per-service registries into the slot catalog.
Overview
Adapter wrappers that re-project a service's existing in-process registries — such as its mount-source-kind and inquiry-kind registries — into a backend slot registry under their contribution kind. The existing registries keep their own callers untouched; this package only mirrors their entries into the shared slot catalog so a service exposes one unified view of its contributions. It ships a single boot-time helper that wires whichever registries a service actually owns.
When to use it
- Use it at service boot to surface existing typed registries through the shared backend slot registry without rewriting their call sites.
- Reach for it when a service already owns specialized registries and you want them visible alongside other contribution slots.
Installation
pnpm add @xemahq/backend-slot-registry-adaptersUsage
import { seedFromExistingRegistries } from '@xemahq/backend-slot-registry-adapters';
import { createBackendSlotRegistry } from '@xemahq/backend-slot-registry';
const slots = createBackendSlotRegistry();
// Wire only the registries this service actually owns:
seedFromExistingRegistries(slots, { mountRegistry, inquiryRegistry });License
Apache-2.0 © Xema — xema.dev
