Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@ instead of inheriting that boundary. Once installed, the type belongs to the
collection: users can edit its fields and update the explicit contract mapping
without changing the published contract.

The featured `mdbase.runtime.standard` pack supplies the durable runtime 0.2
standard library: ten ordinary record contracts and canonical implementing
types, the four canonical record-change events, and inspectable timer-event
and cancellation-action artifacts.
Installing it is passive and grants no execution authority.

This repository is the canonical source. Its deterministic `dist/` output is
published at `https://mdbase.dev/contracts/`. A catalog entry is only a
discovery aid: every installable pack contains an exact manifest, embedded
Expand All @@ -25,6 +31,14 @@ packs/<id>/<version>.pack.yaml readable pack definitions
dist/ deterministic publication artifact
```

The runtime pack is generated in `mdbase-spec`. Contract and schema artifacts
are imported byte-for-byte; its referenced canonical types are materialized as
editable inline schema snapshots for the catalog:

```sh
MDBASE_SPEC_DIR=../mdbase-spec npm run sync:runtime
```

## Build and verify

Requires Node.js 22+ and a built checkout of
Expand Down
16 changes: 16 additions & 0 deletions contracts/mdbase.record.created/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
kind: mdbase.contract
contract_type: event
id: mdbase.record.created
version: 1.0.0
name: Record created
description: Published after a record is created and derived collection state is consistent.
data_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.record.created/1.0.0.schema.json
---

# Record created

This built-in is an ordinary, inspectable contract artifact. Runtime exchange
uses the mdbase interoperability profile unchanged.
16 changes: 16 additions & 0 deletions contracts/mdbase.record.deleted/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
kind: mdbase.contract
contract_type: event
id: mdbase.record.deleted
version: 1.0.0
name: Record deleted
description: Published after a record is deleted and derived collection state is consistent.
data_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.record.deleted/1.0.0.schema.json
---

# Record deleted

This built-in is an ordinary, inspectable contract artifact. Runtime exchange
uses the mdbase interoperability profile unchanged.
16 changes: 16 additions & 0 deletions contracts/mdbase.record.modified/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
kind: mdbase.contract
contract_type: event
id: mdbase.record.modified
version: 1.0.0
name: Record modified
description: Published after a record is modified and derived collection state is consistent.
data_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.record.modified/1.0.0.schema.json
---

# Record modified

This built-in is an ordinary, inspectable contract artifact. Runtime exchange
uses the mdbase interoperability profile unchanged.
16 changes: 16 additions & 0 deletions contracts/mdbase.record.renamed/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
kind: mdbase.contract
contract_type: event
id: mdbase.record.renamed
version: 1.0.0
name: Record renamed
description: Published after a record is renamed and derived collection state is consistent.
data_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.record.renamed/1.0.0.schema.json
---

# Record renamed

This built-in is an ordinary, inspectable contract artifact. Runtime exchange
uses the mdbase interoperability profile unchanged.
18 changes: 18 additions & 0 deletions contracts/mdbase.runtime.action-attempt/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
kind: mdbase.contract
contract_type: record
id: mdbase.runtime.action-attempt
version: 1.0.0
name: Durable action attempt
description: Durable invocation intent and outcome evidence using the shared interoperability envelope.
record_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.runtime.action-attempt/1.0.0.schema.json
---

# Durable action attempt

Durable invocation intent and outcome evidence using the shared interoperability envelope.

This artifact is passive. Installing it or a type that implements it grants no
authority to execute workflows or invoke providers.
18 changes: 18 additions & 0 deletions contracts/mdbase.runtime.capability-grant/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
kind: mdbase.contract
contract_type: record
id: mdbase.runtime.capability-grant
version: 1.0.0
name: Capability grant evidence
description: A materialized authorization grant scoped independently from contract conformance.
record_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.runtime.capability-grant/1.0.0.schema.json
---

# Capability grant evidence

A materialized authorization grant scoped independently from contract conformance.

This artifact is passive. Installing it or a type that implements it grants no
authority to execute workflows or invoke providers.
18 changes: 18 additions & 0 deletions contracts/mdbase.runtime.checkpoint/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
kind: mdbase.contract
contract_type: record
id: mdbase.runtime.checkpoint
version: 1.0.0
name: Runtime checkpoint
description: A durable, lease-safe workflow continuation.
record_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.runtime.checkpoint/1.0.0.schema.json
---

# Runtime checkpoint

A durable, lease-safe workflow continuation.

This artifact is passive. Installing it or a type that implements it grants no
authority to execute workflows or invoke providers.
18 changes: 18 additions & 0 deletions contracts/mdbase.runtime.dead-letter/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
kind: mdbase.contract
contract_type: record
id: mdbase.runtime.dead-letter
version: 1.0.0
name: Runtime dead letter
description: Retained event or action evidence that cannot be processed safely.
record_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.runtime.dead-letter/1.0.0.schema.json
---

# Runtime dead letter

Retained event or action evidence that cannot be processed safely.

This artifact is passive. Installing it or a type that implements it grants no
authority to execute workflows or invoke providers.
18 changes: 18 additions & 0 deletions contracts/mdbase.runtime.diagnostic/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
kind: mdbase.contract
contract_type: record
id: mdbase.runtime.diagnostic
version: 1.0.0
name: Runtime diagnostic
description: A machine-readable durable runtime diagnostic.
record_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.runtime.diagnostic/1.0.0.schema.json
---

# Runtime diagnostic

A machine-readable durable runtime diagnostic.

This artifact is passive. Installing it or a type that implements it grants no
authority to execute workflows or invoke providers.
18 changes: 18 additions & 0 deletions contracts/mdbase.runtime.policy/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
kind: mdbase.contract
contract_type: record
id: mdbase.runtime.policy
version: 1.0.0
name: Runtime policy
description: Local authorization, executor, limit, and provider-selection policy.
record_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.runtime.policy/1.0.0.schema.json
---

# Runtime policy

Local authorization, executor, limit, and provider-selection policy.

This artifact is passive. Installing it or a type that implements it grants no
authority to execute workflows or invoke providers.
18 changes: 18 additions & 0 deletions contracts/mdbase.runtime.provider-registration/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
kind: mdbase.contract
contract_type: record
id: mdbase.runtime.provider-registration
version: 1.0.0
name: Provider registration evidence
description: An optional audit snapshot of a verified interoperability declaration; it never activates code.
record_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.runtime.provider-registration/1.0.0.schema.json
---

# Provider registration evidence

An optional audit snapshot of a verified interoperability declaration; it never activates code.

This artifact is passive. Installing it or a type that implements it grants no
authority to execute workflows or invoke providers.
22 changes: 22 additions & 0 deletions contracts/mdbase.runtime.run.cancel/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
---
kind: mdbase.contract
contract_type: action
id: mdbase.runtime.run.cancel
version: 1.0.0
name: Cancel durable runtime run
description: Request cooperative cancellation of one durable runtime run.
input_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.runtime.run.cancel/1.0.0.schema.json
output_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.runtime.run.cancel/1.0.0.output.schema.json
behavior:
idempotency: required
cancellation: none
---

# Cancel durable runtime run

This built-in is an ordinary, inspectable contract artifact. Runtime exchange
uses the mdbase interoperability profile unchanged.
18 changes: 18 additions & 0 deletions contracts/mdbase.runtime.run/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
kind: mdbase.contract
contract_type: record
id: mdbase.runtime.run
version: 1.0.0
name: Durable run
description: The durable state and immutable admitted plan for one workflow execution.
record_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.runtime.run/1.0.0.schema.json
---

# Durable run

The durable state and immutable admitted plan for one workflow execution.

This artifact is passive. Installing it or a type that implements it grants no
authority to execute workflows or invoke providers.
16 changes: 16 additions & 0 deletions contracts/mdbase.runtime.timer.fired/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
kind: mdbase.contract
contract_type: event
id: mdbase.runtime.timer.fired
version: 1.0.0
name: Runtime timer fired
description: Published with scheduling evidence and opaque application data when the current generation of a durable timer fires.
data_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.runtime.timer.fired/1.0.0.schema.json
---

# Runtime timer fired

This built-in is an ordinary, inspectable contract artifact. Runtime exchange
uses the mdbase interoperability profile unchanged.
18 changes: 18 additions & 0 deletions contracts/mdbase.runtime.timer/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
kind: mdbase.contract
contract_type: record
id: mdbase.runtime.timer
version: 1.0.0
name: Runtime timer
description: A generation-safe one-shot timer that publishes through the interoperability profile.
record_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.runtime.timer/1.0.0.schema.json
---

# Runtime timer

A generation-safe one-shot timer that publishes through the interoperability profile.

This artifact is passive. Installing it or a type that implements it grants no
authority to execute workflows or invoke providers.
18 changes: 18 additions & 0 deletions contracts/mdbase.runtime.workflow/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
kind: mdbase.contract
contract_type: record
id: mdbase.runtime.workflow
version: 1.0.0
name: Durable workflow
description: A portable workflow whose event and action references are resolved and pinned at admission.
record_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.runtime.workflow/1.0.0.schema.json
---

# Durable workflow

A portable workflow whose event and action references are resolved and pinned at admission.

This artifact is passive. Installing it or a type that implements it grants no
authority to execute workflows or invoke providers.
16 changes: 16 additions & 0 deletions dist/artifacts/contracts/mdbase.record.created/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
kind: mdbase.contract
contract_type: event
id: mdbase.record.created
version: 1.0.0
name: Record created
description: Published after a record is created and derived collection state is consistent.
data_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.record.created/1.0.0.schema.json
---

# Record created

This built-in is an ordinary, inspectable contract artifact. Runtime exchange
uses the mdbase interoperability profile unchanged.
16 changes: 16 additions & 0 deletions dist/artifacts/contracts/mdbase.record.deleted/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
kind: mdbase.contract
contract_type: event
id: mdbase.record.deleted
version: 1.0.0
name: Record deleted
description: Published after a record is deleted and derived collection state is consistent.
data_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.record.deleted/1.0.0.schema.json
---

# Record deleted

This built-in is an ordinary, inspectable contract artifact. Runtime exchange
uses the mdbase interoperability profile unchanged.
16 changes: 16 additions & 0 deletions dist/artifacts/contracts/mdbase.record.modified/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
kind: mdbase.contract
contract_type: event
id: mdbase.record.modified
version: 1.0.0
name: Record modified
description: Published after a record is modified and derived collection state is consistent.
data_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.record.modified/1.0.0.schema.json
---

# Record modified

This built-in is an ordinary, inspectable contract artifact. Runtime exchange
uses the mdbase interoperability profile unchanged.
16 changes: 16 additions & 0 deletions dist/artifacts/contracts/mdbase.record.renamed/1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
kind: mdbase.contract
contract_type: event
id: mdbase.record.renamed
version: 1.0.0
name: Record renamed
description: Published after a record is renamed and derived collection state is consistent.
data_schema:
dialect: json-schema-2020-12
ref: ../../schemas/mdbase.record.renamed/1.0.0.schema.json
---

# Record renamed

This built-in is an ordinary, inspectable contract artifact. Runtime exchange
uses the mdbase interoperability profile unchanged.
Loading