Main Page | Alphabetical List | Data Structures | File List | Data Fields | Globals | Related Pages

batch_job.h

Go to the documentation of this file.
00001 /*
00002 Copyright (C) 2003-2004 Douglas Thain and the University of Wisconsin
00003 Copyright (C) 2005- The University of Notre Dame
00004 This software is distributed under a BSD-style license.
00005 See the file COPYING for details.
00006 */
00007 
00008 #ifndef BATCH_JOB_H
00009 #define BATCH_JOB_H
00010 
00011 #include <time.h>
00012 
00020 typedef int batch_job_id_t;
00021 
00023 typedef enum {
00024         BATCH_QUEUE_TYPE_UNIX,  
00025         BATCH_QUEUE_TYPE_CONDOR,        
00026         BATCH_QUEUE_TYPE_SGE,   
00027         BATCH_QUEUE_TYPE_WORK_QUEUE  
00028 } batch_queue_type_t;
00029 
00034 struct batch_queue * batch_queue_create( batch_queue_type_t type );
00035 
00039 void batch_queue_delete( struct batch_queue *q );
00040 
00042 struct batch_job_info {
00043         time_t submitted;       
00044         time_t started;         
00045         time_t finished;        
00046         int exited_normally;    
00047         int exit_code;          
00048         int exit_signal;        
00049 };
00050 
00063 batch_job_id_t batch_job_submit(
00064         struct batch_queue *q,
00065         const char *cmd,
00066         const char *args,
00067         const char *infile,
00068         const char *outfile,
00069         const char *errfile,
00070         const char *extra_input_files,
00071         const char *extra_output_files );
00072 
00080 batch_job_id_t batch_job_wait( struct batch_queue *q, struct batch_job_info *info );
00081 
00090 int batch_job_remove( struct batch_queue *q, batch_job_id_t jobid );
00091 
00092 #endif

Generated on Fri Jun 5 11:10:53 2009 for cctools by  doxygen 1.3.9.1