rackspace/ruby-cloudfiles — pull request #69 by dnordstrom (2012-02-11 01:31:58+00:00)
Title: Auth connection fix

I've spoken with Rackspace support about authentication/connection problems earlier today and they weren't able to help me, so I started digging into the code. The problem was that I got a CloudFiles::Exception::Connection ("Unable to connect to...") error when trying to connect using Ruby 1.9.3 and Rails 3.2.

Turns out the SwiftClient class wasn't available, probably because the client.rb file was required within the CloudFiles module scope. This commit moves the require statement to outside the module, which solves the issue. A "require_relative" call also seems to solve the issue but is obviously not compatible with Ruby 1.8.7.

Feel free to use a different solution—just wanted to bring this to your attention in case others are having the same problem.

Have a nice weekend!