Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Unable to clear Nifi Queue

Solved Go to solution

Unable to clear Nifi Queue

Explorer

Hi all,

I run on NIFI 1.1.1.

It seems I'm not only to unable to empty queue. It is a bug ?

regards

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Unable to clear Nifi Queue

Master Guru

@mayki wogno

What type of downstream processor is the queue you are trying to empty connect to?

Some processors such as the MergeContent processor when running have ownership of FlowFiles in the incoming queue.

The MergeContent assigns FlowFiles on its incoming queue(s) to bins. You will not be able to clear the queue of any FlowFiles that are currently assigned to a bin.

If you stop the processor downstream of your queue (Processor must show no running threads), can you then successfully empty the queue?

Thanks,

Matt

5 REPLIES 5

Re: Unable to clear Nifi Queue

Master Guru

@mayki wogno

What type of downstream processor is the queue you are trying to empty connect to?

Some processors such as the MergeContent processor when running have ownership of FlowFiles in the incoming queue.

The MergeContent assigns FlowFiles on its incoming queue(s) to bins. You will not be able to clear the queue of any FlowFiles that are currently assigned to a bin.

If you stop the processor downstream of your queue (Processor must show no running threads), can you then successfully empty the queue?

Thanks,

Matt

Re: Unable to clear Nifi Queue

Master Guru

@mayki wogno

If you are a secured NiFi cluster, make sure all you nodes have been granted the "modify the data" access policy for those connections (or the containing process group if connections are inheriting policies). As a authenticated and authorized user, when you make a request logged in to one node, that request is replicated to the other nodes. So the purge of data is being done on your behalf by the node you are currently logged in to. Authorizing your nodes to be able to modify the data should allow you to empty the queue successfully.

Another option is to temporarily set file expiration on the connection to 1 sec so that NiFi purges the queue itself. Just don't forget to change it back to avoid data loss when you don't want purging to occur.

Of course as Bryan had noted, you can always top nifi and delete everything in FlowFile and content repositories to purge all data form you dataflow, but that may not always be desired.

Thanks,

Matt

Re: Unable to clear Nifi Queue

Explorer

I'm trying to empty queue of connect "to routeOnAttribute from routeOnAttribute" and another connecter to routeOnAttribute to deleteHDFS"

So I've two connectors where i unable to empty even if all processors are stopped.

Re: Unable to clear Nifi Queue

Explorer

I'm trying to empty connector from "routeToAttribute to routeToAttribute" and another connector from "routeToAttribute to deleteHDFS"

Even if i've stopped all procesors in process group, i'm unable to empty queue.

I did stop nifi and remove all files in *_repository like explain Bryan in another post.

Highlighted

Re: Unable to clear Nifi Queue

Explorer

@Matt, thanks

All nodes in my cluster have been granted "modify the data", i've already succesfully empty queue.

Next time, I'm trying expiration time.

Don't have an account?
Coming from Hortonworks? Activate your account here