Task Scheduler cannot stop tasks since Server 2016
The Option "Stop task if it runs longer than" under Triggers no longer kills the running task in Server 2016/2019.
The same scheduled task that would be killed after the time set on the Trigger of the scheduled task in all Server version before Server 2012 R2 are not terminate on Server 2016/2019.
I confirmed this with creating a basic task to run notepad and kill it after a minute in Server 2019 and upon execution task scheduler never kills notepad.
This same job was exported to Server 2016 and it didn't work either. The XML was then imported to a Server 2012 R2 server and it did work, i.e. notepad was killed after 1 minute as specified on the Trigger.
I also tried the global setting on the scheduled task itself to stop the task but that didn't work either.