| 110 | |
| 111 | #http caller thread |
| 112 | class HTTPThread(threading.Thread): |
| 113 | def run(self): |
| 114 | try: |
| 115 | while flag<2: |
| 116 | code=httpcall(url) |
| 117 | if (code==500) & (safe==1): |
| 118 | set_flag(2) |
| 119 | except Exception, ex: |
| 120 | pass |
| 121 | |
| 122 | # monitors http threads and counts requests |
| 123 | class MonitorThread(threading.Thread): |