@@ -110,7 +110,7 @@ export interface CheckGroupProps {
110
110
/**
111
111
* Sets a retry policy for the group. Use RetryStrategyBuilder to create a retry policy.
112
112
*/
113
- retryStrategy ?: RetryStrategy
113
+ retryStrategy ?: RetryStrategy | null
114
114
/**
115
115
* Determines whether the checks in the group should run on all selected locations in parallel or round-robin.
116
116
* See https://www.checklyhq.com/docs/monitoring/global-locations/ to learn more about scheduling strategies.
@@ -143,7 +143,7 @@ export class CheckGroup extends Construct {
143
143
apiCheckDefaults : ApiCheckDefaultConfig
144
144
browserChecks ?: BrowserCheckConfig
145
145
multiStepChecks ?: MultiStepCheckConfig
146
- retryStrategy ?: RetryStrategy
146
+ retryStrategy ?: RetryStrategy | null
147
147
runParallel ?: boolean
148
148
alertSettings ?: AlertEscalation
149
149
useGlobalAlertSettings ?: boolean
@@ -163,7 +163,6 @@ export class CheckGroup extends Construct {
163
163
this . name = props . name
164
164
this . activated = props . activated
165
165
this . muted = props . muted
166
- this . doubleCheck = props . doubleCheck
167
166
this . tags = props . tags
168
167
this . runtimeId = props . runtimeId
169
168
this . locations = props . locations
@@ -185,6 +184,11 @@ export class CheckGroup extends Construct {
185
184
this . alertChannels = props . alertChannels ?? [ ]
186
185
this . localSetupScript = props . localSetupScript
187
186
this . localTearDownScript = props . localTearDownScript
187
+ // When `retryStrategy: null` and `doubleCheck: undefined`, we want to let the user disable all retries.
188
+ // The backend has a Joi default of `doubleCheck: true`, though, so we need special handling for this case.
189
+ this . doubleCheck = props . doubleCheck === undefined && props . retryStrategy === null
190
+ ? false
191
+ : props . doubleCheck
188
192
this . retryStrategy = props . retryStrategy
189
193
this . runParallel = props . runParallel
190
194
// `browserChecks` is not a CheckGroup resource property. Not present in synthesize()
0 commit comments