Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
SSLError when sending several files #5
We talked about this error on the django-storages bitbucket... I migrated my app to django-cumulus and I still have the exception being rise after some time.
I don't think it is a timeout problem because it happens on a unpredictable intervals. To be honest with you, on Friday, when I migrate about 1,000 files to a cloudfiles container, i got this error several times. Today I'm trying to reproduce the error and it happens only once, much less than on Friday.
To fix it, I'm deleting the connection and the container attributes from the storage instance, it forces the storage to make a new connection.
What do you think about make it happens by default inside CloudFilesStorage?
I talked with rackspace and they said it is a timeout problem.
The default value for timeout is 5 and they suggested me to set it to 15. I think it is 15 seconds of timeout for each request but it is not clear to me, I asked rackspace to clarify and, since they reply me, I will document it on a python-cloudfiles docstring.
I did a small script that uses only the python-cloudfiles lib (without cumulus) and I could reproduce the error generally before 14 or 15 requests. After I updated the timeout on the connection constructor, I couldn't reproduce the error again. I stopped manually on 50 requests.
It is possible to the set timeout on the connection_kwargs on the CloudFilesStorage constructor, anyway, I think we should have a way to set the timeout on the django settings file.
How about it?