Created on 09-06-202302:36 AM - edited on 09-06-202302:46 AM by VidyaSargur
LIMITATIONS OF TEMPLATES
If a user wants to change the flows using templates, i.e., downloading templates and uploading them back, then the following issues will occur:
The template will not preserve the state. It is not supposed to. The template is just a blueprint of the components, not their data.
New controller services will be created instead of using already existing ones, which is expected behavior in templates.
Templates will be unsupported in CFM 4.0/ NiFi 2.0 and there are not active improvements being done to them.
The better solution in this case will be to use flow definitions instead of templates. The steps to use flow definitions are:
Right-click on Process Group > Click on Download Flow Definition > select the option to download flow JSON with or without external controller services. “External” here means services referenced inside the PG, but existing at a higher level.
Then, if you import that flow definition (JSON) that has references to external services, it will not create a Controller service rather it will automatically select them from the higher level as long as there is only one available choice with the same name and type. Meaning if the parent level has two services with the same name and type, then it won’t know which one to select.