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

feat: Add conditions to monv2 action rules #178

Merged
merged 3 commits into from
Dec 10, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions client/internal/meta/operation/monitorv2.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,10 @@ fragment MonitorV2SearchResult on MonitorV2SearchResult {
fragment MonitorV2ActionRule on MonitorV2ActionRule {
actionID
levels
# @genqlient(flatten: true)
conditions {
...MonitorV2ComparisonExpression
}
sendEndNotifications
sendRemindersInterval
# @genqlient(flatten: true)
Expand All @@ -175,6 +179,25 @@ fragment MonitorV2ActionDefinition on MonitorV2ActionDefinition {
}
}

fragment MonitorV2ComparisonExpression on MonitorV2ComparisonExpression {
# @genqlient(flatten: true)
compareTerms {
...MonitorV2ComparisonTerm
}
# subExpressions/operator are not used by the UI so we won't support them here yet either
}

fragment MonitorV2ComparisonTerm on MonitorV2ComparisonTerm {
# @genqlient(flatten: true)
comparison {
...MonitorV2Comparison
}
# @genqlient(flatten: true)
column {
...MonitorV2Column
}
}

# @genqlient(for: "MonitorV2Input.iconUrl", omitempty: true)
# @genqlient(for: "MonitorV2Input.description", omitempty: true)
# @genqlient(for: "MonitorV2Input.managedById", omitempty: true)
Expand Down
125 changes: 125 additions & 0 deletions client/meta/genqlient.generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 0 additions & 3 deletions docs/data-sources/monitor_v2.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
page_title: "observe_monitor_v2 Data Source - terraform-provider-observe"
subcategory: ""
description: |-
NOTE: This feature is still in development. It is not meant for customer use yet.
Monitors provide a configurable way to alert when conditions about incoming data
are matched. These alerts can optionally also be forwarded to notification receivers
like email and webhooks using shared or single-monitor actions to configure the
Expand All @@ -12,8 +11,6 @@ description: |-

# observe_monitor_v2 (Data Source)

NOTE: This feature is still in development. It is not meant for customer use yet.

Monitors provide a configurable way to alert when conditions about incoming data
are matched. These alerts can optionally also be forwarded to notification receivers
like email and webhooks using shared or single-monitor actions to configure the
Expand Down
Loading
Loading