<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Upload multiple nifi templates at once in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/Upload-multiple-nifi-templates-at-once/m-p/315369#M226443</link>
    <description>&lt;P&gt;How do I upload multiple nifi templates at once?Nifi only allows to upload one single template/xml file at a time. How do I upload all the templates in&amp;nbsp; bulk?&lt;/P&gt;</description>
    <pubDate>Tue, 27 Apr 2021 11:22:14 GMT</pubDate>
    <dc:creator>syntax_</dc:creator>
    <dc:date>2021-04-27T11:22:14Z</dc:date>
    <item>
      <title>Upload multiple nifi templates at once</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Upload-multiple-nifi-templates-at-once/m-p/315369#M226443</link>
      <description>&lt;P&gt;How do I upload multiple nifi templates at once?Nifi only allows to upload one single template/xml file at a time. How do I upload all the templates in&amp;nbsp; bulk?&lt;/P&gt;</description>
      <pubDate>Tue, 27 Apr 2021 11:22:14 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Upload-multiple-nifi-templates-at-once/m-p/315369#M226443</guid>
      <dc:creator>syntax_</dc:creator>
      <dc:date>2021-04-27T11:22:14Z</dc:date>
    </item>
    <item>
      <title>Re: Upload multiple nifi templates at once</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Upload-multiple-nifi-templates-at-once/m-p/315958#M226650</link>
      <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/88091"&gt;@syntax_&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;NiFi does not provide a method for uploading templates in bulk.&amp;nbsp; &amp;nbsp;But anything you can do via the UI, you can also do via rest-api calls [1] through curl.&amp;nbsp; So you could script the bulk upload through rest-api external to NiFi's UI.&lt;BR /&gt;&lt;BR /&gt;I would strongly discourage bulk uploading templates to NiFi.&amp;nbsp; Templates should be uploaded as needed, instantiate to the canvas and then template deleted from NiFi.&amp;nbsp; &amp;nbsp;All uploaded templates even if not instantiated to the canvas become part of the flow.xml loaded in to heap memory.&amp;nbsp; So keeping a large number of templates uploaded to your NiFi can have a considerable impact on JVM heap memory usage because now you have not only your active flow on the canvas in memory, but also these templates.&lt;BR /&gt;&lt;BR /&gt;Additionally, In a NiFi cluster on startup the flow.xml.gz is uncompressed, loaded in to heap memory, and a flow fingerprint created on every node.&amp;nbsp; These flow fingerprints are then compared to make sure all nodes joining the cluster are running with the same flow.xml.&amp;nbsp; Since these templates can just add unnecessary size to the flow.xml.gz, this can impact startup times and flow fingerprint comparison time.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;A better approach is to get your reusable flow migrated into NiFi-Registry [2].&amp;nbsp; You can have 1 to many NiFi's all connect to a single NiFi-Registry where all your flows exist.&amp;nbsp; Then all you need to do is drag a process group to the canvas and select "import" which will allow you to select one of these flows from NiFi-Registry and add it to your canvas.&amp;nbsp; Now you have your flow without the additional impact on heap from having it in NiFi both as a template and as a dataflow on your canvas with easy access to load same flow over and over.&amp;nbsp; I encourage you to explore NiFi-Registry.&lt;/P&gt;&lt;P&gt;[1]&amp;nbsp;&lt;A href="http://nifi.apache.org/docs/nifi-docs/rest-api/index.html" target="_blank"&gt;http://nifi.apache.org/docs/nifi-docs/rest-api/index.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;[2]&amp;nbsp;&lt;A href="https://nifi.apache.org/registry.html" target="_blank"&gt;https://nifi.apache.org/registry.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you found this response helped with your query, please take a moment to login in and click accept on this solution.&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;/P&gt;&lt;P&gt;Matt&lt;/P&gt;</description>
      <pubDate>Thu, 06 May 2021 21:01:07 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Upload-multiple-nifi-templates-at-once/m-p/315958#M226650</guid>
      <dc:creator>MattWho</dc:creator>
      <dc:date>2021-05-06T21:01:07Z</dc:date>
    </item>
  </channel>
</rss>

