I created script for this purpose that you can find on github
Precise scheduling of scripts in powershell
-
22-06-2023 - |
質問
I have number of monitoring functions that I want to execute with dynamic frequencies, depending on project. The range of frequencies are from once every second, to once a day. TaskScheduler or ScheduledJob are not precise enough for this purpose.
Is any function scheduler such as this available?
解決 2
他のヒント
Spinning up a powershell instance is not a trivial event. If you're wanting monitoring on a frequency less than a few minutes you'll be much better off to write a script that stays resident and runs in an endless process-sleep-process loop.
所属していません StackOverflow