@hydranium/data-server 1.0.0-next.14 → 1.0.0-next.140

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -19,10 +19,21 @@ Installed by the server process that already composes
19
19
  `getModelDocument`, `updateModelDocument`, `saveModelDocument`,
20
20
  `closeModelDocument`, `watchModelDocument` / `unwatchModelDocument`, and
21
21
  `waitForReady` for clients that must not race workspace initialisation.
22
+ - **Client sessions per connection:** `createSession` registers a participant,
23
+ whose requests then write only what it has open; `createModelDocument` and
24
+ the all-or-none `updateModelDocuments` serve sessions only; `closeSession`, or
25
+ the connection closing, ends a session and closes everything it has open. See
26
+ [Client sessions](../../docs/concepts/client-sessions.md).
22
27
  - **Push notifications instead of polling:** `onDocumentUpdated` when a
23
28
  subscribed document reaches the configured build phase
24
29
  (`DataServerOptions.subscriptionPhase`, `DocumentState.Validated` by default),
25
- `onDocumentSaved` on a separate channel, and `onProjectsChanged` from the
30
+ `onDocumentSaved` on a separate channel, `onDocumentDirtyChanged` when a
31
+ subscribed document starts or stops differing from its file (every document
32
+ the head sends also carries its current `dirty`), `onDocumentDeleted` (a
33
+ deleted document has no built state to carry, and the build-phase path never
34
+ runs for one), `onDocumentsBuilt` once per build for the documents nobody
35
+ watches — chiefly those rebuilt as a cascade, which no filesystem watcher can
36
+ see because their own files did not change — and `onProjectsChanged` from the
26
37
  project registry.
27
38
  - **Projects as first-class:** `getProjects` and `getProjectForUri`, answered from
28
39
  the framework's `ProjectManager`.
@@ -38,6 +49,8 @@ The projection itself is not this package's: it delegates to `TransferEncoder`
38
49
  and `ModelService` from `@hydranium/core`, so there is no second in-memory model
39
50
  to keep in sync.
40
51
 
52
+ For the adopter extension path, see [Add a data-server method](../../docs/guides/data-server-method.md). It covers the typed subclass, `additionalMethods`, shared namespace, and client proxy as one wire contract.
53
+
41
54
  ## Install
42
55
 
43
56
  ```bash