Skip to content

Latest commit

 

History

History
36 lines (28 loc) · 811 Bytes

rule_format.md

File metadata and controls

36 lines (28 loc) · 811 Bytes

Rule Format

  • type (String): Supports 2 values based on the usage
    • RULE
    • DELETE

Rule Type

  • windowMinutes (Number): Data window required for this query. It will be used to expire data in the table
  • sqlQuery (String): SQL format query whuch needs to be executed to receive alerts
  • sinkExchangeKey (String): RMQ exchange key to which alert will be published
  • sinkRoutingKey (String): RMQ routing key for the corresponding exchange

DELETE Type

  • ruleId (String): Rule Id which needs to be deleted

Example Rule:

{
    "type": "RULE",
    "sqlQuery": "select * from TABLE",
    "windowMinutes": 1,
    "sinkExchangeKey": "rule-result-test",
    "sinkRoutingKey": "rule-result-test"
}

Example Delete RUle

{
    "ruleId": "<rule-id>",
    "type": "DELETE"
}