Package iceprod :: Package client :: Module commands :: Class setstatus
[hide private]
[frames] | no frames]

Class setstatus

source code

object --+    
         |    
   Command --+
             |
            setstatus

Command: setstatus <dataset_id>[.<job>] <status>

Set the status of all jobs or a specific job from a dataset.
Can set the status of multiple jobs over multiple datasets at once.

Arguments:
  <dataset_id>  Specify the dataset.
  [.<job>]      (Optional) Specify the job within the dataset.
  <status>      Specify the status
                (WAITING, QUEUEING, QUEUED, PROCESSING, OK, ERROR,
                 READYTOCOPY, COPYING, SUSPENDED, RESET, FAILED,
                 COPIED, EVICTED, CLEANING, IDLE)
  
Returns:
  Returns the result of the mysql query (success or failure).
  Warning that if the dataset or job id is wrong it will likely
  print success because there was no mysql error.
  
Examples:
  Set status of all jobs in dataset to RESET  (dataset 1234, all jobs)
     status 1234 RESET
  
  Set status of individual jobs from different datasets
  (dataset 1234, job 10 to waiting and dataset 4321, job 20 to RESET)
     status 1234.10 WAITING 4321.20 RESET
  
  Set status of multiple datasets and jobs using commas
  (jobs 1, 3, and 5 from datasets 1234 and 1243 to OK)
     status 1234,1243.1,3,5 OK
  
  Set status of multile datasets and jobs using ranges
  (datasets 1234 - 1235, jobs 1 - 5 to SUSPENDED)
     status 1234-1235.1-5 SUSPENDED
 

Instance Methods [hide private]
 
Execute(self, shell) source code
 
_status(self, shell, dataset, job, status) source code
 
CheckArgs(self, args) source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __init__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]
  shortdoc = 'setstatus <dataset_id>[.<job>] <status> : Set stat...
hash(x)
  numArgs = 2
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

Execute(self, shell)

source code 
Overrides: Command.Execute

CheckArgs(self, args)

source code 
Overrides: Command.CheckArgs

Class Variable Details [hide private]

shortdoc

hash(x)

Value:
'setstatus <dataset_id>[.<job>] <status> : Set status of jobs.'