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

[datadog_synthetics_test] Add validation on synthetics test header #2469

Merged

Conversation

HantingZhang2
Copy link
Contributor

@HantingZhang2 HantingZhang2 commented Jun 28, 2024

The synthetics resource now validates that the provided headers don't have new line characters
fix #2462

@HantingZhang2 HantingZhang2 requested a review from a team as a code owner June 28, 2024 16:40
@HantingZhang2 HantingZhang2 changed the title Adds validation on synthetics test header [datadog_synthetics_test] Adds validation on synthetics test header Jun 28, 2024
@HantingZhang2 HantingZhang2 changed the title [datadog_synthetics_test] Adds validation on synthetics test header [datadog_synthetics_test] add validation on synthetics test header Jun 28, 2024
datadog/internal/validators/validators.go Outdated Show resolved Hide resolved
datadog/resource_datadog_synthetics_test_.go Outdated Show resolved Hide resolved
buraizu
buraizu previously approved these changes Jun 28, 2024
@HantingZhang2 HantingZhang2 changed the title [datadog_synthetics_test] add validation on synthetics test header [datadog_synthetics_test] Add validation on synthetics test header Jul 1, 2024
etnbrd
etnbrd previously approved these changes Jul 1, 2024
Copy link
Contributor

@etnbrd etnbrd left a comment

Choose a reason for hiding this comment

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

LGTM modulo getting back the documentation as mentioned by @nkzou.

datadog/internal/validators/validators.go Outdated Show resolved Hide resolved
@HantingZhang2 HantingZhang2 dismissed stale reviews from etnbrd and buraizu via 6e18dcd July 1, 2024 16:33
@HantingZhang2 HantingZhang2 merged commit 7df937b into master Jul 2, 2024
10 checks passed
@HantingZhang2 HantingZhang2 deleted the hzhang-add-validation-for-synthetics-test-header branch July 2, 2024 11:21
bharling pushed a commit to bharling/terraform-provider-datadog that referenced this pull request Jul 8, 2024
…ataDog#2469)

* Adds validation

* update docs

* use validateFunc and expand validation
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Synthetic test fails with INVALID_CHAR_IN_HEADER if entry in request_headers comes from data.local_file
4 participants