Support Questions

Find answers, ask questions, and share your expertise

Where does Nifi store templates?

Explorer

Can you help me to find where do Nifi stores templates?
I am running Nifi on a docker container.
PS: there is no dir under the folder conf.
Here is the WORKDIR:

Ghilani_0-1669718369646.png

 

1 ACCEPTED SOLUTION

Master Guru

@Ghilani 
NiFi stores Templates in the flow.xml.gz file.  the flow.xml.gz is just a compressed copy of dataflow(s) which reside inside NiFi's heap memory while NiFi is running.   It is not recommended to keep templates in your NiFi.  NiFi templates are also deprecated and will go away in next major release. It is recommended to use NiFi-registry to store version controlled flows.  If not using NiFi-Registry, Flow definitions should be downloaded instead of creating templates and stored safely somewhere outside of NiFi itself.

A flow definition can be downloaded by right clicking on a process group in NiFi and selecting "Download flow definition".  This json file will be generated of that flow and downloaded.  Flow definitions can be uploaded to NiFi by dragging the create Process Group icon to the canvas and selecting option to upload flow definition.

 

If you found that the provided solution(s) assisted you with your query, please take a moment to login and click Accept as Solution below each response that helped.

Thank you,

Matt

View solution in original post

1 REPLY 1

Master Guru

@Ghilani 
NiFi stores Templates in the flow.xml.gz file.  the flow.xml.gz is just a compressed copy of dataflow(s) which reside inside NiFi's heap memory while NiFi is running.   It is not recommended to keep templates in your NiFi.  NiFi templates are also deprecated and will go away in next major release. It is recommended to use NiFi-registry to store version controlled flows.  If not using NiFi-Registry, Flow definitions should be downloaded instead of creating templates and stored safely somewhere outside of NiFi itself.

A flow definition can be downloaded by right clicking on a process group in NiFi and selecting "Download flow definition".  This json file will be generated of that flow and downloaded.  Flow definitions can be uploaded to NiFi by dragging the create Process Group icon to the canvas and selecting option to upload flow definition.

 

If you found that the provided solution(s) assisted you with your query, please take a moment to login and click Accept as Solution below each response that helped.

Thank you,

Matt