emqx_message_validation_schema.hocon 2.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. emqx_message_validation_schema {
  2. check_avro_type.desc:
  3. """Avro schema check"""
  4. check_avro_type.label:
  5. """Avro schema check"""
  6. check_avro_schema.desc:
  7. """Schema name to use during check."""
  8. check_avro_schema.label:
  9. """Schema name"""
  10. check_json_type.desc:
  11. """JSON schema check"""
  12. check_json_type.label:
  13. """JSON schema check"""
  14. check_json_schema.desc:
  15. """Schema name to use during check."""
  16. check_json_schema.label:
  17. """Schema name"""
  18. check_protobuf_type.desc:
  19. """Protobuf schema check"""
  20. check_protobuf_type.label:
  21. """Protobuf schema check"""
  22. check_protobuf_schema.desc:
  23. """Schema name to use during check."""
  24. check_protobuf_schema.label:
  25. """Schema name"""
  26. check_protobuf_message_name.desc:
  27. """Message name to use during check."""
  28. check_protobuf_message_name.label:
  29. """Message name"""
  30. check_sql_type.desc:
  31. """Use rule-engine's SQL to validate the message. SQL here is the same as in rule-engine,
  32. just with the different that the `FROM` clause must be omitted.
  33. A SQL statement which yields any value is considered successfully validated, otherwise failed.
  34. For example <code>SELECT payload.foo + payload.bar as sum WHERE sum > 0</code>
  35. validates that the sum of field `foo` and `bar` is a positive value."""
  36. check_sql_type.label:
  37. """SQL schema check"""
  38. check_sql_schema.desc:
  39. """Schema name to use during check."""
  40. check_sql_schema.label:
  41. """Schema name"""
  42. topics.desc:
  43. """A single topic filter or list of topic filters that this validation should validate."""
  44. topics.label:
  45. """Topic filter(s)"""
  46. name.desc:
  47. """The name for this validation. Must be unique among all validations. It must be a combination of alphanumeric characters and underscores, and cannot start with neither number nor an underscore."""
  48. name.desc:
  49. """Name"""
  50. strategy.desc:
  51. """How the validation should consider the checks to be successful.
  52. <code>all_pass</code>: All checks will be evaluated and must pass.
  53. <code>any_pass</code>: Any passing check will suffice. Stops at the first success."""
  54. strategy.desc:
  55. """Strategy"""
  56. failure_action.desc:
  57. """How to proceed if the validation fails.
  58. <code>drop</code>: The offending message is simply dropped without further processing.
  59. <code>disconnect</code>: The message is not published, and the publishing client is disconnected.
  60. <code>ignore</code>: Only the failure is logged and traced. No other action is taken."""
  61. failure_action.label:
  62. """Failure action"""
  63. log_failure_at.desc:
  64. """Log level at which failures will be logged."""
  65. log_failure_at.label:
  66. """Failure log level"""
  67. checks.desc:
  68. """Checks that will be performed during validation. They are evaluated in the same order as defined."""
  69. checks.label:
  70. """Checks"""
  71. }