You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@nifi.apache.org by Richard Snyder <ri...@fivetwelvellc.com> on 2016/07/01 13:02:48 UTC

ExecuteSQL multi

Hello All,
  I'm using the ExecuteSQL to call a stored procedure in MySQL.  I'm
running into an error which I'm unsure about.  I have flowfiles that are
going to the processor within 20 milliseconds of one another.  The 1st one
will execute while the following goes the error path.  I think it's because
the processor is still waiting for the stored procedure response and cannot
execute more than 1 command at once.  The error in my logs are:

jdbc4.CommunicationsException: The last packet successfully received from
teh server was <xxx> seconds ago.

Does the processor have a "wait until completed" ability with flowfiles
sent to it so it doesn't trip on itself" or am I wrong on the error?

-- 
Cell: 410-960-3023

Re: ExecuteSQL multi

Posted by Mark Payne <ma...@hotmail.com>.
Richard,

NiFi allows you to configure how many threads are executing at the same time. This is configured
by right-clicking on the processor and going to the "Scheduling" tab. You can choose the number of
concurrent tasks. If that is set to 1, then only one FlowFile will be processed at a time.

If you are running in a clustered environment, that means that each node will process one FlowFile
at a time. If you want to ensure that only a single node is running at a time, you can change the
scheduling strategy (in that same tab / configuration dialog) to Primary Node, so that only a single node
will run, but you will then need to ensure that you push all of the data to the Primary Node.

Thanks
-Mark

> On Jul 1, 2016, at 9:02 AM, Richard Snyder <ri...@fivetwelvellc.com> wrote:
> 
> Hello All,
>  I'm using the ExecuteSQL to call a stored procedure in MySQL.  I'm
> running into an error which I'm unsure about.  I have flowfiles that are
> going to the processor within 20 milliseconds of one another.  The 1st one
> will execute while the following goes the error path.  I think it's because
> the processor is still waiting for the stored procedure response and cannot
> execute more than 1 command at once.  The error in my logs are:
> 
> jdbc4.CommunicationsException: The last packet successfully received from
> teh server was <xxx> seconds ago.
> 
> Does the processor have a "wait until completed" ability with flowfiles
> sent to it so it doesn't trip on itself" or am I wrong on the error?
> 
> -- 
> Cell: 410-960-3023