work_queue_internal.h

00001 /*
00002 Copyright (C) 2008- The University of Notre Dame
00003 This software is distributed under the GNU General Public License.
00004 See the file COPYING for details.
00005 */
00006 
00007 #include "work_queue.h"
00008 #include "work_queue_resources.h"
00009 
00010 #include "list.h"
00011 
00012 struct work_queue_file {
00013         work_queue_file_t type;
00014         int flags;              // WORK_QUEUE_CACHE or others in the future.
00015         int length;             // length of payload, only used for non-file objects like buffers and urls
00016         off_t offset;           // file offset for WORK_QUEUE_FILE_PIECE
00017         off_t piece_length;     // file piece length for WORK_QUEUE_FILE_PIECE
00018         char *payload;          // name on master machine or buffer of data.
00019         char *remote_name;      // name on remote machine.
00020         char *cached_name;      // name on remote machine in cached directory.
00021 };
00022 
00023 struct work_queue_task *work_queue_wait_internal(struct work_queue *q, int timeout, struct link *foreman_uplink, int *foreman_uplink_active);
00024 
00025 /* Adds (arithmetically) all the workers resources (cores, memory, disk) */
00026 void aggregate_workers_resources( struct work_queue *q, struct work_queue_resources *r );
00027 
00033 void work_queue_enable_process_module(struct work_queue *q);
00034 
00039 int work_queue_submit_internal(struct work_queue *q, struct work_queue_task *t);
00040 
00042 void work_queue_invalidate_cached_file_internal(struct work_queue *q, const char *filename);
00043 
00044 void release_all_workers(struct work_queue *q);
00045 
00046 void update_catalog(struct work_queue *q, struct link *foreman_uplink, int force_update );
00047 
00049 void work_queue_broadcast_message(struct work_queue *q, const char *msg);
00050 
00051 /* shortcut to set cores, memory, disk, etc. from a single function. */
00052 void work_queue_task_specify_resources(struct work_queue_task *t, struct rmsummary *rm);

Generated on 14 Jul 2016 for cctools by  doxygen 1.6.1