Support Questions

Find answers, ask questions, and share your expertise
Announcements
Celebrating as our community reaches 100,000 members! Thank you!

Regarding NIFI Timer driven scheduling not working

avatar
Explorer

Hi Team,

I have the below flow to get the ticket details through Rest Api call i want to execute it will atomatically execute after every 60 min but scheduling not working.Please support how can execute below flow after every 60 min.

 

Note:API's working fine through postman able to execute flow 

 

 

pk87_0-1656906714445.png

I have set below property but flow is not executed after 60 min.

pk87_1-1656906784041.png

 

 

5 REPLIES 5

avatar
Super Guru

@pk87 ,

 

The HandleHttpRequest processor will only produce a flowfile when an HTTP call is received on its port. If you want this to be called every 60 minutes you can add an InvokeHTTP processor, scheduled to run every 60 minutes, that will call your API endpoint in the same way that Postman does.

 

You actually don't need the HandleHttpProcessor to run this on a regular basis. You could possibly replace that with a GenerateFlowFile that executes every 60 minutes and will trigger the process for you.

 

Cheers,

André

 

 

--
Was your question answered? Please take some time to click on "Accept as Solution" below this post.
If you find a reply useful, say thanks by clicking on the thumbs up button.

avatar
Explorer

Thanks for your quick support....Please support for another issue 

Hi Team,

I have the below flow to get the ticket details .getting 400 error and I have provided valid credentials also. Please suggest.

Note:API's working fine in postman.

 

pk87_0-1656931637435.png

Evaluation JSON path process contains access token

pk87_1-1656931655075.png

Update attribute processor contains the authorization

pk87_2-1656931670669.png

Invoke http processor contains url for ticket details

pk87_3-1656931684940.pngpk87_4-1656931692270.png

Here I'm getting issue in  invoke http processor

pk87_5-1656931706817.pngpk87_6-1656931714486.png

 

avatar
Explorer

@araujo,

 

Please support above issue.

avatar
Super Mentor

@pk87 
Above was discussed in another post here:
https://community.cloudera.com/t5/Support-Questions/NIFI-I-m-getting-issue-like-quot-authentication-...
A configuration change was provided to resolve the http 400 response.  The new response was an HTTP 401 so request was good, but a end point did not like the authorization provided in the request.

Thanks

Matt

avatar
Super Mentor

@pk87 
Also consider that using timer driven may not always give you 60 minute scheduling.  When using timer driven the component will get scheduled upon start and then again x configured amount of time later.  A NiFi restart or stopping and starting the processor will reset this.  If you need to make sure that a component is only scheduled every x amount of time consistently, you should be using cron driven scheduling strategy which will allow you to set specific time of schedule.

Thanks,

Matt