Package iceprod :: Package server :: Module server :: Class MonitorCGIProxy
[hide private]
[frames] | no frames]

Class MonitorCGIProxy

source code

Monitor --+    
          |    
 MonitorCGI --+
              |
             MonitorCGIProxy

XMLRPC server class for monitoring jobs job connect to server from compute nodes and make status updates Similar to Monitor class but runs CGI embeded in existing HTTP server

Instance Methods [hide private]
 
__init__(self, cfg) source code
 
monitor(self) source code
 
getvalue(self, key)
Retrive dictionary entry
source code
 
getfile(self, key, dataset_id=0)
Retrive dictionary entry
source code
 
get_tarball(self, metaproject_name, metaproject_version, platform, gccversion, ppc=0)
Get best matching tarball in file repository @param metaproject_name @param metaproject_version @param platform @param gccversion
source code
 
getconfig(self, dataset)
Download configuration from database
source code
 
getmetadata(self, dataset)
Download configuration from database
source code
 
start(self, hostname, dataset=0, job_id=0, key='', grid=0)
Change the status of a job to indicate it is currently running @param : hostname @param : dataset simdb_id @param : job_id @param : key a passkey to prevent processes from overriding entries
source code
 
ping(self, dataset_id, job_id, host, key='', tray=0, iter=0)
Let server know that job is still running
source code
 
finish(self, dataset_id, job_id, stats, key='', mode=0)
Update monitoring for job and write statistics
source code
 
copying(self, dataset_id, job_id, key='')
Update monitoring for job and write statistics
source code
 
abort(self, job_id, dataset_id, error, errormessage='', key='', stats='(d.')
Reset any pending jobs to they get reprocesses.
source code
 
AddFileURL(self, dataset_id, job_id, url, md5sum, filesize, transfertime, key='')
Add or change the global location of a file
source code
 
get_storage_url(self, dataset_id, queue_id, passkey='', storage_type='INPUT') source code
 
multipart_job_start(self, dataset_id, queue_id, key='')
Change the status of a job to indicate it is currently running @param : dataset simdb_id @param : job_id @param : key a passkey to prevent processes from overriding entries
source code
 
multipart_job_finish(self, dataset_id, queue_id, key='') source code
 
task_start(self, dataset_id, queue_id, taskname, tray, iter, hostname, key='') source code
 
task_copying_input(self, task_id, key='') source code
 
task_processing(self, task_id, key='') source code
 
task_copying_output(self, task_id, key='') source code
 
task_update_status(self, task_id, status, key='') source code
 
task_abort(self, task_id, key='') source code
 
task_finish(self, task_id, stats, key='') source code
 
echo(self, msg) source code

Inherited from Monitor: SetSemaphore, register_functions, register_module, serve_forever

Method Details [hide private]

__init__(self, cfg)
(Constructor)

source code 
Overrides: Monitor.__init__

monitor(self)

source code 
Overrides: Monitor.monitor

getvalue(self, key)

source code 

Retrive dictionary entry

Returns:
string value
Overrides: Monitor.getvalue
(inherited documentation)

getfile(self, key, dataset_id=0)

source code 

Retrive dictionary entry

Returns:
string value
Overrides: Monitor.getfile
(inherited documentation)

get_tarball(self, metaproject_name, metaproject_version, platform, gccversion, ppc=0)

source code 

Get best matching tarball in file repository @param metaproject_name @param metaproject_version @param platform @param gccversion

Returns:
string path to tarball
Overrides: Monitor.get_tarball
(inherited documentation)

getconfig(self, dataset)

source code 

Download configuration from database

Overrides: Monitor.getconfig
(inherited documentation)

getmetadata(self, dataset)

source code 

Download configuration from database

Overrides: Monitor.getmetadata
(inherited documentation)

start(self, hostname, dataset=0, job_id=0, key='', grid=0)

source code 

Change the status of a job to indicate it is currently running @param : hostname @param : dataset simdb_id @param : job_id @param : key a passkey to prevent processes from overriding entries

Returns:
dataset_id,nproc,procnum
Overrides: Monitor.start
(inherited documentation)

ping(self, dataset_id, job_id, host, key='', tray=0, iter=0)

source code 

Let server know that job is still running

Parameters:
  • dataset_id - runconfig index
  • job_id - process number within dataset
  • host - hostname of computing node
Overrides: Monitor.ping
(inherited documentation)

finish(self, dataset_id, job_id, stats, key='', mode=0)

source code 

Update monitoring for job and write statistics

Parameters:
  • dataset_id - runconfig index
  • job_id - process number within dataset
  • stats - dictonary of stat entries
  • key - security passkey assigned to job
  • mode - if true, finalize job and set status to COPIED instead of setting its status to READYTOCOPY
Overrides: Monitor.finish
(inherited documentation)

copying(self, dataset_id, job_id, key='')

source code 

Update monitoring for job and write statistics

Parameters:
  • dataset_id - runconfig index
  • job_id - process number within dataset
  • stats - dictonary of stat entries
Overrides: Monitor.copying
(inherited documentation)

abort(self, job_id, dataset_id, error, errormessage='', key='', stats='(d.')

source code 

Reset any pending jobs to they get reprocesses. This would typically be run at startup in case the daemon crashed previously.

Overrides: Monitor.abort
(inherited documentation)

AddFileURL(self, dataset_id, job_id, url, md5sum, filesize, transfertime, key='')

source code 

Add or change the global location of a file

Overrides: Monitor.AddFileURL
(inherited documentation)

get_storage_url(self, dataset_id, queue_id, passkey='', storage_type='INPUT')

source code 
Overrides: Monitor.get_storage_url

multipart_job_start(self, dataset_id, queue_id, key='')

source code 

Change the status of a job to indicate it is currently running @param : dataset simdb_id @param : job_id @param : key a passkey to prevent processes from overriding entries

Returns:
dataset_id,nproc,procnum
Overrides: Monitor.multipart_job_start
(inherited documentation)

multipart_job_finish(self, dataset_id, queue_id, key='')

source code 
Overrides: Monitor.multipart_job_finish

task_start(self, dataset_id, queue_id, taskname, tray, iter, hostname, key='')

source code 
Overrides: Monitor.task_start

task_copying_input(self, task_id, key='')

source code 
Overrides: Monitor.task_copying_input

task_processing(self, task_id, key='')

source code 
Overrides: Monitor.task_processing

task_copying_output(self, task_id, key='')

source code 
Overrides: Monitor.task_copying_output

task_update_status(self, task_id, status, key='')

source code 
Overrides: Monitor.task_update_status

task_abort(self, task_id, key='')

source code 
Overrides: Monitor.task_abort

task_finish(self, task_id, stats, key='')

source code 
Overrides: Monitor.task_finish

echo(self, msg)

source code 
Overrides: Monitor.echo