Skip to content
runward
runward
Product
Who it is for
Trust
Documentation
News
Try it on an example Talk to us

Docs · The doctrine · Section 15

Beyond the application, the shared building blocks

Everything above addresses one application: a domain, its ports, its adapters. But some capabilities are the adapter of no application in particular: they are shared by several, by nature. A connector library, a skill catalog, a cross-application memory, a delivery and evaluation chain, an agent identity: these are enterprise building blocks. This section fixes their principles; the landscape of locations and offerings, shifting by nature, is deliberately left outside these pages, which retain only what holds whatever the vendors.

The shift, and the rule that does not move

Housing a shared building block inside an application condemns it to duplication; housing it elsewhere does not leave the model. The block leaves the application, but the application still consumes it through a port, a stable contract; what changes is that the adapter behind that port points to an enterprise service instead of a local structure. The question is therefore never port or no port: it is which location behind the port, existing infrastructure, dedicated platform, or managed service. This location trade-off is reversible precisely because the contract itself does not move.

APPLICATION domain + orchestrator use cases PORTS MODEL GATEWAYtier routing, governanceSHARED MEMORYinvariant static + variableCONNECTOR LIBRARYtools via the tool protocolSKILL CATALOGversioned artifacts + catalogIDENTITY AND SECRETSaccess management, vault, in placeDELIVERY AND EVALUATIONexisting pipeline + eval gates The block leaves the application; the application still consumes it via a port, a stable contract.

The locations, and the criteria that decide

Behind each port, five location families. In the application itself: a local adapter, simple but duplicated as soon as a second application appears. Existing infrastructure, API gateway, artifact repository, integration pipeline, access management: sovereign and amortized, but not designed for the agentic. The dedicated internal platform: control and reuse, at the price of building and operating it. The managed service from an infrastructure provider: mature and fast, less sovereign, dependent. The managed runtime from a model provider: maximum velocity and the strongest dependency, the one on the supplier of the central component, with partial sovereignty when tool execution stays in-house. Six criteria decide, and they alone are stable: sovereignty and control, reuse across applications, implementation velocity, cost and dependency, reuse of the existing estate, compliance. The grid is durable; filling it in depends on a dated landscape and context, deliberately outside these pages.

The recursive motif: contract, index, implementation

At the scale of one application, the adapter is local. At the scale of an infrastructure, since the block is shared, the adapter becomes a thin client that resolves the capability through a common index, then calls it by its contract. It is the direct extension of the two-adapter registry (section 05): the motif is recursive. Three things remain distinct and must never merge: the contract, which states what the block promises; the index, which publishes and makes discoverable; the shared implementation, which honors the contract. It is not the adapters that become the index: it is their discovery that goes through an index.

Applicationadapter, discovery client resolves DISCOVERY INDEXpublishes and resolves, does not orchestrate calls Shared building blockconsumed through its contract Contract, index, implementation: three distinct things. The index is not a brain.

The guards, amplified at scale

Two guards of this doctrine apply as they stand and become more critical at platform scale. The first: the index, or the catalog, stays an index, not a brain; it publishes and makes discoverable, it does not orchestrate, on pain of recreating the bloated integration bus (section 05). The trap takes a precise form here: letting the delivery chain or the catalog decide at runtime which skill to call. Delivery delivers; the application's orchestrator decides. The second: a third-party skill or connector is an untrusted input; least privilege, approval on the action, and the triad breaks on the context window (section 11). A shared catalog amplifies this surface: curation and security review are not optional there.

The durable execution engine, one adapter among others

When turns grow long, waits, recoveries, compensations, a durable execution engine can carry these properties as a shared building block: step journal, retry, suspension and wake-up. It remains an adapter behind the ports, and the guard is the same as for the index: it carries control flow and durability, never reasoning or business logic. The model call remains an activity whose output is recorded: it is reread, not replayed (section 07). Letting the orchestration engine decide business logic would, here again, amount to rebuilding the bloated bus.

The building-block matrix

As with the decision matrix of section 13, each block has a sober default and an explicit trigger; the default applies as long as no trigger commands a change.

BlockRecommended defaultSwitch when
Model gatewayThe existing API gateway, seen as the model portAgentic functions (tier routing, cost governance) outgrow it.
Connector libraryExisting infrastructure carries transport and securityIt caps out on tool semantics and discovery: dedicated or managed block.
Skill catalogExisting artifact repository for the versioned packageCuration and security review demand it: dedicated catalog, never without curation.
Shared memoryIn the application for working memoryA real cross-application need, not a distant target.
Discovery registryIn-memory table (section 05)Crossing a process boundary: shared registry (section 07).
Durable executionSimple loop in the applicationLong turns, approval waits, recovery after failure: durable engine, which never carries business logic.
Delivery and evaluationExisting integration pipeline plus evaluation gatesGuarded continuous evaluation (section 12) outgrows the pipeline: dedicated evaluation block.
ObservabilityExisting stack for trace transportRegulated data: self-hosted, because traces are data.
Identity and secretsExisting access management and vaultAgent identity and bounded delegation required (section 11): dedicated block.

Sovereignty is graduated by class of data

Sovereignty is not a switch, it is a gradient: it is decided per class of data, not wholesale. The rule that follows: sovereign by default wherever sovereignty costs only operations, gateway, memory, registry, execution, access control; the only tier where it can cost quality is the model, and the model port makes precisely its sensitivity-based routing local and reversible, best available engine for ordinary data, sovereign engine for regulated data. A consequence often forgotten: execution traces contain the prompts and the outputs, hence data; they follow the same gradient, and exporting them to a third-party service is an exfiltration like any other (section 10).

Compliance consumes the architecture

Regulatory compliance is not a separate workstream: it is a layer that consumes the primitives already in place, immutable logging, human oversight, least privilege, memory governance and erasure, provenance. One extension is enough to equip it: the discovery registry extends into a usage registry, which carries, per deployment, the risk class, the data classes, and the owner, under an identified responsible party and a periodic review. Because risk is classified per deployment, not per platform: the same foundation, reused for a sensitive use, tips that particular deployment into a more demanding regime, without the architecture changing.

The lesson of the layers

A history lesson, to close. Infrastructures sediment: each generation deposits a layer of abstraction on top of the previous one, and every layer ends up commoditized while a new one stacks above it. At each transition, the systems that consumed the layer below through a contract crossed it; those that had welded themselves to it paid dearly. The building blocks of this section will not escape the rule: they will be commoditized in their turn. That is precisely why one consumes them behind ports and does not weld to them: the discipline of contracts does not only protect against a change of vendor, it carries you across the layers themselves.

Talk to us

Tell us who you are, and we will get back to you.

Your details are recorded by Another Framework, publisher of runward, to get back to you. They are neither sold nor shared, and are deleted three years after our last exchange. To see or delete them: contact@runward.dev.