From: Michael Vrable Date: Mon, 18 Oct 2010 21:48:47 +0000 (-0700) Subject: Add timeout on cleaner S3 retry. X-Git-Url: https://git.vrable.net/?a=commitdiff_plain;h=2223a4a4ec1ea91f30e345179cea751c022e5b99;p=bluesky.git Add timeout on cleaner S3 retry. --- diff --git a/cleaner/cleaner b/cleaner/cleaner index 9103769..c4b1222 100755 --- a/cleaner/cleaner +++ b/cleaner/cleaner @@ -8,7 +8,7 @@ # Copyright (C) 2010 The Regents of the University of California # Written by Michael Vrable -import base64, os, re, struct, sys +import base64, os, re, struct, sys, time import boto from boto.s3.key import Key @@ -75,6 +75,7 @@ def retry_wrap(method): except: print >>sys.stderr, "S3 operation failed, retrying..." self.connect() + time.sleep(1.0) return method(self, *args, **kwargs) return wrapped