@tsuga/cli 1.51.0 → 1.52.0
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 +9 -9
- package/dist/cli.js +7 -7
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -536,27 +536,27 @@ tsuga promql query -d '{"query":"sum by (\"context.service.name\") (sum_over_tim
|
|
|
536
536
|
|
|
537
537
|
`timeRange.from` / `timeRange.to` are Unix timestamps in seconds.
|
|
538
538
|
|
|
539
|
-
##
|
|
540
|
-
|
|
541
|
-
Commands under `tsuga experimental` may change or be removed without notice.
|
|
542
|
-
|
|
543
|
-
### Continuous profiling
|
|
539
|
+
## Continuous profiling
|
|
544
540
|
|
|
545
541
|
```bash
|
|
546
542
|
# Rank functions by self (flat) and inclusive (cum) sample value, like `go tool pprof -top`
|
|
547
|
-
tsuga
|
|
548
|
-
tsuga
|
|
543
|
+
tsuga profiles top --service api --type cpu --from=-1h
|
|
544
|
+
tsuga profiles top --service api --type alloc_space --from=-1h --limit 10 -o tsv
|
|
549
545
|
|
|
550
546
|
# Download the merged profile as raw pprof protobuf and open it with pprof
|
|
551
|
-
tsuga
|
|
547
|
+
tsuga profiles pprof --service api --type cpu --from=-1h -O cpu.pb
|
|
552
548
|
go tool pprof -http=: cpu.pb
|
|
553
549
|
|
|
554
550
|
# Raw folded stacks (`root;...;leaf` with a value), with the usual -f / -d / --generate-skeleton
|
|
555
|
-
tsuga
|
|
551
|
+
tsuga profiles query -d '{"service":"api","type":"cpu","timeRange":{"from":1704067200,"to":1704070800}}'
|
|
556
552
|
```
|
|
557
553
|
|
|
558
554
|
`--type` is a pprof sample type such as `cpu`, `samples`, `wall`, `off_cpu`, `alloc_space`, `inuse_space`, `alloc_objects`, `inuse_objects`, or `goroutine`. `--filter` takes a Tsuga query over the profile labels; only label equality, negation, and wildcards are accepted.
|
|
559
555
|
|
|
556
|
+
## Experimental
|
|
557
|
+
|
|
558
|
+
Commands under `tsuga experimental` may change or be removed without notice.
|
|
559
|
+
|
|
560
560
|
### Sandbox agent runs
|
|
561
561
|
|
|
562
562
|
```bash
|