Ultralight, security-first service mesh for Kubernetes. Main repo for Linkerd 2.x.
Go to file
Matei David e798b33e2e
Add peer label to TCP read and write stat queries (#5903)
Add peer label to TCP read and write stat queries

Closes #5693

### Tests
---

After refactoring, `linkerd viz stat` behaves the same way (I haven't checked gateways or routes).

```
$ linkerd viz stat deploy/web -n emojivoto -o wide

NAME   MESHED   SUCCESS      RPS   LATENCY_P50   LATENCY_P95   LATENCY_P99   TCP_CONN   READ_BYTES/SEC   WRITE_BYTES/SEC
web       1/1    91.91%   2.3rps           2ms           4ms           5ms          3         185.3B/s         5180.0B/s

# same value as before, latency seems to have dropped

time="2021-03-22T18:19:44Z" level=debug msg="Query request:\n\tsum(increase(tcp_write_bytes_total{deployment=\"web\", direction=\"inbound\", namespace=\"emojivoto\", peer=\"src\"}[1m])) by (namespace, deployment)"

time="2021-03-22T18:19:44Z" level=debug msg="Query request:\n\tsum(increase(tcp_read_bytes_total{deployment=\"web\", direction=\"inbound\", namespace=\"emojivoto\", peer=\"src\"}[1m])) by (namespace, deployment)"

# queries show the peer label
---

$ linkerd viz stat deploy/web -n emojivoto --from deploy/vote-bot -o wide

NAME   MESHED   SUCCESS      RPS   LATENCY_P50   LATENCY_P95   LATENCY_P99   TCP_CONN   READ_BYTES/SEC   WRITE_BYTES/SEC
web       1/1    93.16%   1.9rps           3ms           4ms           4ms          1        4503.4B/s          153.1B/s


# stats same as before except for latency which seems to have dropped a bit

time="2021-03-22T18:22:10Z" level=debug msg="Query request:\n\tsum(increase(tcp_write_bytes_total{deployment=\"vote-bot\", direction=\"outbound\", dst_deployment=\"web\", dst_namespace=\"emojivoto\", namespace=\"emojivoto\", peer=\"dst\"}[1m])) by (dst_namespace, dst_deployment)"

time="2021-03-22T18:22:10Z" level=debug msg="Query request:\n\tsum(increase(tcp_read_bytes_total{deployment=\"vote-bot\", direction=\"outbound\", dst_deployment=\"web\", dst_namespace=\"emojivoto\", namespace=\"emojivoto\", peer=\"dst\"}[1m])) by (dst_namespace, dst_deployment)"

# queries show the right label
```

Signed-off-by: mateiidavid <matei.david.35@gmail.com>
2021-03-26 13:36:30 -04:00
.github Add darwin-arm64 CLI binary to list of uploads in release.yml (#5929) 2021-03-19 14:14:58 -05:00
bin Update bin/web script to work with metrics-api (#5944) 2021-03-24 15:51:22 -04:00
charts Fix parsing of ignoreInboundPorts field (#5876) 2021-03-09 15:32:20 -05:00
cli checks: make hintBaseURL configurable (#5921) 2021-03-23 23:16:56 +05:30
cni-plugin fix: issues affecting code quality (#5827) 2021-03-15 17:35:40 -04:00
controller Ignore pods in "Terminating" when watching IP addresses. (#5940) 2021-03-24 18:21:42 +05:30
grafana Include viz components in Prom scrapes, fix Linkerd Health charts (#5656) 2021-02-04 09:40:23 -05:00
jaeger add installNamespace toggle for jaeger extension 2021-03-24 12:09:46 +05:30
multicluster helm: add NOTES.txt for extension charts (#5870) 2021-03-09 15:31:18 -05:00
pkg checks: make hintBaseURL configurable (#5921) 2021-03-23 23:16:56 +05:30
proto Simplify SelfCheck API (#5665) 2021-02-05 10:13:45 -05:00
proxy-identity Improve comments in proxy-identity (#5420) 2020-12-23 08:28:41 -08:00
test Get rid of `CheckDeployments()` in integration tests (#5942) 2021-03-23 13:53:38 -05:00
testutil Get rid of `CheckDeployments()` in integration tests (#5942) 2021-03-23 13:53:38 -05:00
viz Add peer label to TCP read and write stat queries (#5903) 2021-03-26 13:36:30 -04:00
web Update bin/web script to work with metrics-api (#5944) 2021-03-24 15:51:22 -04:00
.dockerignore Migrate CI to docker buildx and other improvements (#4765) 2020-07-22 14:27:45 -05:00
.editorconfig Add PodDisruptionBudgets to control plane (#5398) (#5406) 2021-01-06 09:19:15 -05:00
.gcp.json.enc Add docker builds and integration tests to CI (#1303) 2018-07-11 14:01:42 -07:00
.gitattributes remove the duplicate word (#3385) 2019-09-04 20:13:55 -07:00
.gitignore service profile generation work offline using --ignore-cluster (#5482) 2021-01-09 10:23:25 -08:00
.golangci.yml Upgrade golangci-lint to v1.23.8 (#4181) 2020-03-18 09:13:19 -05:00
.helmdocsignore Add automatic readme generation for charts (#5316) 2020-12-02 14:37:45 -05:00
.markdownlint.yaml Lint all markdown files in CI (#4402) 2020-05-19 23:03:50 -07:00
.proxy-version proxy: v2.139.0 (#5923) 2021-03-18 11:45:04 -07:00
ADOPTERS.md Add Personio to the adopters list (#5957) 2021-03-26 09:52:15 -05:00
BUILD.md Update BUILD.md (#5869) 2021-03-11 12:02:06 -05:00
CHANGES.md edge-21.3.4 (#5950) 2021-03-25 12:00:46 +05:30
CODE_OF_CONDUCT.md Lint all markdown files (#4403) 2020-05-19 09:59:26 -07:00
CONTRIBUTING.md Update CI and docs to reference `main` branch (#4662) 2020-06-24 12:39:22 -07:00
DCO Add contributing doc and DCO file (#88) 2017-12-22 14:54:27 -08:00
Dockerfile-debug Update debian base images to buster-20210208-slim (#5750) 2021-02-16 08:39:53 -08:00
Dockerfile-proxy update go.mod and docker images to go 1.16.2 (#5890) 2021-03-15 11:20:16 -05:00
EXTENSIONS.md Add EXTENSIONS.md (#5692) 2021-03-03 10:33:47 -08:00
GOVERNANCE.md Update Linkerd Governance (#5477) 2021-01-13 11:51:15 -08:00
LICENSE Introducing Conduit, the ultralight service mesh 2017-12-05 00:24:55 +00:00
MAINTAINERS.md Add Tarun to Maintainers (#5765) 2021-02-17 10:06:25 -08:00
README.md reference SECURITY.md from README.md (#5918) 2021-03-18 10:13:06 -07:00
SECURITY.md Spelling (#4872) 2020-08-12 21:59:50 -07:00
SECURITY_AUDIT.pdf Add security audit (#3008) 2019-06-28 16:04:41 -07:00
STEERING.md add STEERING.md (#5607) 2021-01-27 09:39:32 -06:00
TEST.md Update BUILD.md (#5869) 2021-03-11 12:02:06 -05:00
go.mod update go.mod and docker images to go 1.16.2 (#5890) 2021-03-15 11:20:16 -05:00
go.sum Rabbitmq integration tests. (#5757) 2021-03-15 15:40:28 +05:30
tools.go Upgrade to client-go 0.17.4 and smi-sdk-go 0.3.0 (#4221) 2020-04-01 10:07:23 -07:00

README.md

Linkerd

Linkerd

CII Best Practices GitHub Actions Status GitHub license Go Report Card Slack Status

🎈 Welcome to Linkerd! 👋

Linkerd is an ultralight, security-first service mesh for Kubernetes. Linkerd adds critical security, observability, and reliability features to your Kubernetes stack with no code change required.

Linkerd is a Cloud Native Computing Foundation (CNCF) project.

Repo layout

This is the primary repo for the Linkerd 2.x line of development.

The complete list of Linkerd repos is:

Quickstart and documentation

You can run Linkerd on any modern Kubernetes cluster in a matter of seconds. See the Linkerd Getting Started Guide for how.

For more comprehensive documentation, start with the Linkerd docs. (The doc source code is available in the website repo.)

Working in this repo

BUILD.md includes general information on how to work in this repo.

We ❤️ pull requests! See CONTRIBUTING.md for info on contributing changes.

Get involved

Community meetings

We host regular online meetings for contributors, adopters, maintainers, and anyone else interested to connect in a synchronous fashion. These meetings usually take place the last Thursday of the month at 9am Pacific / 4pm UTC.

We're a friendly group, so please feel free to join us!

Steering Committee meetings

We host regular online meetings for the Linkerd Steering Committee. All are welcome to attend, but audio and video participation is limited to Steering Committee members and maintainers. These meetings are currently scheduled on an ad-hoc basis and announced on the linkerd-users mailing list.

Code of Conduct

This project is for everyone. We ask that our users and contributors take a few minutes to review our Code of Conduct.

Security

See SECURITY.md for our security policy, including how to report vulnerabilities.

A third party security audit was performed by Cure53 in June 2019. You can see the full report here.

License

Copyright 2021 the Linkerd Authors. All rights reserved.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use these files except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.