cfbackend should use the retry decorator
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Duplicity |
New
|
Undecided
|
Unassigned |
Bug Description
I'm backing up to Rackspace, and I have quite a large backup set. Often when backing up, some sort of network exception gets raised. Sometimes, it's a connection timeout. Other times it's an SSL error. There are probably others, too, that I don't remember at the moment. Sometimes the error will occur early in the backup process. Other times it'll be near the end.
Of course, all these error conditions are transient, yet DD just reports a Backend exception and gives up. Instead, it should retry a number of times, especially if it has already connected in the current session. Networks are unreliable, and DD doesn't seem to realize this.
I'm currently using Ubuntu 11.10 with deja-dup 20.1-0ubuntu0.1 and duplicity 0.6.15-0ubuntu2. However, this problem has been going on for a long time and a number of versions.
I was having similar problems, but after running with DEJA_DUP_DEBUG=1 I could see on the logs that deja-dup (duplicity, in fact) did retry the upload 5 times (with a 30s sleep between them) before giving up. It'd be nice if there was a way to change that via an environment variable, but in the meantime you could change num_retries in /usr/share/ pyshared/ duplicity/ globals. py