EJBInvokerJob (Quartz Parent POM 2.0.1 API)
From Quartz Java
|
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
org.quartz.jobs.ee.ejb Class EJBInvokerJob
java.lang.Objectorg.quartz.jobs.ee.ejb.EJBInvokerJob
- All Implemented Interfaces:
- Job
A Job that invokes a method on an EJB.
Expects the properties corresponding to the following keys to be in the
JobDataMap when it executes:
EJB_JNDI_NAME_KEY- the JNDI name (location) of the EJB's home interface.EJB_METHOD_KEY- the name of the method to invoke on the EJB.EJB_ARGS_KEY- an Object[] of the args to pass to the method (optional, if left out, there are no arguments).EJB_ARG_TYPES_KEY- an Class[] of the types of the args to pass to the method (optional, if left out, the types will be derived by calling getClass() on each of the arguments).
The following keys can also be used at need:
INITIAL_CONTEXT_FACTORY- the context factory used to build the context.PROVIDER_URL- the name of the environment property for specifying configuration information for the service provider to use.
The result of the EJB method invocation will be available to
Job/TriggerListeners via
JobExecutionContext.getResult().
- Author:
- Andrew Collins, James House, Joel Shellman, Chris Bonham
Field Summary
static String
CREDENTIALS
static String
EJB_ARG_TYPES_KEY
static String
EJB_ARGS_KEY
static String
EJB_JNDI_NAME_KEY
static String
EJB_METHOD_KEY
static String
INITIAL_CONTEXT_FACTORY
static String
PRINCIPAL
static String
PROVIDER_URL
Constructor Summary
EJBInvokerJob()
Method Summary
void
execute(JobExecutionContext context)
Called by the Scheduler when a Trigger
fires that is associated with the Job.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
EJB_JNDI_NAME_KEY
public static final String EJB_JNDI_NAME_KEY
- See Also:
- Constant Field Values
EJB_METHOD_KEY
public static final String EJB_METHOD_KEY
- See Also:
- Constant Field Values
EJB_ARG_TYPES_KEY
public static final String EJB_ARG_TYPES_KEY
- See Also:
- Constant Field Values
EJB_ARGS_KEY
public static final String EJB_ARGS_KEY
- See Also:
- Constant Field Values
INITIAL_CONTEXT_FACTORY
public static final String INITIAL_CONTEXT_FACTORY
- See Also:
- Constant Field Values
PROVIDER_URL
public static final String PROVIDER_URL
- See Also:
- Constant Field Values
PRINCIPAL
public static final String PRINCIPAL
- See Also:
- Constant Field Values
CREDENTIALS
public static final String CREDENTIALS
- See Also:
- Constant Field Values
Constructor Detail
EJBInvokerJob
public EJBInvokerJob()
Method Detail
execute
public void execute(JobExecutionContext context)
throws JobExecutionException
- Description copied from interface:
Job
Called by the Scheduler when a Trigger
fires that is associated with the Job.
The implementation may wish to set a
result object on the
JobExecutionContext before this method exits. The result itself
is meaningless to Quartz, but may be informative to
JobListeners or
TriggerListeners that are watching the job's
execution.
- Throws:
JobExecutionException - if there is an exception while executing the job.
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Copyright 2001-2011, Terracotta, Inc.