Made timeout watcher provide AirtimeInstnace

This commit is contained in:
Rudi Grinberg 2012-11-15 12:12:47 -05:00
parent fa66f33ffa
commit 5073ced732
1 changed files with 3 additions and 3 deletions

View File

@ -1,5 +1,4 @@
# -*- coding: utf-8 -*-
import threading
import time
import copy
@ -9,15 +8,16 @@ from media.monitor.exceptions import BadSongFile
from media.monitor.eventcontractor import EventContractor
from media.monitor.events import EventProxy
from media.monitor.request import ThreadedRequestSync, RequestSync
from media.saas.thread import InstanceInheritingThread
class TimeoutWatcher(threading.Thread,Loggable):
class TimeoutWatcher(InstanceInheritingThread,Loggable):
"""
The job of this thread is to keep an eye on WatchSyncer and force a
request whenever the requests go over time out
"""
def __init__(self, watcher, timeout=5):
self.logger.info("Created timeout thread...")
threading.Thread.__init__(self)
super(TimeoutWatcher, self).__init__()
self.watcher = watcher
self.timeout = timeout