linkerd check sends params on version check#1642
Merged
Conversation
The `linkerd check` parameter hits https://versioncheck.linkerd.io/version.json to check for the latest Linkerd version. This loses information, as that endpoint is intended to record current version, uuid, and source. Modify `linkerd check` to set `version`, `uuid`, and `source` parameters when performing a version check. Part of #1604. Signed-off-by: Andrew Seigner <[email protected]>
adleong
reviewed
Sep 14, 2018
| hc.latestVersion = hc.VersionOverride | ||
| } else { | ||
| hc.latestVersion, err = version.GetLatestVersion() | ||
| // The UUID is only known to the web process. At some point we may want |
Member
There was a problem hiding this comment.
I think we could put it on an annotation on the control plane namespace object. This would make it easy to retrieve my the cli.
Member
Author
There was a problem hiding this comment.
Yeah, an annotation on the namespace seems like a better place to store this. I'd like to make that change as part of a larger refactor, to centralize UUID storage/retrieval, and version checking. Filed #1646 to track this.
Signed-off-by: Andrew Seigner <[email protected]>
klingerf
approved these changes
Sep 14, 2018
pkg/healthcheck/healthcheck.go
Outdated
| if container.Name == "web" { | ||
| for _, arg := range container.Args { | ||
| if strings.HasPrefix(arg, "-uuid=") { | ||
| uuid = arg[len("-uuid="):] |
Contributor
There was a problem hiding this comment.
TIOLI, since you're using HasPrefix to check the arg, you might as well use TrimPrefix to strip it.
if strings.HasPrefix(arg, "-uuid=") {
uuid = strings.TrimPrefix(arg, "-uuid=")
}
Signed-off-by: Andrew Seigner <[email protected]>
zachalbert
added a commit
to zachalbert/linkerd2
that referenced
this pull request
Sep 15, 2018
* master: Move more info from the tap table into the expanded row (linkerd#1641) `linkerd check` sends params on version check (linkerd#1642) Bikeshed the tap and top icons (linkerd#1637) Add link to tap each row in top table (linkerd#1643) Bump default check retry time to 5 minutes (linkerd#1645) Make wait=true a default option for check and dashboard (linkerd#1640) Add version check to Grafana dashboard (linkerd#1638) Add data plane check for metrics Prometheus (linkerd#1635)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The
linkerd checkparameter hitshttps://versioncheck.linkerd.io/version.json to check for the latest
Linkerd version. This loses information, as that endpoint is intended to
record current version, uuid, and source.
Modify
linkerd checkto setversion,uuid, andsourceparameters when performing a version check.
Part of #1604.
Signed-off-by: Andrew Seigner [email protected]