Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add metric to track number ssh connect attempts #11240

Merged
merged 10 commits into from
Mar 24, 2022

Conversation

rcanderson23
Copy link
Contributor

This adds the metric teleport_connect_to_node_attempts_total

# HELP teleport_connect_to_node_attempts_total Number of ssh connect attempts
# TYPE teleport_connect_to_node_attempts_total counter
teleport_connect_to_node_attempts_total 4

This is added so that we can track percentage of successful connections as we already track failed attempts with failed_connect_to_node_attempts_total

Copy link
Collaborator

@zmb3 zmb3 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm accustomed to seeing related metrics like this have names that are more similar.

I recognize we're limited by the original metric, but ideally we would have something like:

teleport_connect_to_node_attempts_failed
teleport_connect_to_node_attempts_total

Since we don't want to change the original metric, I wonder if we could at least update the Help field or the docs so that these metrics mention each other.

lib/srv/regular/proxy.go Outdated Show resolved Hide resolved
@russjones russjones added the cloud Cloud label Mar 18, 2022
@rcanderson23
Copy link
Contributor Author

Updated the Help on both metrics as well as the docs to point to each other for usage and indicate they are linked.

Copy link
Contributor

@ptgott ptgott left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left a couple of very minor nits.

docs/pages/setup/reference/metrics.mdx Outdated Show resolved Hide resolved
docs/pages/setup/reference/metrics.mdx Outdated Show resolved Hide resolved
lib/srv/regular/proxy.go Outdated Show resolved Hide resolved
lib/srv/regular/proxy.go Outdated Show resolved Hide resolved
@rcanderson23 rcanderson23 enabled auto-merge (squash) March 23, 2022 13:35
@rcanderson23 rcanderson23 merged commit 4054c79 into master Mar 24, 2022
@rcanderson23 rcanderson23 deleted the carson/ssh-connect-attempts branch March 24, 2022 20:34
rcanderson23 added a commit that referenced this pull request Mar 31, 2022
* add ssh connect attempts metric

* fix help message wording

Co-authored-by: Paul Gottschling <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants