To develop and schedule tasks, use a configured scheduler.
Procedure
Look up a configured scheduler. Refer to the Accessing schedules
topic. Each configured scheduler is available from two different
programming models:
A Java™ Platform,
Enterprise Edition (Java EE) server application, such as a servlet
or Enterprise JavaBeans™ (EJB) component, can use the Scheduler
API. Schedulers are accessed by looking them up using a Java Naming
and Directory Interface (JNDI) name or resource reference.
Java Management
Extensions (JMX) applications, such as wsadmin scripts, can use the Scheduler
API using WASScheduler MBeans.
Develop the task.
The Scheduler API supports different
implementations of the TaskInfo interface, each of which can be used to schedule
a particular type of work. Refer to the Developing a task that calls a session
bean topic and Develop a task that sends a Java Message Service (JMS) message topic
for details. The task object that is referenced in the Develop a task that
sends a Java Message Service (JMS) message topic can send a
JMS message to either a queue or a topic.
Attention: Creating
and manipulating scheduled tasks through the Scheduler interface is only supported
from within the EJB container or Web container (Enterprise beans or servlets).
Looking up and using a configured scheduler from a Java EE
application client container is not supported.
Receive scheduler notifications. A notification sink
is set on a task in order to receive the notification events that are generated
by a scheduler when it performs an operation on the task.
Use custom calendars. You can assign a UserCalendar
session bean to a task that allows schedulers to use custom and predefined
date algorithms to determine when a task should run. Refer to the UserCalendar
interface topic for details.
Submit tasks to a scheduler. After a TaskInfo object
has been created, it can be submitted to the scheduler for task creation by
calling the Scheduler.create() method.
Use IBM Suggests to retrieve related content from ibm.com and beyond, identified for your convenience.
This feature requires Internet access.
Most of the following links will take you to information that is not part of the formal product documentation and is provided "as is." Some of these links go to non-IBM Web sites and are provided for your convenience only and do not in any manner serve as an endorsement by IBM of those Web sites, the material thereon, or the owner thereof.
Last updated: Oct 21, 2010 5:30:17 AM CDT http://www14.software.ibm.com/webapp/wsbroker/redirect?version=compass&product=was-nd-iseries&topic=tsch_developtasks File name: tsch_developtasks.html