LHS Feature Of The Week #5 - Task Scheduler 2.0
Hello everyone, and welcome back to the “Feature Of The Week” newsletter. In this fifth installment, we will take a short little peek at a series of enhancements coming in Vista and Longhorn Server to the Task Scheduler.
What is the Task Scheduler API? The Task Scheduler API is an API that enables you to automatically perform routine tasks on a chosen computer. The Task Scheduler does this by monitoring whatever criteria you choose to initiate the tasks (referred to as triggers) and then executing the tasks when the criteria is met.
What enhancements have been made in 2.0 over 1.0? The following Task Scheduler 2.0 changes are introduced in Windows Vista:
- Isolating user actions in separate sessions
- Credentials managements using new security services (S4U and CredMan)
- Removed limitations on the number of registered tasks
- API changes:
- Scripting support: interfaces are now derived from IDispatch, providing full support for script development
- Task Scheduler schema: allows you to create/manage tasks through XML-formatted docs.
- New Triggers: new time, calendar, and event triggers. All triggers support repetition, delay, start, and stop boundaries.
- Task settings: can now prioritize tasks, define multiple instance policies, start a task only when it is available or only if the network is available, restart on failure, and set an execution time limit
- New actions: a task can be scheduled to send an email, show a message box, start an exe, or fire a COM handler.
What scenarios does this enable? The Task Scheduler can be used to execute tasks such as starting an application, sending an email, or showing a message box. Tasks can be scheduled to execute:
- When a specific system event occurs
- At a specific time (even on a daily, weekly, monthly, or monthly day-of-week schedule)
- When the computer enters an idle state
- When the task is registered
- When the system is booted
- When a user logs on
- When a Terminal Server session changes state