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

MetricMonitoredCommand #6873

Open
SufyanRizvi24 opened this issue Feb 7, 2025 · 4 comments
Open

MetricMonitoredCommand #6873

SufyanRizvi24 opened this issue Feb 7, 2025 · 4 comments
Assignees
Labels
documentation This is a problem with documentation. p2 This is a standard priority issue response-requested Waiting on additional info and feedback. Will move to \"closing-soon\" in 7 days. service-api This issue is due to a problem in a service API, not the SDK implementation.

Comments

@SufyanRizvi24
Copy link

Describe the issue

It would be nice to know if a particular metric is being monitored or not. Currently, the only way to check if a metric is being monitored is if we get datapoints for it using the GetMetricStatisticsCommand or the GetMetricDataCommand. Like, I want to check if my 5XX errors are being monitored, if there are no errors it states not enough data points which leads me to assume that it is not being monitored.
Hopefully someone has a solution.
Thanks!

Links

https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/cloudwatch/

@SufyanRizvi24 SufyanRizvi24 added documentation This is a problem with documentation. needs-triage This issue or PR still needs to be triaged. labels Feb 7, 2025
@zshzbh zshzbh self-assigned this Feb 7, 2025
@zshzbh zshzbh added p2 This is a standard priority issue and removed needs-triage This issue or PR still needs to be triaged. labels Feb 10, 2025
@zshzbh
Copy link
Contributor

zshzbh commented Feb 10, 2025

Hey @SufyanRizvi24 ,

I have forwarded your feedback to the service documentation team.

Thanks!
Maggie

@zshzbh zshzbh added the service-api This issue is due to a problem in a service API, not the SDK implementation. label Feb 10, 2025
@zshzbh
Copy link
Contributor

zshzbh commented Feb 11, 2025

Hey @SufyanRizvi24 ,

I just got back from service team -

Can you provide more info on what the you are trying to do?
if the '5XX errors' metric is a custom metric emitted using PutMetricData, you can emit a 0 datapoint in case you don't get any errors, that way you will always have datapoints for it.
If it's a vended metric such as Lambda Errors Count for example, you can use math expression Fill to fill with 0 when there are no datapoints.

@zshzbh zshzbh added the response-requested Waiting on additional info and feedback. Will move to \"closing-soon\" in 7 days. label Feb 11, 2025
@SufyanRizvi24
Copy link
Author

Thank you for your response.

I am trying to determine whether the HTTPCode_ELB_5XX_Count metric is actively monitored. According to the AWS documentation, this metric reports data points only when there is a nonzero value. Consequently, since my load balancer hasn't encountered any errors during the period I'm investigating, no data points are returned and I cannot flag the metric as being not monitored. How can I address this issue?

@github-actions github-actions bot removed the response-requested Waiting on additional info and feedback. Will move to \"closing-soon\" in 7 days. label Feb 13, 2025
@zshzbh
Copy link
Contributor

zshzbh commented Feb 17, 2025

Hey @SufyanRizvi24 ,

Could you please clarify what does that mean by "I cannot flag the metric as being not monitored"? If the you are creating an alarm, you can still create an alarm and set missing data as not breaching. If there is some other use-case, you can create a lambda and emit a metric themself on top of HTTPCode_ELB_5XX_Count.

@zshzbh zshzbh added the response-requested Waiting on additional info and feedback. Will move to \"closing-soon\" in 7 days. label Feb 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation This is a problem with documentation. p2 This is a standard priority issue response-requested Waiting on additional info and feedback. Will move to \"closing-soon\" in 7 days. service-api This issue is due to a problem in a service API, not the SDK implementation.
Projects
None yet
Development

No branches or pull requests

2 participants