0

I want to create Jolt Specification in Update Attribute processor and use in JoltTransformer processor as an attribute like below.

nifi Update Attribute Component

enter image description here

I get this error in JoltTransformer: . "is invalid because of the specification not valid for the selected transformation. Reason being Jolt Specification will set during runtime.

enter image description here

Thanks for the help! Ani

Ani
  • 598
  • 5
  • 13
  • 29

1 Answers1

1

In NiFi-1.6.0 JoltTransformJson processor not accepting attributes in jolt specification property value.

We still need to keep literal jolt specification in property value.

Example: enter image description here

But Starting from NiFi-1.7.0 JoltTransformJson processor will be evaluated using flow file attributes and variable registry

  • we can use ${mapping} starting from NiFi-1.7.0
notNull
  • 30,258
  • 4
  • 35
  • 50
  • Shu, Thank you for your answer, is this true for EvaluateJsonPath processor as well. EvaluateJsonPath does not throw an error but does not evaluate the property. incoming json: { "indiv_id": "75008f47-99f5-4eb7-8c0e-cfb6ee550964", "first_name": "Ila", "last_Name": "Gallegos", "Address_1": 188, "Address_2": "FlorenceAvenue" } This is my expression $.${row_id} for property: hb_row_id But output is emptyString or just {} (when i put ticks like $.${'row_id'}) – Ani Jan 08 '19 at 17:35
  • @Ani, Yes, **EvaluateJsonPath** Processor will **`not evaluates flowfile attribute or variable Registry`** (checked in NiFi-1.8) also, we still needs to keep all the properties with literal values in it. i.e. `$.id`..etc. – notNull Jan 09 '19 at 13:50