-
Notifications
You must be signed in to change notification settings - Fork 933
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 metrics for stopped instances #12639
Merged
tomponline
merged 10 commits into
canonical:main
from
simondeziel:12333-metrics-instances-only
Jan 18, 2024
Merged
Add metrics for stopped instances #12639
tomponline
merged 10 commits into
canonical:main
from
simondeziel:12333-metrics-instances-only
Jan 18, 2024
Conversation
This file contains 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
tomponline
reviewed
Dec 8, 2023
github-actions
bot
added
Documentation
Documentation needs updating
API
Changes to the REST API
labels
Dec 11, 2023
simondeziel
force-pushed
the
12333-metrics-instances-only
branch
from
January 8, 2024 19:01
e42971b
to
6f81b06
Compare
Just a small nit, the API extension should be the first commit |
simondeziel
force-pushed
the
12333-metrics-instances-only
branch
from
January 8, 2024 22:41
6f81b06
to
04429c7
Compare
@tomponline please take another look, thanks. |
@simondeziel needs a rebase please |
simondeziel
force-pushed
the
12333-metrics-instances-only
branch
from
January 18, 2024 14:28
04429c7
to
49e729d
Compare
Signed-off-by: Simon Deziel <[email protected]>
Signed-off-by: Simon Deziel <[email protected]>
This adds the running state to container metrics. The value will be either "RUNNING" or "STOPPED. Signed-off-by: Thomas Hipp <[email protected]>
This checks the running state when retrieving metrics. Warnings will only be shown if metrics cannot be retrieved for running containers. Also, if values are returned for stopped containers as well, these will also be included. Signed-off-by: Thomas Hipp <[email protected]>
This adds the running state to VM metrics. The value is hard-coded as "RUNNING" since metrics can only be retrieved from running VMs. That is because LXD needs to connect either to the agent or the QEMU monitor in order to get metrics. Signed-off-by: Thomas Hipp <[email protected]>
This adds support for filtering metrics based only on the project name. It will allow filtering metrics which are tied to a project but not to an instance. Signed-off-by: Thomas Hipp <[email protected]>
This extends the metrics filter to additionally filter samples by project only if there's no instance name. Signed-off-by: Thomas Hipp <[email protected]>
This adds the number of containers and VMs per project to the metrics. Signed-off-by: Thomas Hipp <[email protected]>
Signed-off-by: Thomas Hipp <[email protected]>
Signed-off-by: Simon Deziel <[email protected]>
simondeziel
force-pushed
the
12333-metrics-instances-only
branch
from
January 18, 2024 14:34
49e729d
to
a7655bc
Compare
@tomponline rebased (twice!), please take another look, thanks. |
tomponline
approved these changes
Jan 18, 2024
Thanks! |
3 tasks
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.
Thomas' PR #12476 without the
metrics: Add LXD server info
commit ece77a1This would fix #12333.