Search code examples
rabbitmqapache-nifiamqp

Nifi AmqpConsumer get amqp$headers attribute


AmqpConsumer fetch the amqp data from given queue and put the flow.

Amqp data header value set in amqp$headers attributes.

So I tried to get this attribute by updateAttribute processor and using referance, but it was given an error.

enter image description here

The data like as above. But I can not reach as below by updateAttribute.

enter image description here

How can set the amqp$headers in flow to header attribute.


Solution

  • Your syntax for referencing attributes is wrong, generally it would be ${amqp$headers}, but in your case, since you have a '$' in the attribute name, you reference it like ${'amqp$headers'}.

    It should look like this