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

Modifies since_value's validation to match rest API's requirements #144

Merged
merged 9 commits into from
Jul 10, 2019

Conversation

nicoleyson
Copy link
Contributor

@nicoleyson nicoleyson commented Jun 7, 2019

Issue

The rest API asserts that since_value is the timeframe (in minutes) in which to evaluate the specified NRQL query. since_value must be between 1 and 20.
However, the provider does not allow the number to be above 5.

New Relic Documentation

nrql[since_value] https://docs.newrelic.com/docs/alerts/rest-api-alerts/new-relic-alerts-rest-api/alerts-conditions-api-field-names

For @SuperBadCode who said he needs it.
Found out after the fact that it resolves #131

Rationale for custom ValidateFunc

It appears as though the newrelic API expects since_value to be a string instead of an int which prevents the use of validate.IntBetween

@ghost ghost added size/XS documentation Improvements or additions to documentation labels Jun 7, 2019
Copy link

@ddebko ddebko left a comment

Choose a reason for hiding this comment

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

This is what I need.

Copy link

@mikeliao mikeliao left a comment

Choose a reason for hiding this comment

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

Code review.

Copy link

@ghost ghost left a comment

Choose a reason for hiding this comment

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

Found some fixes!

P.S. share your ideas, feedbacks or issues with us at https://github.com/fixmie/feedback (this message will be removed after the beta stage).

@paultyng paultyng merged commit 8aae17f into newrelic:master Jul 10, 2019
@sanderblue sanderblue mentioned this pull request Nov 6, 2019
kidk pushed a commit to aminoz007/terraform-provider-newrelic that referenced this pull request Oct 12, 2021
…ation

Modifies since_value's validation to match rest API's requirements
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support for newrelic_nrql_ alert_condition "since_value" values greater than 5
4 participants