Ignore:
Timestamp:
03/28/13 11:44:36 (11 years ago)
Author:
jripsl
Message:
  • add static class initialisation function.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Monitoring/RunChecker/runchecker

    r840 r841  
    1919        @classmethod 
    2020        def check(cls): 
    21                 simulation=dao.getSimulation() 
     21                simulation=dao.get_simulation() 
     22 
     23                m=simulation.get_last_message() 
     24 
     25                if (current_date-m.timestamp).days > 2: 
     26                         
     27                        print "simulation too old" 
     28 
     29                messages=simulation.get_messages() 
     30 
     31                for m in messages: 
     32 
     33                        pass 
     34                         
     35 
    2236  
    2337def main(): 
     
    3246                sys.exit(1) 
    3347 
    34         # open DB connections 
    35          
    36         # initialize logger 
     48        SMON.init_singleton() 
    3749 
    38         #  
     50        RunChecker.check() 
    3951 
    40  
    41         # close DB connections 
    42  
     52        SMON.free_singleton() 
    4353 
    4454if __name__ == '__main__': 
Note: See TracChangeset for help on using the changeset viewer.