tina4-nodejs 3.13.165 → 3.13.166

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/CLAUDE.md CHANGED
@@ -14,13 +14,13 @@ Even if the skill text is not currently loaded, these are non-negotiable:
14
14
 
15
15
  The full discipline lives in `.claude/skills/tina4-maintainer/SKILL.md`; this block is the always-on floor.
16
16
 
17
- # CLAUDE.md - AI Developer Guide for tina4-nodejs (v3.13.165)
17
+ # CLAUDE.md - AI Developer Guide for tina4-nodejs (v3.13.166)
18
18
 
19
19
  > This file helps AI assistants (Claude, Copilot, Cursor, etc.) understand and work on this codebase effectively.
20
20
 
21
21
  ## What This Project Is
22
22
 
23
- Tina4 for Node.js/TypeScript v3.13.165 - The Intelligent Native Application 4ramework. A convention-over-configuration structural paradigm. The developer writes TypeScript; Tina4 is invisible infrastructure.
23
+ Tina4 for Node.js/TypeScript v3.13.166 - The Intelligent Native Application 4ramework. A convention-over-configuration structural paradigm. The developer writes TypeScript; Tina4 is invisible infrastructure.
24
24
 
25
25
  The philosophy: zero ceremony, batteries included, file system as source of truth.
26
26
 
@@ -1081,10 +1081,17 @@ for await (const job of queue.consume("emails")) {
1081
1081
  ## Graceful shutdown (`packages/core/src/server.ts`)
1082
1082
 
1083
1083
  `startServer()` owns signal handling. It is the ONLY place that registers
1084
- `process.on("SIGTERM"/"SIGINT")` — `background.ts` and the CLI's `serve.ts`
1085
- deliberately register none.
1084
+ `process.on("SIGTERM"/"SIGINT")` (plus `"SIGBREAK"` on Windows) — `background.ts`
1085
+ and the CLI's `serve.ts` deliberately register none.
1086
1086
 
1087
- On SIGTERM or SIGINT it: stops background tasks, sends RFC 6455 close code
1087
+ On Windows, Ctrl+Break and the CTRL_BREAK_EVENT a console or service manager
1088
+ sends a process group arrive as **SIGBREAK**; untrapped, Node kills the process
1089
+ on the spot (exit `0xC000013A`). `startServer()` traps it into the same drain, at
1090
+ parity with tina4-python (SIGINT/SIGBREAK/SIGTERM on Windows).
1091
+ `test/gracefulShutdown.test.ts` drives it with a real CTRL_BREAK_EVENT via
1092
+ `test/_ctrlBreak.ts`.
1093
+
1094
+ On SIGTERM, SIGINT or (Windows) SIGBREAK it: stops background tasks, sends RFC 6455 close code
1088
1095
  **1001 ("going away")** to every live WebSocket, closes the listeners so new
1089
1096
  connections get a clean refusal, waits for in-flight requests to finish (up to
1090
1097
  `TINA4_SHUTDOWN_TIMEOUT`), closes the database, and exits **0**.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tina4-nodejs",
3
- "version": "3.13.165",
3
+ "version": "3.13.166",
4
4
  "type": "module",
5
5
  "description": "Tina4 for Node.js/TypeScript - native TypeScript conventions and shared Tina4 contracts",
6
6
  "keywords": [