Changeset 184


Ignore:
Timestamp:
08/03/05 16:34:28 (17 years ago)
Author:
bastiaans
Message:

daemon/togad.py:

  • Delete jobs from memory after written to dbase

plugin/togap.py:

  • Only accept job attrs changes for jobs in Q or R status
Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/daemon/togad.py

    r183 r184  
    477477                                mytime = int( jobinfo['reported'] ) + int( jobinfo['poll_interval'] )
    478478
    479                                 if mytime < self.heartbeat and jobid not in self.jobs_processed and jobinfo['status'] == 'R':
     479                                if (mytime < self.heartbeat) and (jobid not in self.jobs_processed) and (jobinfo['status'] == 'R'):
    480480
    481481                                        if not jobid in self.jobs_processed:
     
    492492                        for jobid in self.jobs_to_store:
    493493                                if self.jobAttrs[ jobid ]['status'] in [ 'R', 'Q', 'F' ]:
    494                                         self.ds.storeJobInfo( jobid, self.jobAttrs[ jobid ] )   
     494
     495                                        self.ds.storeJobInfo( jobid, self.jobAttrs[ jobid ] )
     496
     497                                        if self.jobAttrs[ jobid ]['status'] == 'F':
     498                                                del self.jobAttrs[ jobid ]
    495499
    496500                        debug_msg( 1, 'torque_xml_thread(): Done storing.' )
  • trunk/plugin/togap.py

    r174 r184  
    259259                        myAttrs['poll_interval'] = TORQUE_POLL_INTERVAL
    260260
    261                         if self.jobDataChanged( jobs, job_id, myAttrs ):
     261                        if self.jobDataChanged( jobs, job_id, myAttrs ) and myAttrs['status'] in [ 'R', 'Q' ]:
    262262                                jobs[ job_id ] = myAttrs
    263263
Note: See TracChangeset for help on using the changeset viewer.