Support Questions

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

Using wait Processor in nifi

avatar
Contributor

I need to use wait processor for terminating invokehttp processor in case of failure, I have tried this - [https://stackoverflow.com/questions/43915412/how-to-use-wait-notify-processor][1]

and added DistributeCashMapServerService by PutDistributeMapCachProcessor (I have made host:localhost with port 4557 for both DistributeMapCachclient and server service), but both of them still throws execpetion:Should I change server port? Or configure it another way?

(P.S I have uploaded picture of error itself and my workflow in nifi)

33388-workflow.png

33387-errorserver.png

14 REPLIES 14

avatar

@sally sally

The Wait processor works with the Notify processor.

The configuration of the Wait processor:

34381-screen-shot-2017-08-20-at-42752-pm.png

Here is the configuration of the Notify processor that will be a trigger for the Wait processor:

34382-screen-shot-2017-08-20-at-43007-pm.png

Here are the DistributedMapCacheClientService and DistributedMapCacheServer controller services being used by these processors and their configurations.

DistributedMapCacheServer

34383-screen-shot-2017-08-20-at-43258-pm.png

DistributedMapCacheClientService

34385-screen-shot-2017-08-20-at-43408-pm.png

It is better to put the actual hostname instead of just localhost.

The DistributedMapCacheClientService controller service needs to have a DistributedMapCacheServer controller service configured.

Replace the PutDistributedMapCache processor with the Notify processor in your flow.

avatar
Contributor

I have successfully implemented all this (thank you for your answer) but it seems that it isn't good solution for my task,can you recommend me any internal command which can help me stopping another processor by compilig script in executescript processor

avatar
Contributor

How can i add DistributedCashMapServer without putDistributedMap processor? why did you replace localhots withnifi-sme-19 ?

avatar
Contributor

I have manged it already, can i stop other processor by 'wait' conection?

avatar
@sally sally

If that is how you want to use it, sure.

avatar
@sally sally

In this question, I provided an example of a script that will stop a processor. Stop a processor with a script

Won't this work for you?

avatar
Contributor

I have windows and when i try to make it with bat file i get this errod https://community.hortonworks.com/questions/129851/stopping-processor-by-curl-commands.html

avatar
Contributor

but it was useful, becuase tanks to it i found out how to make my task , but i still gave exceptions

avatar
Contributor

first of all i have winsows and when i try to make all this by bat file i get this case :https://community.hortonworks.com/questions/129851/stopping-processor-by-curl-commands.html