-
-
Notifications
You must be signed in to change notification settings - Fork 217
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[datadog-synthetics] Accept Datadog API output as input (#885)
- Loading branch information
Showing
7 changed files
with
123 additions
and
69 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
## Changes approximately v1.329.0 | ||
|
||
### API Schema accepted | ||
|
||
Test can now be defined using the Datadog API schema, meaning that the test definition | ||
returned by | ||
- `https://api.datadoghq.com/api/v1/synthetics/tests/api/{public_id}` | ||
- `https://api.datadoghq.com/api/v1/synthetics/tests/browser/{public_id}` | ||
|
||
can be directly used a map value (you still need to supply a key, though). | ||
|
||
You can mix tests using the API schema with tests using the old Terraform schema. | ||
You could probably get away with mixing them in the same test, but it is not recommended. | ||
|
||
### Default locations | ||
|
||
Previously, the default locations for Synthetics tests were "all" public locations. | ||
Now the default is no locations, in favor of locations being specified in each test configuration, | ||
which is more flexible. Also, since the tests are expensive, it is better to err on the side of | ||
too few test locations than too many. |
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
61 changes: 34 additions & 27 deletions
61
modules/datadog-synthetics/catalog/synthetics/examples/browser-test.yaml
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,38 @@ | ||
my-browser-test: | ||
name: "Browser Test" | ||
message: "Browser Test Failed" | ||
name: My Browser Test | ||
status: live | ||
type: browser | ||
subtype: http | ||
device_ids: | ||
- "laptop_large" | ||
tags: | ||
- "managed-by:Terraform" | ||
status: "live" | ||
request_definition: | ||
url: "CHANGEME" | ||
method: GET | ||
request_headers: | ||
Accept-Charset: "utf-8, iso-8859-1;q=0.5" | ||
Accept: "text/html" | ||
options_list: | ||
tick_every: 1800 | ||
no_screenshot: false | ||
follow_redirects: false | ||
config: | ||
request: | ||
method: GET | ||
headers: {} | ||
url: https://example.com/login | ||
setCookie: |- | ||
DatadogTest=true | ||
message: "My Browser Test Failed" | ||
options: | ||
device_ids: | ||
- chrome.laptop_large | ||
- edge.tablet | ||
- firefox.mobile_small | ||
ignoreServerCertificateError: false | ||
disableCors: false | ||
disableCsp: false | ||
noScreenshot: false | ||
tick_every: 86400 | ||
min_failure_duration: 0 | ||
min_location_failed: 1 | ||
retry: | ||
count: 2 | ||
interval: 10 | ||
count: 0 | ||
interval: 300 | ||
monitor_options: | ||
renotify_interval: 300 | ||
browser_step: | ||
- name: "Check current URL" | ||
type: assertCurrentUrl | ||
params: | ||
check: contains | ||
value: "CHANGEME" | ||
renotify_interval: 0 | ||
ci: | ||
executionRule: non_blocking | ||
rumSettings: | ||
isEnabled: false | ||
enableProfiling: false | ||
enableSecurityTesting: false | ||
locations: | ||
- aws:us-east-1 | ||
- aws:us-west-2 |
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
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
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
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