<?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 Re: How to map/select controller service in processor after importing/creating  controller service using Nifi toolkit in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/How-to-map-select-controller-service-in-processor-after/m-p/291292#M215402</link>
    <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/75149"&gt;@anil35759&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you create a NiFi template that includes a NiFi processor that references a controller service, that controller service will be included in the generated template.&amp;nbsp; So if you import and instantiate that template on to the canvas of another NiFi, the controller service will be added as well and be associated with the processor instantiate from that same template.&lt;/P&gt;&lt;P&gt;&lt;A href="https://nifi.apache.org/docs/nifi-docs/html/user-guide.html#templates" target="_blank"&gt;https://nifi.apache.org/docs/nifi-docs/html/user-guide.html#templates&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So I am not clear on why you need to import the controller service separately via the toolkit.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Controller services are not mapped to processors.&amp;nbsp; The association happens from the processor side.&amp;nbsp; &amp;nbsp;The processor is mapped to a specific controller service via the controller services assigned uuid.&lt;BR /&gt;&lt;BR /&gt;Keep in mind that anything you can do within the NiFi Ui can also be accomplished using NiFi rest-api endpoints.&amp;nbsp; Using your browsers developer tools to capture the requests as you make them through the NiFi UI is a great way to learn how to interact with NiFi rest-api endpoints.&amp;nbsp; The rest-api endpoints specific to your NiFi release version can be found under help within your install.&lt;BR /&gt;Here are the Apache NiFi rest-api docs for the latest Apache release version:&lt;BR /&gt;&lt;A href="https://nifi.apache.org/docs/nifi-docs/rest-api/index.html" target="_blank"&gt;https://nifi.apache.org/docs/nifi-docs/rest-api/index.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Essentially what you need to do here is to update the processor configuration to reference the UUID of whichever controller service you want it to use.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;curl 'http://&amp;lt;nifi-hostname&amp;gt;:&amp;lt;nifi-port&amp;gt;/nifi-api/processors/b10fd083-0170-1000-0000-00007f7c905f' -X PUT --data-binary '{"component":{"id":"b10fd083-0170-1000-0000-00007f7c905f","name":"ExecuteSQL","config":{"concurrentlySchedulableTaskCount":"1","schedulingPeriod":"0 sec","executionNode":"ALL","penaltyDuration":"30 sec","yieldDuration":"1 sec","bulletinLevel":"WARN","schedulingStrategy":"TIMER_DRIVEN","comments":"","autoTerminatedRelationships":[],"properties":{"Database Connection Pooling Service":"e60cb24c-95c5-3a97-bcb9-9e537006317d"}},"state":"STOPPED"},"revision":{"clientId":"affea95c-0170-1000-988b-73bf756785b3","version":2},"disconnectedNodeAcknowledged":false}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So you'll notice from above example, I am updating a processor's (ExecuteSQL) configuration so that the Database Connection Pooling Service is mapped to the UUID of my DBCPConnectionPool controller service's uuid (e60cb24c-95c5-3a97-bcb9-9e537006317d).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Note:&amp;nbsp; The "clientId" string can be anything.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hope this helps,&lt;/P&gt;&lt;P&gt;Matt&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 06 Mar 2020 18:28:41 GMT</pubDate>
    <dc:creator>MattWho</dc:creator>
    <dc:date>2020-03-06T18:28:41Z</dc:date>
    <item>
      <title>How to map/select controller service in processor after importing/creating  controller service using Nifi toolkit</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-to-map-select-controller-service-in-processor-after/m-p/291119#M215296</link>
      <description>&lt;P&gt;I am able to Export and Import controller services from one instance to another.&lt;/P&gt;
&lt;P&gt;Processors which are referencing to a controller service are not being mapped/selected.&lt;/P&gt;
&lt;P&gt;Looking for better possible way.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks in Advance&lt;/P&gt;</description>
      <pubDate>Thu, 05 Mar 2020 09:00:20 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-to-map-select-controller-service-in-processor-after/m-p/291119#M215296</guid>
      <dc:creator>anil35759</dc:creator>
      <dc:date>2020-03-05T09:00:20Z</dc:date>
    </item>
    <item>
      <title>Re: How to map/select controller service in processor after importing/creating  controller service using Nifi toolkit</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-to-map-select-controller-service-in-processor-after/m-p/291200#M215339</link>
      <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/75149"&gt;@anil35759&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It may be helpful if you can share the exact commands you are performing now to export and import your controller services.&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Matt&lt;/P&gt;</description>
      <pubDate>Thu, 05 Mar 2020 18:56:01 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-to-map-select-controller-service-in-processor-after/m-p/291200#M215339</guid>
      <dc:creator>MattWho</dc:creator>
      <dc:date>2020-03-05T18:56:01Z</dc:date>
    </item>
    <item>
      <title>Re: How to map/select controller service in processor after importing/creating  controller service using Nifi toolkit</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-to-map-select-controller-service-in-processor-after/m-p/291268#M215384</link>
      <description>&lt;P&gt;I have created a sample controller service and mapped to a processor in source.&lt;/P&gt;&lt;P&gt;Source:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="controller service.JPG" style="width: 999px;"&gt;&lt;img src="https://community.cloudera.com/t5/image/serverpage/image-id/26633i5AD172304B47D716/image-size/large?v=v2&amp;amp;px=999" role="button" title="controller service.JPG" alt="controller service.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;created a process group and execute sql processor and assigned created controller service to "Execute SQL" processor&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Executesql before map.JPG" style="width: 999px;"&gt;&lt;img src="https://community.cloudera.com/t5/image/serverpage/image-id/26634iD0C8626D2D13FD2E/image-size/large?v=v2&amp;amp;px=999" role="button" title="Executesql before map.JPG" alt="Executesql before map.JPG" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Mapped controller service" style="width: 999px;"&gt;&lt;img src="https://community.cloudera.com/t5/image/serverpage/image-id/26635i4BE734B65A12C5AD/image-size/large?v=v2&amp;amp;px=999" role="button" title="mapped controllerservice.JPG" alt="Mapped controller service" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;Mapped controller service&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Able to export Controller service as Json object with Nifi toolkit Class &lt;U&gt;&lt;STRONG&gt;"PGGetControllerServices".&lt;/STRONG&gt;&lt;/U&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Destination:&lt;/P&gt;&lt;P&gt;Created a new instance with different port 8086 and manually exported and imported Process group by creating a template.&lt;/P&gt;&lt;P&gt;Now my Destination instance looks similar to Source instance without any controller services.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Destination without controller service" style="width: 999px;"&gt;&lt;img src="https://community.cloudera.com/t5/image/serverpage/image-id/26636i16E1CC8335AF0F44/image-size/large?v=v2&amp;amp;px=999" role="button" title="destination import.JPG" alt="Destination without controller service" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;Destination without controller service&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Now I am able to Import/create controller service from external location by using&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;&lt;STRONG&gt;"PGCreateControllerService"&lt;/STRONG&gt;&lt;/U&gt;.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="After importing to destination" style="width: 999px;"&gt;&lt;img src="https://community.cloudera.com/t5/image/serverpage/image-id/26638i62B7855BA851F2B7/image-size/large?v=v2&amp;amp;px=999" role="button" title="Imported to destination.JPG" alt="After importing to destination" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;After importing to destination&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT size="5"&gt;Now i am looking how to map the controller service with Processor using Toolkit or any is there any other way to achieve.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in Advance&lt;/P&gt;</description>
      <pubDate>Fri, 06 Mar 2020 10:02:55 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-to-map-select-controller-service-in-processor-after/m-p/291268#M215384</guid>
      <dc:creator>anil35759</dc:creator>
      <dc:date>2020-03-06T10:02:55Z</dc:date>
    </item>
    <item>
      <title>Re: How to map/select controller service in processor after importing/creating  controller service using Nifi toolkit</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-to-map-select-controller-service-in-processor-after/m-p/291292#M215402</link>
      <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/75149"&gt;@anil35759&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you create a NiFi template that includes a NiFi processor that references a controller service, that controller service will be included in the generated template.&amp;nbsp; So if you import and instantiate that template on to the canvas of another NiFi, the controller service will be added as well and be associated with the processor instantiate from that same template.&lt;/P&gt;&lt;P&gt;&lt;A href="https://nifi.apache.org/docs/nifi-docs/html/user-guide.html#templates" target="_blank"&gt;https://nifi.apache.org/docs/nifi-docs/html/user-guide.html#templates&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So I am not clear on why you need to import the controller service separately via the toolkit.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Controller services are not mapped to processors.&amp;nbsp; The association happens from the processor side.&amp;nbsp; &amp;nbsp;The processor is mapped to a specific controller service via the controller services assigned uuid.&lt;BR /&gt;&lt;BR /&gt;Keep in mind that anything you can do within the NiFi Ui can also be accomplished using NiFi rest-api endpoints.&amp;nbsp; Using your browsers developer tools to capture the requests as you make them through the NiFi UI is a great way to learn how to interact with NiFi rest-api endpoints.&amp;nbsp; The rest-api endpoints specific to your NiFi release version can be found under help within your install.&lt;BR /&gt;Here are the Apache NiFi rest-api docs for the latest Apache release version:&lt;BR /&gt;&lt;A href="https://nifi.apache.org/docs/nifi-docs/rest-api/index.html" target="_blank"&gt;https://nifi.apache.org/docs/nifi-docs/rest-api/index.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Essentially what you need to do here is to update the processor configuration to reference the UUID of whichever controller service you want it to use.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;curl 'http://&amp;lt;nifi-hostname&amp;gt;:&amp;lt;nifi-port&amp;gt;/nifi-api/processors/b10fd083-0170-1000-0000-00007f7c905f' -X PUT --data-binary '{"component":{"id":"b10fd083-0170-1000-0000-00007f7c905f","name":"ExecuteSQL","config":{"concurrentlySchedulableTaskCount":"1","schedulingPeriod":"0 sec","executionNode":"ALL","penaltyDuration":"30 sec","yieldDuration":"1 sec","bulletinLevel":"WARN","schedulingStrategy":"TIMER_DRIVEN","comments":"","autoTerminatedRelationships":[],"properties":{"Database Connection Pooling Service":"e60cb24c-95c5-3a97-bcb9-9e537006317d"}},"state":"STOPPED"},"revision":{"clientId":"affea95c-0170-1000-988b-73bf756785b3","version":2},"disconnectedNodeAcknowledged":false}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So you'll notice from above example, I am updating a processor's (ExecuteSQL) configuration so that the Database Connection Pooling Service is mapped to the UUID of my DBCPConnectionPool controller service's uuid (e60cb24c-95c5-3a97-bcb9-9e537006317d).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Note:&amp;nbsp; The "clientId" string can be anything.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hope this helps,&lt;/P&gt;&lt;P&gt;Matt&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 06 Mar 2020 18:28:41 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-to-map-select-controller-service-in-processor-after/m-p/291292#M215402</guid>
      <dc:creator>MattWho</dc:creator>
      <dc:date>2020-03-06T18:28:41Z</dc:date>
    </item>
    <item>
      <title>Re: How to map/select controller service in processor after importing/creating  controller service using Nifi toolkit</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-to-map-select-controller-service-in-processor-after/m-p/291525#M215556</link>
      <description>&lt;P&gt;Thank you it helped and worked.&lt;/P&gt;</description>
      <pubDate>Wed, 11 Mar 2020 09:07:17 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-to-map-select-controller-service-in-processor-after/m-p/291525#M215556</guid>
      <dc:creator>anil35759</dc:creator>
      <dc:date>2020-03-11T09:07:17Z</dc:date>
    </item>
  </channel>
</rss>

