예제 #1
0
 def timeout(self, task):
     if self.numRetries == ASYNC_REQUEST_INFINITE_RETRIES:
         return Task.again
     elif self.numRetries > 0:
         self.numRetries -= 1
         return Task.again
     else:
         self.sendRejectCode(RejectCode.TIMEOUT)
         AsyncRequest.timeout(self, task)
예제 #2
0
    def timeout(self, task):
        for timeoutInfo in self.timeoutCallback:
            apply(timeoutInfo[0], timeoutInfo[1] + [self])

        AsyncRequest.timeout(self, task)
    def timeout(self, task):
        for timeoutInfo in self.timeoutCallback:
            apply(timeoutInfo[0], timeoutInfo[1] + [self])

        AsyncRequest.timeout(self, task)