mirror of https://github.com/linkerd/linkerd2.git
## Motivation Introduces an `unmeshed` flag to the `stat` command so that users can opt-in to viewing unmeshed resources in the `stat` output. This changes the existing behavior of the `stat` command such that unmeshed resources no longer render by default in the output. Before: ``` ❯ bin/linkerd stat -A deploy NAMESPACE NAME MESHED SUCCESS RPS LATENCY_P50 LATENCY_P95 LATENCY_P99 TCP_CONN kube-system coredns 0/1 - - - - - - kube-system local-path-provisioner 0/1 - - - - - - kube-system metrics-server 0/1 - - - - - - kube-system traefik 0/1 - - - - - - linkerd linkerd-controller 1/1 100.00% 0.3rps 1ms 2ms 2ms 2 linkerd linkerd-destination 1/1 100.00% 0.3rps 1ms 1ms 1ms 11 ... ``` After: ``` ❯ bin/linkerd stat -A deploy NAMESPACE NAME MESHED SUCCESS RPS LATENCY_P50 LATENCY_P95 LATENCY_P99 TCP_CONN linkerd linkerd-controller 1/1 100.00% 0.3rps 1ms 1ms 1ms 2 linkerd linkerd-destination 1/1 100.00% 0.3rps 1ms 2ms 2ms 13 ... ``` Closes #3871 ## Solution Using the meshed pod count in the stat response, resources with a count of `0` are not rendered in the table. The `-l`/`--selector` flag do not work for all resource types, so applying a default label does not solve this problem. While it works for pods, it does not work for deployments as the `linkerd.io/inject` is an annotation that cannot be selected on. I did not think a shorthand flag was necessary for this. I do not think users will commonly pass this flag to the `stat` command, and I didn't think adding an additional short flag such as `u` was necessary. Signed-off-by: Kevin Leimkuhler <kevin@kleimkuhler.com> |
||
|---|---|---|
| .. | ||
| edges | ||
| egress | ||
| endpoints | ||
| externalissuer | ||
| get | ||
| inject | ||
| routes | ||
| serviceaccounts | ||
| serviceprofiles | ||
| stat | ||
| tap | ||
| testdata | ||
| tracing | ||
| trafficsplit | ||
| uninstall | ||
| install_test.go | ||