-
Notifications
You must be signed in to change notification settings - Fork 389
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
[datadog_logs_custom_pipeline] Add tags and description to logs pipelines #2773
base: master
Are you sure you want to change the base?
[datadog_logs_custom_pipeline] Add tags and description to logs pipelines #2773
Conversation
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.
Looks good for Logs Access ✅
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.
Could you please add a PR description? 😄 I am not familiar with this part of the code so don't really understand what change is being made, why we are making this change and why my team needs to review it.
EDIT: edited out the part about linking the jira ticket since apparently github is smart enough to pick it up from the PR title
@@ -63,6 +63,21 @@ func dataSourceDatadogLogsPipelines() *schema.Resource { | |||
Type: schema.TypeBool, | |||
Computed: true, | |||
}, | |||
"tags": { | |||
Description: "Tags of the pipeline", | |||
Type: schema.TypeList, |
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.
Type: schema.TypeList, | |
Type: schema.TypeSet, |
"is_enabled": {Type: schema.TypeBool, Optional: true}, | ||
"name": {Type: schema.TypeString, Required: true}, | ||
"is_enabled": {Type: schema.TypeBool, Optional: true}, | ||
"tags": {Type: schema.TypeList, Optional: true, Elem: &schema.Schema{Type: schema.TypeString}}, |
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.
"tags": {Type: schema.TypeList, Optional: true, Elem: &schema.Schema{Type: schema.TypeString}}, | |
"tags": {Type: schema.TypeSet, Optional: true, Elem: &schema.Schema{Type: schema.TypeString}}, |
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.
@skarimo if we use a set isn't it a risk of changing the order of the tags?
The set has the advantage of unicity but the pipelines API already does dedup if necessary
This PR adds the tags and description for pipelines to the Datadog Terraform provider.
The provider interprets the Terraform files and uses the Go SDK to invoke the Datadog public API to change the state of the logs pipelines and make them match the state expressed in the Terraform files. This PR makes it read and writes the tags and description of logs pipelines from the public API.
LOGSC-2078