Support Questions

Find answers, ask questions, and share your expertise

How to Productionize Nifi and schedule it to run every hour not from Nifi UI?

avatar
Expert Contributor

What is the best practice to productionize nifi and schedule it to run every hour through a script? How do we upgrade nifi to a new version. How to deploy new workflows and modified workflows into production in EC2.

How do we deploy changes into nifi workflows thank you

1 ACCEPTED SOLUTION

avatar
Master Guru

I think it depends what you mean by "schedule it to run every hour"... NiFi itself would always be running and different processors can be scheduled to run according to their needs. Every processor supports timer based scheduling or cron based scheduling, so using either of those you can set a source processor to run every hour. You could also use the REST API to start and stop processors as needed, anything you can do in the UI can be done through the REST API.

For best practices for upgrading NiFi see this wiki page:

https://cwiki.apache.org/confluence/display/NIFI/Upgrading+NiFi

Deploying changes to production, there are a couple of approaches, one of them is based around templates:

https://github.com/aperepel/nifi-api-deploy

Some people also just move the flow.xml.gz from one environment to another, but this assumes you have parametized everything that is different between environments.

View solution in original post

1 REPLY 1

avatar
Master Guru

I think it depends what you mean by "schedule it to run every hour"... NiFi itself would always be running and different processors can be scheduled to run according to their needs. Every processor supports timer based scheduling or cron based scheduling, so using either of those you can set a source processor to run every hour. You could also use the REST API to start and stop processors as needed, anything you can do in the UI can be done through the REST API.

For best practices for upgrading NiFi see this wiki page:

https://cwiki.apache.org/confluence/display/NIFI/Upgrading+NiFi

Deploying changes to production, there are a couple of approaches, one of them is based around templates:

https://github.com/aperepel/nifi-api-deploy

Some people also just move the flow.xml.gz from one environment to another, but this assumes you have parametized everything that is different between environments.