Skip to content

Commit

Permalink
fix composite alerts
Browse files Browse the repository at this point in the history
  • Loading branch information
mattcarmody committed Jan 3, 2024
1 parent 7c39eed commit 5386279
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 4 deletions.
2 changes: 1 addition & 1 deletion lightstep/resource_alert.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ func getCompositeAlertFromUnifiedConditionResourceData(compositeAlertIn *client.
if subAlertIn.Expression.NoDataDurationMs != nil {
subAlertExpressionMap["no_data_duration_ms"] = subAlertIn.Expression.NoDataDurationMs
}
subAlerts = append(subAlerts, map[string]interface{}{})
subAlerts = append(subAlerts, subAlertExpressionMap)
}

return []map[string][]map[string]interface{}{{
Expand Down
3 changes: 0 additions & 3 deletions lightstep/resource_metric_condition.go
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,6 @@ func getThresholdSchemaMap() map[string]*schema.Schema {
"critical_duration_ms": {
Type: schema.TypeInt,
Optional: true,
Default: false,
Description: "Critical threshold must be breached for this duration before the status changes.",
},
"warning": {
Expand All @@ -352,7 +351,6 @@ func getThresholdSchemaMap() map[string]*schema.Schema {
"warning_duration_ms": {
Type: schema.TypeInt,
Optional: true,
Default: false,
Description: "Critical threshold must be breached for this duration before the status changes.",
},
}
Expand Down Expand Up @@ -437,7 +435,6 @@ func getCompositeSubAlertExpressionResource() *schema.Resource {
"no_data_duration_ms": {
Type: schema.TypeInt,
Optional: true,
Default: false,
Description: "No data must be seen for this duration before the status changes.",
},
"operand": {
Expand Down

0 comments on commit 5386279

Please sign in to comment.