-
Notifications
You must be signed in to change notification settings - Fork 1
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 support for CRUD of holidays to client #5
Merged
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
sd2k
force-pushed
the
add-holiday-support
branch
from
January 4, 2023 11:45
b5fd232
to
101b750
Compare
sd2k
added a commit
to grafana/terraform-provider-grafana
that referenced
this pull request
Jan 4, 2023
Note that holidays can be created and added to jobs, but not vice versa, despite the API supporting it. This is because the API would return an updated value for the holiday's `jobs` field if we exposed it via Terraform, and we have no way of updating that from the job resource's CreateContext (as far as I'm aware). NOTE: this currently depends on an unreleased version of the machine-learning-go-client repo; once grafana/machine-learning-go-client#5 is merged, I'll adjust this PR and mark it ready for review.
sd2k
added a commit
to grafana/terraform-provider-grafana
that referenced
this pull request
Jan 4, 2023
Note that holidays can be created and added to jobs, but not vice versa, despite the API supporting it. This is because the API would return an updated value for the holiday's `jobs` field if we exposed it via Terraform, and we have no way of updating that from the job resource's CreateContext (as far as I'm aware). NOTE: this currently depends on an unreleased version of the machine-learning-go-client repo; once grafana/machine-learning-go-client#5 is merged, I'll adjust this PR and mark it ready for review.
sd2k
added a commit
to grafana/terraform-provider-grafana
that referenced
this pull request
Jan 4, 2023
Note that holidays can be created and added to jobs, but not vice versa, despite the API supporting it. This is because the API would return an updated value for the holiday's `jobs` field if we exposed it via Terraform, and we have no way of updating that from the job resource's CreateContext (as far as I'm aware). NOTE: this currently depends on an unreleased version of the machine-learning-go-client repo; once grafana/machine-learning-go-client#5 is merged, I'll adjust this PR and mark it ready for review.
sd2k
added a commit
to grafana/terraform-provider-grafana
that referenced
this pull request
Jan 4, 2023
Note that holidays can be created and added to jobs, but not vice versa, despite the API supporting it. This is because the API would return an updated value for the holiday's `jobs` field if we exposed it via Terraform, and we have no way of updating that from the job resource's CreateContext (as far as I'm aware). NOTE: this currently depends on an unreleased version of the machine-learning-go-client repo; once grafana/machine-learning-go-client#5 is merged, I'll adjust this PR and mark it ready for review.
csmarchbanks
reviewed
Jan 4, 2023
sd2k
force-pushed
the
add-holiday-support
branch
from
January 4, 2023 22:54
101b750
to
05646c0
Compare
csmarchbanks
reviewed
Jan 4, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One small thing then 👍
csmarchbanks
reviewed
Jan 4, 2023
sd2k
force-pushed
the
add-holiday-support
branch
from
January 5, 2023 08:17
05646c0
to
98deec5
Compare
This PR adds support for the new Holidays feature of Grafana ML to the client. The client supports CRUD of holidays as well as linking jobs to holidays using the LinkJobHolidays method.
sd2k
force-pushed
the
add-holiday-support
branch
from
January 5, 2023 08:18
98deec5
to
8dcd5f4
Compare
csmarchbanks
approved these changes
Jan 5, 2023
sd2k
added a commit
to grafana/terraform-provider-grafana
that referenced
this pull request
Jan 5, 2023
Note that holidays can be created and added to jobs, but not vice versa, despite the API supporting it. This is because the API would return an updated value for the holiday's `jobs` field if we exposed it via Terraform, and we have no way of updating that from the job resource's CreateContext (as far as I'm aware). NOTE: this currently depends on an unreleased version of the machine-learning-go-client repo; once grafana/machine-learning-go-client#5 is merged, I'll adjust this PR and mark it ready for review.
julienduchesne
pushed a commit
to grafana/terraform-provider-grafana
that referenced
this pull request
Jan 10, 2023
Note that holidays can be created and added to jobs, but not vice versa, despite the API supporting it. This is because the API would return an updated value for the holiday's `jobs` field if we exposed it via Terraform, and we have no way of updating that from the job resource's CreateContext (as far as I'm aware). NOTE: this currently depends on an unreleased version of the machine-learning-go-client repo; once grafana/machine-learning-go-client#5 is merged, I'll adjust this PR and mark it ready for review.
julienduchesne
pushed a commit
to grafana/terraform-provider-grafana
that referenced
this pull request
Jan 10, 2023
* Add support for Machine Learning holidays Note that holidays can be created and added to jobs, but not vice versa, despite the API supporting it. This is because the API would return an updated value for the holiday's `jobs` field if we exposed it via Terraform, and we have no way of updating that from the job resource's CreateContext (as far as I'm aware). NOTE: this currently depends on an unreleased version of the machine-learning-go-client repo; once grafana/machine-learning-go-client#5 is merged, I'll adjust this PR and mark it ready for review. * Fix docs for machine learning holiday resource * Handle 404s when reading ML jobs/holidays
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.
This PR adds support for the new Holidays feature of
Grafana ML to the client. The client supports CRUD
of holidays as well as linking jobs to holidays using
the LinkJobHolidays method.