00001 #ifndef WORK_QUEUE_PROCESS_H
00002 #define WORK_QUEUE_PROCESS_H
00003
00004 #include "work_queue.h"
00005 #include "timestamp.h"
00006
00007 #include <unistd.h>
00008 #include <sys/types.h>
00009 #include <sys/resource.h>
00010
00011
00012
00013
00014
00015
00016 struct work_queue_process {
00017 pid_t pid;
00018 int task_status;
00019 int exit_status;
00020
00021 struct rusage rusage;
00022 timestamp_t execution_start;
00023 timestamp_t execution_end;
00024
00025 char *sandbox;
00026
00027 char *output_file_name;
00028 int output_fd;
00029
00030 struct work_queue_task *task;
00031 };
00032
00033 struct work_queue_process * work_queue_process_create( int taskid );
00034 pid_t work_queue_process_execute( struct work_queue_process *p );
00035 void work_queue_process_kill( struct work_queue_process *p );
00036 void work_queue_process_delete( struct work_queue_process *p );
00037
00038 #endif