# Libtmux_eio.Workspace

**Workspace Manager concept example** A working example of the core library. It can change without notice.

- **Package:** libtmux-eio
- **Language:** OCaml
- **Kind:** module
- **Source:** https://github.com/libtmux/libtmux-ocaml/blob/205dfda49742592b479247049d186956e4a4cfe9/eio/libtmux_eio.mli#L605
- **Public owner:** Libtmux_eio
- **Page:** https://libtmux.org/en/ocaml/latest/workspace/reference/libtmux_eio-workspace/

```ocaml
module Workspace
```

Apply workspace plans through Eio while retaining journals across caller cancellation. Handles belong to the creating domain; the application owns the scheduler and switch.

## Members

### Common operations

- [`await`](/en/ocaml/latest/workspace/reference/libtmux_eio-workspace-await/) (function): Apply steps at most once per execution handle. Expected failures return a retained journal. On initial application, `compensate_on_failure` defaults to `true`, attempting removal of proven newly created panes after failure or cancellation. Passing `false` skips that compensation. Eio cancellation propagates after progress is recorded and at most 500 ms of protected compensation. Admitted commands can still complete under client ownership; use {!inspect} before manual recovery.

### Other members

- [`client`](/en/ocaml/latest/workspace/reference/libtmux_eio-workspace-client/) (function): Borrow the existing or bootstrapped {!Client.t} without I/O for subsequent actions or recovery. {!close} releases a client owned by this workspace execution handle.
- [`close`](/en/ocaml/latest/workspace/reference/libtmux_eio-workspace-close/) (function): Release an owned client through {!Client.close}. Active await returns Busy. Closing is idempotent; completed journals remain readable.
- [`inspect`](/en/ocaml/latest/workspace/reference/libtmux_eio-workspace-inspect/) (function): Copy the retained {!type:Libtmux_workspace.Execution.receipt} without I/O, on the owning domain, including after execution or client closure. Pending steps can settle as the client progresses; earlier receipts keep their own step and cleanup arrays.
- [`submit`](/en/ocaml/latest/workspace/reference/libtmux_eio-workspace-submit/) (function): Allocate a generation-bound handle without I/O. The supplied client is borrowed; closing the handle leaves it open.
- [`submit_bootstrap`](/en/ocaml/latest/workspace/reference/libtmux_eio-workspace-submit_bootstrap/) (function): Allocate a missing-endpoint execution without I/O. Await starts control new-session and binds that same connection. The handle owns its new client within `sw`; it never owns the daemon.
- [`t`](/en/ocaml/latest/workspace/reference/libtmux_eio-workspace-t/) (typealias)

## Guides

Pages that discuss `Workspace`.

- [Choose the packages your application needs](/en/ocaml/latest/guides/packages/)
