Hallo,

Let me explain a problem I have with one of the methods from slurmrest api, 
namley the “jobs” method. When I issue the call:

curl -H "X-SLURM-USER-NAME:holka" -H "X-SLURM-USER-TOKEN:${SLURM_JWT}" 
http://172.20.102.31:6820/slurm/v0.0.37/jobs 
<http://172.20.102.31:6820/slurm/v0.0.37/jobs>

I receive the response (which is as expected an array of jobs). However, some 
of the jobs (I've noticed it for some of the PENDING jobs only yet) does not 
have the attribute “user_ name” set (On the othe hand the standard slurm 
cmdline utils like squeue display the username correctly). 

 …
    "jobs": [
     {
       "account": "ktokar",
       "accrue_time": 1640268477,
       "admin_comment": "",
       "array_job_id": 0,
       "array_task_id": null,
…
       ],
       "group_id": 1003,
       "job_id": 1097151,
       "job_resources": {
       },
       "job_state": "PENDING”,
…
       "tres_alloc_str": "",
       "user_id": 1081,
       "user_name": "",
       "wckey": "",
       "current_working_directory": "\/lustre\/home\/ktokar\/test\/NbO2"
     },
…

The same happens, when I call the method “job" with particular job id:

curl -H "X-SLURM-USER-NAME:holka" -H "X-SLURM-USER-TOKEN:${SLURM_JWT}" 
http://172.20.102.31:6820/slurm/v0.0.37/job/ 
<http://172.20.102.31:6820/slurm/v0.0.37/job/1097151>1097151 
<http://172.20.102.31:6820/slurm/v0.0.37/job/1097151>

We have a mobile app for users with some statistical and accounting data, that 
is relying on the slurm rest API and this inconsistency in the jobs method is 
causing us slight problems. We have currently version 21.08.4. Could anyone 
help with that?

Thanks and regards, Filip.


#  Filip Holka
#  HPC administration and monitoring
#  Computing Centre of Slovak Academy of Sciences
#  Dúbravská cesta 9
#  84535 Bratislava
#  Slovakia
#
#  Office phone: +421 2 3229 3110
#  Cell phone: +421 904 942 684
#  E-mail: filip.ho...@savba.sk

Reply via email to