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
4 changes: 4 additions & 0 deletions src/core/device-provisioner.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -446,6 +446,8 @@ describe("DeviceProvisioner and a component removal (ADR 0010 §8)", () => {
// doctor and registry tests split out of one file (ADR 0063).
[join("core", "test-doctor.ts")]: 2,
[join("core", "test-registry.ts")]: 1,
// why: the harness the lease-acquisition coordinator tests split out of one file share (ADR 0063).
[join("leasing", "test-lease-acquisition.ts")]: 1,
});
expect(callSites(/\.provision\(/g)).toEqual({
// The driver call itself.
Expand All @@ -458,6 +460,8 @@ describe("DeviceProvisioner and a component removal (ADR 0010 §8)", () => {
// part, and its test helpers (never loaded in production) drive the driver to build fixtures.
[join("drivers", "android", "index.ts")]: 1,
[join("drivers", "android", "testing.ts")]: 2,
// why: the harness's fixture devices, as for registerDevice above.
[join("leasing", "test-lease-acquisition.ts")]: 1,
});
});

Expand Down
32 changes: 16 additions & 16 deletions src/leasing/AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,22 +8,22 @@ Flows: [device selection](../../docs/internal/flows/device-selection.md), [start

## Files

| File | Role |
| ----------------------------------------- | ------------------------------------------------------------------------------------------------- |
| `create-leasing.ts` | Composition root; builds `corePorts` for `core.connect` |
| `lease-acquisition-coordinator.ts` | Admission, spec resolution, plan → perform loop, grant |
| `acquisition-planner.ts` | Read-only plan; takes the claim or reservation it hands back |
| `wait-queue.ts` | FIFO, two lines (virtual, physical), timeouts, cancel; `requesterLimitDecision` |
| `lease-request-book.ts` | Request records: store before queue, idempotent replay, settle once |
| `lease-lifecycle.ts` | Registry half of grant, renew, release |
| `lease-expiry-scheduler.ts` | TTL timers |
| `lease-release-coordinator.ts` | Every lease ending; lease-end participants; background reclaim |
| `lease-health-monitor.ts` | Reboots a crashed leased virtual device under its lease |
| `physical-device-watcher.ts` | Presence polling of enrolled physical devices |
| `lease-startup.ts`, `lease-reconciler.ts` | Lease half of startup |
| `lease-refusal.ts` | `lease.rejected`, or `lease.declined` for a gateway request |
| `lease-ports.ts` | `LeaseCommands`, `QueueControl`, `LeaseEndParticipant` |
| `testing.ts` | Builds core + leasing for other modules' tests; `TestEngineConfig` is the config slice that takes |
| File | Role |
| ----------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `create-leasing.ts` | Composition root; builds `corePorts` for `core.connect` |
| `lease-acquisition-coordinator.ts` | Admission, spec resolution, plan → perform loop, grant |
| `acquisition-planner.ts` | Read-only plan; takes the claim or reservation it hands back |
| `wait-queue.ts` | FIFO, two lines (virtual, physical), timeouts, cancel; `requesterLimitDecision` |
| `lease-request-book.ts` | Request records: store before queue, idempotent replay, settle once |
| `lease-lifecycle.ts` | Registry half of grant, renew, release |
| `lease-expiry-scheduler.ts` | TTL timers |
| `lease-release-coordinator.ts` | Every lease ending; lease-end participants; background reclaim |
| `lease-health-monitor.ts` | Reboots a crashed leased virtual device under its lease |
| `physical-device-watcher.ts` | Presence polling of enrolled physical devices |
| `lease-startup.ts`, `lease-reconciler.ts` | Lease half of startup |
| `lease-refusal.ts` | `lease.rejected`, or `lease.declined` for a gateway request |
| `lease-ports.ts` | `LeaseCommands`, `QueueControl`, `LeaseEndParticipant` |
| `testing.ts`, `test-lease-acquisition.ts` | Builds core + leasing for other modules' tests; `TestEngineConfig` is the config slice that takes; the harness the `lease-acquisition*.test.ts` parts share |

## The update hold

Expand Down
Loading
Loading