save works
This commit is contained in:
parent
ef95cea41f
commit
c1e42b1ee2
6 changed files with 202 additions and 108 deletions
|
|
@ -21,8 +21,11 @@ typedef int (*plugin_init_fn_t)(void*);
|
|||
typedef void (*plugin_fini_fn_t)(void*);
|
||||
|
||||
/* plugin function to elect job to be scheduler */
|
||||
typedef int64_t (*plugin_job_election_fn_t)(void*);
|
||||
typedef void* (*plugin_job_election_fn_t)(void*);
|
||||
|
||||
typedef int (*plugin_begin_session_fn_t)(void*);
|
||||
|
||||
typedef int (*plugin_end_session_fn_t)(void*);
|
||||
/* allocation function of job */
|
||||
typedef xce_job_alloc_t* (*plugin_job_allocate_fn_t)(void*, int64_t*);
|
||||
|
||||
|
|
@ -34,14 +37,16 @@ typedef struct {
|
|||
} plugin_hooks_t;
|
||||
|
||||
typedef struct {
|
||||
char* name;
|
||||
void* sched;
|
||||
plugin_init_fn_t init_fn;
|
||||
plugin_fini_fn_t fini_fn;
|
||||
plugin_job_election_fn_t job_elect_fn;
|
||||
plugin_job_allocate_fn_t job_alloc_fn;
|
||||
plugin_hooks_t hooks;
|
||||
plugin_data_t data;
|
||||
char* name;
|
||||
void* sched;
|
||||
plugin_init_fn_t init_fn;
|
||||
plugin_fini_fn_t fini_fn;
|
||||
plugin_begin_session_fn_t begin_session_fn;
|
||||
plugin_end_session_fn_t end_session_fn;
|
||||
plugin_job_election_fn_t job_elect_fn;
|
||||
plugin_job_allocate_fn_t job_alloc_fn;
|
||||
plugin_hooks_t hooks;
|
||||
plugin_data_t data;
|
||||
} xce_sched_plugin_t;
|
||||
|
||||
extern int plugin_register(void*, void*);
|
||||
|
|
@ -50,6 +55,8 @@ extern int plugin_config_update(void*, xce_conf4sched_t*);
|
|||
extern int plugin_queue_update(void*, xce_sched_queue_t*);
|
||||
extern int plugin_job_update(void*, xce_sched_job_t*);
|
||||
extern int plugin_worker_update(void*, xce_sched_worker_t*);
|
||||
extern int plugin_begin_session(void*);
|
||||
extern int plugin_end_session(void*);
|
||||
|
||||
extern int register_fcfs(void*);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue