linkerd2/controller/api/public
Alex Leong ec51434eb9
Show traffic split metrics from sources in all namespaces (#3967)
Fixes #3562 

When a pod in one namespace sends traffic to a service which is the apex of a traffic split in another namespace, that traffic is not displayed in the `linkerd stat trafficsplit` output.  This is because when we do a Prometheus query for traffic to the traffic split, we supply a Prometheus label selector to only select traffic sources in the namespace of the traffic split.

Since any pod in any namespace can send traffic to the apex service of a traffic split, we must look at all possible sources of traffic, not just the ones in the same namespace.

Before:

```
$ bin/linkerd stat ts
NAME           APEX     LEAF       WEIGHT   SUCCESS   RPS   LATENCY_P50   LATENCY_P95   LATENCY_P99
webapp-split   webapp   webapp       900m         -     -             -             -             -
webapp-split   webapp   webapp-2     100m         -     -             -             -             -
```

After:

```
$ bin/linkerd stat ts
NAME           APEX     LEAF       WEIGHT   SUCCESS      RPS   LATENCY_P50   LATENCY_P95   LATENCY_P99
webapp-split   webapp   webapp       900m    80.00%   1.4rps          31ms          99ms        2530ms
webapp-split   webapp   webapp-2     100m    60.00%   0.2rps          35ms          93ms          99ms
```

Signed-off-by: Alex Leong <alex@buoyant.io>
2020-02-12 09:21:59 -08:00
..
testdata Fix issue for debug containers when using custom Docker registry (#3873) 2020-01-17 10:18:03 -08:00
client.go Trace Control plane Components with OC (#3495) 2019-10-18 12:19:13 -07:00
client_test.go Remove Discovery service leftovers (#3500) 2019-10-15 11:20:21 -05:00
edges.go Add unit test for edges API endpoint (#3306) 2019-08-23 09:28:02 -07:00
edges_test.go Add unit test for edges API endpoint (#3306) 2019-08-23 09:28:02 -07:00
grpc_server.go Fix issue for debug containers when using custom Docker registry (#3873) 2020-01-17 10:18:03 -08:00
grpc_server_test.go Fix issue for debug containers when using custom Docker registry (#3873) 2020-01-17 10:18:03 -08:00
http_server.go Remove Discovery service leftovers (#3500) 2019-10-15 11:20:21 -05:00
http_server_test.go Remove Discovery service leftovers (#3500) 2019-10-15 11:20:21 -05:00
prometheus.go Upgrade prometheus to v1.2.1 (#3541) 2019-12-11 15:26:16 -08:00
stat_summary.go Show traffic split metrics from sources in all namespaces (#3967) 2020-02-12 09:21:59 -08:00
stat_summary_test.go Add CronJobs and ReplicaSets to dashboard and CLI (#3687) 2019-12-11 10:02:37 -08:00
stream_client.go Introduce tap APIService, update `linkerd tap` (#3167) 2019-08-01 14:02:45 -07:00
test_helper.go Upgrade prometheus to v1.2.1 (#3541) 2019-12-11 15:26:16 -08:00
top_routes.go Allow custom cluster domains in remaining backends (#3278) 2019-08-27 10:01:36 -07:00
top_routes_test.go Add support for k8s 1.16 (#3364) 2019-09-04 09:59:55 -05:00