@saptools/cf-inspector 0.3.9 → 0.3.12

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.
Files changed (2) hide show
  1. package/README.md +10 -35
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -46,20 +46,6 @@ pnpm add @saptools/cf-inspector
46
46
 
47
47
  ## 🚀 Quick Start
48
48
 
49
- ### Local Node process
50
-
51
- ```bash
52
- # Terminal 1 — run any Node app with the inspector enabled
53
- node --inspect=9229 my-app.js
54
-
55
- # Terminal 2 — capture a snapshot when handler.ts:42 hits
56
- cf-inspector snapshot \
57
- --port 9229 \
58
- --bp src/handler.ts:42 \
59
- --capture 'this.user, req.body' \
60
- --timeout 30
61
- ```
62
-
63
49
  ### Cloud Foundry app (auto-tunnel)
64
50
 
65
51
  ```bash
@@ -72,7 +58,7 @@ cf-inspector snapshot \
72
58
  --remote-root 'regex:^/(home/vcap/app|example-root-.*)$'
73
59
  ```
74
60
 
75
- The first form connects directly to `localhost:9229`. The second internally calls `@saptools/cf-debugger` to open the SSH tunnel, runs the snapshot through it, and tears the tunnel down on exit.
61
+ This command internally calls `@saptools/cf-debugger` to open the SSH tunnel, runs the snapshot through it, and tears the tunnel down on exit.
76
62
 
77
63
  ---
78
64
 
@@ -83,13 +69,6 @@ The first form connects directly to `localhost:9229`. The second internally call
83
69
  Set one or more breakpoints, wait for any of them to hit, capture frame metadata and requested expressions, auto-resume, exit.
84
70
 
85
71
  ```bash
86
- # Simple snapshot
87
- cf-inspector snapshot \
88
- --port 9229 \
89
- --bp src/handler.ts:42 \
90
- --capture 'this.user, req.body' \
91
- --timeout 30
92
-
93
72
  # Conditional snapshot — only pauses for the user we care about
94
73
  cf-inspector snapshot --port 9229 \
95
74
  --bp src/handler.ts:42 \
@@ -115,21 +94,17 @@ cf-inspector snapshot --port 9229 \
115
94
  | `--remote-root <value>` | Optional path-mapping anchor: literal path or `regex:<pattern>` / `/pattern/flags` |
116
95
  | `--include-scopes` | Include expanded paused-frame scopes under `topFrame.scopes`. Omitted by default to keep targeted captures concise |
117
96
  | `--no-json` | Print a human-readable summary instead of JSON |
118
- | `--keep-paused` | Skip `Debugger.resume` after capture; Node may resume when the CLI disconnects |
97
+ | `--keep-paused` | Skip `Debugger.resume` after capture |
119
98
  | `--fail-on-unmatched-pause` | Fail immediately if the target pauses somewhere else instead of waiting cooperatively |
120
99
 
121
- JSON output includes frame metadata and `captures` by default. `topFrame.scopes`
122
- is only present with `--include-scopes`, because Cloud Foundry Node apps often
123
- carry large local/closure/module objects that drown out targeted captures. The
124
- output contains raw debugger values; use it only against trusted targets and be
125
- careful when sharing logs. The output also includes `pausedDurationMs`, the
126
- client-observed time from receiving
127
- the matching pause event until `Debugger.resume` completes. It does not include
128
- the time spent waiting for the breakpoint to hit. When `--keep-paused` is used,
129
- `pausedDurationMs` is `null` because `cf-inspector` intentionally skips
130
- `Debugger.resume`. Node may resume execution when this one-shot CLI disconnects,
131
- so treat `--keep-paused` as a low-level diagnostic escape hatch, not a durable
132
- paused-session mode.
100
+ Snapshot JSON includes frame metadata and `captures` by default. `topFrame.scopes`
101
+ is only present with `--include-scopes` because scope objects can be large and
102
+ drown out targeted captures. Values are raw debugger values, so be careful when
103
+ sharing logs.
104
+
105
+ `pausedDurationMs` measures the client-observed time from receiving the matching
106
+ pause event until `Debugger.resume` completes. With `--keep-paused`, it is `null`
107
+ because resume is intentionally skipped.
133
108
 
134
109
  If the target pauses somewhere else first, for example another debugger's
135
110
  breakpoint or a `debugger;` statement, `snapshot` does not resume it by default.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@saptools/cf-inspector",
3
- "version": "0.3.9",
3
+ "version": "0.3.12",
4
4
  "description": "Set breakpoints, capture variable snapshots, and evaluate expressions on a SAP BTP Cloud Foundry Node.js app via the Chrome DevTools Protocol — agent-friendly, no IDE required.",
5
5
  "type": "module",
6
6
  "publishConfig": {