improve resmgr/jobmgr/qmgr/workermgr
This commit is contained in:
parent
2362b32825
commit
8d78f0cbeb
12 changed files with 161 additions and 575 deletions
|
|
@ -76,32 +76,6 @@ typedef struct {
|
|||
typedef struct {
|
||||
} metrics_t;
|
||||
|
||||
typedef struct {
|
||||
xce_queue_t queue;
|
||||
} queue_t;
|
||||
|
||||
typedef struct {
|
||||
xce_job_t job;
|
||||
} job_t;
|
||||
|
||||
typedef struct {
|
||||
mylock_t lock;
|
||||
htab_t htab;
|
||||
zarray_t jobs;
|
||||
} jobmgr_t;
|
||||
|
||||
typedef struct {
|
||||
mylock_t lock;
|
||||
htab_t htab;
|
||||
zarray_t workers;
|
||||
} workermgr_t;
|
||||
|
||||
typedef struct {
|
||||
mylock_t lock;
|
||||
htab_t htab;
|
||||
zarray_t queues;
|
||||
} qmgr_t;
|
||||
|
||||
typedef struct {
|
||||
mylock_t lock;
|
||||
endpoint_t* ep;
|
||||
|
|
|
|||
|
|
@ -10,6 +10,7 @@
|
|||
|
||||
#include "xlist.h"
|
||||
#include "zarray.h"
|
||||
#include "netio.h"
|
||||
|
||||
#define XCE_VAL_STRING (0)
|
||||
#define XCE_VAL_NUMERIC (1)
|
||||
|
|
@ -96,11 +97,6 @@ typedef struct {
|
|||
char** data;
|
||||
} xce_strlist_t;
|
||||
|
||||
typedef struct {
|
||||
char* name;
|
||||
char* key;
|
||||
} xce_peerinfo_t;
|
||||
|
||||
typedef struct {
|
||||
char* name;
|
||||
char* value;
|
||||
|
|
@ -267,6 +263,21 @@ typedef struct {
|
|||
int64_t duration;
|
||||
} xce_alloc_t;
|
||||
|
||||
typedef struct {
|
||||
uint64_t jobid;
|
||||
xce_alloc_t alloc;
|
||||
double used;
|
||||
} res_usage_t;
|
||||
|
||||
typedef struct {
|
||||
xce_worker_t host;
|
||||
char hostkey[XCE_MAXKEY_LEN];
|
||||
endpoint_t* ep;
|
||||
int idx;
|
||||
zarray_t usages;
|
||||
} worker_t;
|
||||
|
||||
|
||||
typedef struct {
|
||||
char* host;
|
||||
int nallocs;
|
||||
|
|
@ -431,6 +442,11 @@ typedef struct {
|
|||
xce_job_preason_t* pend_reasons;
|
||||
} xce_job_t;
|
||||
|
||||
typedef struct {
|
||||
xce_job_t job;
|
||||
} job_t;
|
||||
|
||||
|
||||
typedef struct {
|
||||
int count;
|
||||
xce_job_t** data;
|
||||
|
|
@ -474,6 +490,10 @@ typedef struct {
|
|||
char* autopscaler;
|
||||
} xce_queue_t;
|
||||
|
||||
typedef struct {
|
||||
xce_queue_t queue;
|
||||
} queue_t;
|
||||
|
||||
typedef struct {
|
||||
int count;
|
||||
xce_queue_t** queues;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue