Automate the Enablement of a StandardHttpContextMap
I'm trying to automate the deployment of a template that contains a HandleHttpRequest processor. My issue is that this always comes up with an Invalid component marker after a fresh deployment of the template. The cause of this marker is that the StandardHttpContextMap in the HandleHttpRequest processor needs to be manually enabled in Controller Services. Is there any way to avoid this manual enablement?
Re: Automate the Enablement of a StandardHttpContextMap
When a template, or a versioned flow, is instantiated, all the processors are initially stopped and the services are disabled. This is done on purpose since starting and enabling components may cause interactions with external systems, and it may not be clear or desired that just by instantiating the template that all of these interactions are automatically going to take place. So it requires an extra step where the user (or your script) must explicitly enabled and start the components. The NIFI CLI has a command "pg-enable-services" that can be used to enable all the services in a given process group. You could call this from your script like "./bin/cli.sh nifi pg-enable-service -pgid someid". On Thu, Mar 21, 2019 at 11:29 AM William Gosse wrote: > > I’m trying to automate the deployment of a template that contains a > HandleHttpRequest processor. > > > > My issue is that this always comes up with an Invalid component marker after > a fresh deployment of the template. > > The cause of this marker is that the StandardHttpContextMap in the > HandleHttpRequest processor needs to be manually enabled in Controller > Services. > > > > Is there any way to avoid this manual enablement? > > > >
RE: Automate the Enablement of a StandardHttpContextMap
I'm having a problem with the command you showed below. When I run it for my stuff I get the following: PS C:\Dev\aim\nifi-toolkit-1.9.1\bin> .\cli.bat nifi pg-enable-services -pgid aee943fb-48ac-351e-aef7-29db27d33b0f -p .. \conf\cli.properties ERROR: Error executing command 'pg-enable-services' : One or more services could not be enabled, run command with -verbose to obtain more details The are for components referencing the StandardHttpContextMap, one HandleHttpRequest component and three HandleHttpResponse components. Any suggestion on how to handle this error? -Original Message- From: Bryan Bende Sent: Thursday, March 21, 2019 12:27 PM To: users@nifi.apache.org Subject: Re: Automate the Enablement of a StandardHttpContextMap [CAUTION: This email originated from outside of Kodak Alaris. Do not click links or open attachments unless you recognize the sender and know the content is safe.] When a template, or a versioned flow, is instantiated, all the processors are initially stopped and the services are disabled. This is done on purpose since starting and enabling components may cause interactions with external systems, and it may not be clear or desired that just by instantiating the template that all of these interactions are automatically going to take place. So it requires an extra step where the user (or your script) must explicitly enabled and start the components. The NIFI CLI has a command "pg-enable-services" that can be used to enable all the services in a given process group. You could call this from your script like "./bin/cli.sh nifi pg-enable-service -pgid someid". On Thu, Mar 21, 2019 at 11:29 AM William Gosse wrote: > > I’m trying to automate the deployment of a template that contains a > HandleHttpRequest processor. > > > > My issue is that this always comes up with an Invalid component marker after > a fresh deployment of the template. > > The cause of this marker is that the StandardHttpContextMap in the > HandleHttpRequest processor needs to be manually enabled in Controller > Services. > > > > Is there any way to avoid this manual enablement? > > > >
Re: Automate the Enablement of a StandardHttpContextMap
If you run it with -verbose does it produce anything more helpful? On Thu, Mar 21, 2019 at 2:55 PM William Gosse wrote: > > I'm having a problem with the command you showed below. When I run it for my > stuff I get the following: > PS C:\Dev\aim\nifi-toolkit-1.9.1\bin> .\cli.bat nifi pg-enable-services -pgid > aee943fb-48ac-351e-aef7-29db27d33b0f -p .. > \conf\cli.properties > > ERROR: Error executing command 'pg-enable-services' : One or more services > could not be enabled, run command with -verbose to obtain more details > > The are for components referencing the StandardHttpContextMap, one > HandleHttpRequest component and three HandleHttpResponse components. > > Any suggestion on how to handle this error? > > -Original Message- > From: Bryan Bende > Sent: Thursday, March 21, 2019 12:27 PM > To: users@nifi.apache.org > Subject: Re: Automate the Enablement of a StandardHttpContextMap > > [CAUTION: This email originated from outside of Kodak Alaris. Do not click > links or open attachments unless you recognize the sender and know the > content is safe.] > > When a template, or a versioned flow, is instantiated, all the processors are > initially stopped and the services are disabled. This is done on purpose > since starting and enabling components may cause interactions with external > systems, and it may not be clear or desired that just by instantiating the > template that all of these interactions are automatically going to take > place. So it requires an extra step where the user (or your script) must > explicitly enabled and start the components. > > The NIFI CLI has a command "pg-enable-services" that can be used to enable > all the services in a given process group. You could call this from your > script like "./bin/cli.sh nifi pg-enable-service -pgid someid". > > On Thu, Mar 21, 2019 at 11:29 AM William Gosse > wrote: > > > > I’m trying to automate the deployment of a template that contains a > > HandleHttpRequest processor. > > > > > > > > My issue is that this always comes up with an Invalid component marker > > after a fresh deployment of the template. > > > > The cause of this marker is that the StandardHttpContextMap in the > > HandleHttpRequest processor needs to be manually enabled in Controller > > Services. > > > > > > > > Is there any way to avoid this manual enablement? > > > > > > > >
Re: Automate the Enablement of a StandardHttpContextMap
Also meant to say that it can only be enabled if it is valid, meaning there are no validation messages on the component. So it might be worth checking in the UI to see if there are any validation issues on the service. On Thu, Mar 21, 2019 at 3:02 PM Bryan Bende wrote: > > If you run it with -verbose does it produce anything more helpful? > > On Thu, Mar 21, 2019 at 2:55 PM William Gosse > wrote: > > > > I'm having a problem with the command you showed below. When I run it for > > my stuff I get the following: > > PS C:\Dev\aim\nifi-toolkit-1.9.1\bin> .\cli.bat nifi pg-enable-services > > -pgid aee943fb-48ac-351e-aef7-29db27d33b0f -p .. > > \conf\cli.properties > > > > ERROR: Error executing command 'pg-enable-services' : One or more services > > could not be enabled, run command with -verbose to obtain more details > > > > The are for components referencing the StandardHttpContextMap, one > > HandleHttpRequest component and three HandleHttpResponse components. > > > > Any suggestion on how to handle this error? > > > > -Original Message----- > > From: Bryan Bende > > Sent: Thursday, March 21, 2019 12:27 PM > > To: users@nifi.apache.org > > Subject: Re: Automate the Enablement of a StandardHttpContextMap > > > > [CAUTION: This email originated from outside of Kodak Alaris. Do not click > > links or open attachments unless you recognize the sender and know the > > content is safe.] > > > > When a template, or a versioned flow, is instantiated, all the processors > > are initially stopped and the services are disabled. This is done on > > purpose since starting and enabling components may cause interactions with > > external systems, and it may not be clear or desired that just by > > instantiating the template that all of these interactions are automatically > > going to take place. So it requires an extra step where the user (or your > > script) must explicitly enabled and start the components. > > > > The NIFI CLI has a command "pg-enable-services" that can be used to enable > > all the services in a given process group. You could call this from your > > script like "./bin/cli.sh nifi pg-enable-service -pgid someid". > > > > On Thu, Mar 21, 2019 at 11:29 AM William Gosse > > wrote: > > > > > > I’m trying to automate the deployment of a template that contains a > > > HandleHttpRequest processor. > > > > > > > > > > > > My issue is that this always comes up with an Invalid component marker > > > after a fresh deployment of the template. > > > > > > The cause of this marker is that the StandardHttpContextMap in the > > > HandleHttpRequest processor needs to be manually enabled in Controller > > > Services. > > > > > > > > > > > > Is there any way to avoid this manual enablement? > > > > > > > > > > > >
RE: Automate the Enablement of a StandardHttpContextMap
Ok I got this working by configuring each Http component's StandardHttpContextMap individual instead having them all ganged all onto one. Each of the StandardHttpContextMap is stills coped for the process group that all the components are in. I'll admit I'm still a little shaky on controller services but it seem to work now. I'm able to enable all the controller services form the root group with .\conf\cli.properties PS C:\Dev\aim\nifi-toolkit-1.9.1\bin> .\cli.bat nifi pg-enable-services -pgid 911b83b1-0169-1000-17bb-823bb530cf8c -p ..\conf\cli.properties Thanks for the help it is much approceiated. -Original Message- From: William Gosse Sent: Thursday, March 21, 2019 2:55 PM To: users@nifi.apache.org Subject: RE: Automate the Enablement of a StandardHttpContextMap [CAUTION: This email originated from outside of Kodak Alaris. Do not click links or open attachments unless you recognize the sender and know the content is safe.] [WARNING: Potential spoofed mail] The sender of this email used an @kodakalaris.com email address, but the email did not come from a known Kodak Alaris email system. This email might not be legitimate. Delete this email unless it was sent from a known, trusted source. To avoid this notice if this email was sent from a known trusted source please submit an IT_KAre request to have this sender added as a valid email sender. Proofpoint rule module.access.rule.anti_spoofing_rule Message ID 2rceu6r68c-1 2rceu6r68c I'm having a problem with the command you showed below. When I run it for my stuff I get the following: PS C:\Dev\aim\nifi-toolkit-1.9.1\bin> .\cli.bat nifi pg-enable-services -pgid aee943fb-48ac-351e-aef7-29db27d33b0f -p .. \conf\cli.properties ERROR: Error executing command 'pg-enable-services' : One or more services could not be enabled, run command with -verbose to obtain more details The are for components referencing the StandardHttpContextMap, one HandleHttpRequest component and three HandleHttpResponse components. Any suggestion on how to handle this error? -Original Message- From: Bryan Bende Sent: Thursday, March 21, 2019 12:27 PM To: users@nifi.apache.org Subject: Re: Automate the Enablement of a StandardHttpContextMap [CAUTION: This email originated from outside of Kodak Alaris. Do not click links or open attachments unless you recognize the sender and know the content is safe.] When a template, or a versioned flow, is instantiated, all the processors are initially stopped and the services are disabled. This is done on purpose since starting and enabling components may cause interactions with external systems, and it may not be clear or desired that just by instantiating the template that all of these interactions are automatically going to take place. So it requires an extra step where the user (or your script) must explicitly enabled and start the components. The NIFI CLI has a command "pg-enable-services" that can be used to enable all the services in a given process group. You could call this from your script like "./bin/cli.sh nifi pg-enable-service -pgid someid". On Thu, Mar 21, 2019 at 11:29 AM William Gosse wrote: > > I’m trying to automate the deployment of a template that contains a > HandleHttpRequest processor. > > > > My issue is that this always comes up with an Invalid component marker after > a fresh deployment of the template. > > The cause of this marker is that the StandardHttpContextMap in the > HandleHttpRequest processor needs to be manually enabled in Controller > Services. > > > > Is there any way to avoid this manual enablement? > > > >