You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

update_job.go 696 B

3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
123456789101112131415161718192021222324252627282930
  1. package main
  2. import (
  3. "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo_tianhe/src/slurm"
  4. submit_job "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo_tianhe/src/slurm/submitjob"
  5. )
  6. import "os"
  7. import "strconv"
  8. import "fmt"
  9. func main() {
  10. if len(os.Args) < 4 {
  11. fmt.Printf("Synthax specify JobID, qos and partition \n")
  12. return
  13. }
  14. var ops submit_job.Update_job_options
  15. id, err := strconv.Atoi(os.Args[1])
  16. if err != nil {
  17. fmt.Printf("Invalid job id (no int) %s\n", os.Args[1])
  18. return
  19. }
  20. ops.Qos = os.Args[2]
  21. ops.Partition = os.Args[3]
  22. err2 := submit_job.Update_job(ops, uint32(id))
  23. if err2 != uint32(0) {
  24. fmt.Printf("error %s \n", slurm.GetErrorString(err2))
  25. }
  26. }

PCM is positioned as Software stack over Cloud, aiming to build the standards and ecology of heterogeneous cloud collaboration for JCC in a non intrusive and autonomous peer-to-peer manner.