Hi Jean-Sebastien,

When you stop NiFi, by default, it will try to gracefully stop everything
in 10 seconds, and if not all components are nicely stopped after that, it
will force shut down the NiFi process. This is configured with
"nifi.flowcontroller.graceful.shutdown.period" in nifi.properties file. If
you have processors/CS that might take longer to stop gracefully (because
of connections to external systems for instance), you could increase this
value.

I'm not very familiar with AWS spot instances but I'd try to catch the spot
notification event to stop the NiFi service on the host before the instance
is stopped/killed.

Pierre



Le mar. 27 août 2019 à 20:05, Jean-Sebastien Vachon <jsvac...@brizodata.com>
a écrit :

> Hi everybody,
>
> I am working with AWS spot instances and one thing that is giving me a
> hard time is to perform a clean (and quick) shutdown of Nifi in order to
> prevent data loss.
>
> AWS will give you about two minutes to clean up everything before the
> machine is actually shutdown.
> Is there a way to stop/kill all processes running on the host without
> loosing anything? It is fine if all the flowfiles being processed are
> simply requeued.
>
> Would simply killing the processes achieve this? (I doubt so)... would it
> be better to fetch a list of running processors and terminate them using
> Nifi's API?
>
> All ideas and thoughts are welcome
>
> thanks
>

Reply via email to