FileDocCategorySizeDatePackage
QuartzJob.javaAPI DocJBoss 4.2.12442Fri Jul 13 21:01:14 BST 2007org.jboss.resource.adapter.quartz.inflow

QuartzJob

public class QuartzJob extends Object implements org.quartz.Job
Comment
author
Bill Burke
version
$Revision: 57189 $

Fields Summary
private static Logger
log
Constructors Summary
public QuartzJob()


    
   
   
Methods Summary
public voidexecute(org.quartz.JobExecutionContext jobExecutionContext)

      MessageEndpoint endpoint = null;
      try
      {
         MessageEndpointFactory endpointFactory = (MessageEndpointFactory)jobExecutionContext.getJobDetail().getJobDataMap().get("endpointFactory");
         endpoint = endpointFactory.createEndpoint(null);
         if (endpoint != null)
         {
            Job job = (Job) endpoint;
            job.execute(jobExecutionContext);
         }
         else
         {
            log.error("ENDPOINT IS NULL!!!!");
         }
      }
      catch (UnavailableException e)
      {
         throw new JobExecutionException(e);
      }
      finally
      {
         if (endpoint != null)
         {
            endpoint.release();
         }
      }