Rework shutdown

This set of patches is intended to make sure that the agent will reliably stop after a reasonable time if it has been requested to, even in some corner cases.

I removed the counting of shutdown requests: One request needs to be enough in case of for example a shutdown of the host or an automated restart.
Could you please use the same type setup that the other flags do?

`type=partial(integer, instance=self, flag="shutdown-timeout", min_=0),`

The advantage over straight `int` is that we can enforce a minimum but it also keeps the parser error consistent with the other flags too.