This commit is contained in:
19
main.go
19
main.go
@@ -761,10 +761,21 @@ func main() {
|
||||
|
||||
func (s *server) listDynamicRules(ctx context.Context) ([]DynamicRule, error) {
|
||||
const q = `
|
||||
SELECT id, name, description, severity, channel, event_ids,
|
||||
match_field, match_operator, match_value,
|
||||
threshold_count, threshold_window_seconds, suppress_for_seconds,
|
||||
enabled, created_at, updated_at
|
||||
SELECT id,
|
||||
name,
|
||||
COALESCE(description, ''),
|
||||
severity,
|
||||
channel,
|
||||
event_ids,
|
||||
COALESCE(match_field, ''),
|
||||
COALESCE(match_operator, ''),
|
||||
COALESCE(match_value, ''),
|
||||
threshold_count,
|
||||
threshold_window_seconds,
|
||||
suppress_for_seconds,
|
||||
enabled,
|
||||
created_at,
|
||||
updated_at
|
||||
FROM detection_rules
|
||||
ORDER BY name ASC
|
||||
`
|
||||
|
||||
Reference in New Issue
Block a user