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
29 changes: 0 additions & 29 deletions docs/adr/0010-process-manager-architecture.md

This file was deleted.

72 changes: 0 additions & 72 deletions docs/adr/0012-compiled-bun-runtime-dispatch.md

This file was deleted.

5 changes: 3 additions & 2 deletions docs/adr/0013-live-e2e-bypasses-replay-server.md
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,9 @@ independent green signals instead of one averaged result.

## Related Decisions

- [ADR 0012](0012-compiled-bun-runtime-dispatch.md): Compiled Bun Runtime Dispatch
(the next CLI e2e harness runs against the compiled binary)
- [Compiled Bun self-dispatch](../../packages/process-compose/docs/architecture.md#compiled-bun-self-dispatch):
the next CLI e2e harness runs against the compiled binary and therefore exercises its process
re-entry contract
- [ADR 0011](0011-cli-release-and-distribution-strategy.md): CLI Release & Distribution Strategy

## See Also
Expand Down
2 changes: 0 additions & 2 deletions docs/adr/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,7 @@ When an ADR becomes outdated, mark it as `deprecated` or reference the supersedi
| 0007 | [Real-time Progress in Command Handlers](0007-realtime-progress-in-command-handlers.md) | proposed |
| 0008 | [Authentication & Token Management](0008-authentication-and-token-management.md) | proposed |
| 0009 | [Configuration Schema & Validation](0009-configuration-schema-and-validation.md) | proposed |
| 0010 | [Process Manager Architecture](0010-process-manager-architecture.md) | proposed |
| 0011 | [CLI Release & Distribution Strategy](0011-cli-release-and-distribution-strategy.md) | proposed |
| 0012 | [Compiled Bun Runtime Dispatch](0012-compiled-bun-runtime-dispatch.md) | proposed |
| 0013 | [Live E2E Tests Bypass the Replay Server](0013-live-e2e-bypasses-replay-server.md) | proposed |

## Template
Expand Down
49 changes: 28 additions & 21 deletions packages/process-compose/README.md
Original file line number Diff line number Diff line change
@@ -1,32 +1,39 @@
# @supabase/process-compose
# `@supabase/process-compose`

TypeScript port of [process-compose](https://github.com/F1bonacc1/process-compose) for Bun. Orchestrates multiple processes with health checks, an HTTP API, and structured logging. Zero runtime dependencies.
An Effect-based TypeScript library for supervising dependency-ordered process graphs under Bun or
Node.js.

## Usage

As a library:
The package accepts in-memory `ServiceDef` values and provides lifecycle control, readiness,
health probes, restart policies, state streams, log streams, and optional orphan supervision. It
does not expose a CLI, parse YAML, or run an HTTP server.

```ts
import { createProcessCompose } from "@supabase/process-compose";

const pc = await createProcessCompose({
configPath: "process-compose.yaml",
apiPort: 8080,
});

await pc.start();
import { buildGraph, Orchestrator } from "@supabase/process-compose";
import { Effect } from "effect";

const graph = await Effect.runPromise(
buildGraph([
{ name: "database", command: "postgres" },
{
name: "api",
command: "api-server",
dependencies: [{ service: "database", condition: "healthy" }],
},
]),
);

// Orchestrator.layer(graph) requires a LogBuffer layer and the caller's
// ChildProcessSpawner Adapter.
const orchestratorLayer = Orchestrator.layer(graph);
```

As a CLI:

```sh
bun run packages/process-compose/src/cli.ts -f process-compose.yaml
```
See [the architecture guide](./docs/architecture.md) for the lifecycle, supervision, and compiled
runtime contracts.

## Development

```sh
pnpm run check:all # Run all quality checks in parallel
pnpm run fix:all # Auto-fix lint, format, and unused exports in parallel
pnpm run test # Run tests
pnpm check:all
pnpm fix:all
pnpm test:core
```
Loading
Loading