is it possible to do validation of incoming json via http Processor with
Json Schema in nifi?

Example Json:

{
  name: "Test",
  timestamp: 1463499695,
  tags: {
       "host": "Test_1",
       "ip" : "1.1.1.1"
  },
  fields: {
    "cpu": 10.2,
    "load: : 15.6
  }
}

JSON schema:

"type": "object",
"required": ["name", "tags", "timestamp", "fields"],
"properties": {
    "name": {"type": "string"},
    "timestamp": {"type": "integer"},
    "tags": {"type": "object", "items": {"type": "string"}},
    "fields": { "type": "object"}
}

Reply via email to