Wed, 17 Aug 2011

Windows Azure Storage Libraries in Many Languages

A recent question on the Windows Azure forums reminded me of just how many languages have libraries for accessing Windows Azure storage. Here are a few that I know about (some of which I’ve even contributed to):

  • C#/.NET: Microsoft.WindowsAzure.dll, azurestoragesamples – The former ships in the Windows Azure SDK and is by far the most popular library to access storage. The latter is written by David Pallmann, one of our Windows Azure MVPs, and it’s a side-by-side comparison of using the client library from the SDK versus building your own HTTP requests.
  • Python: winazurestorage.pySriram Krishnan (former Windows Azure team member) wrote the first version of this back in 2008, and since then I’ve been committing to it. It supports basic blob upload and download as well as table queries and queue creation/deletion. At this point, it needs something of an overhaul to make the classes more organized and consistent.
  • Ruby: waz-storage – This is a well-designed library that’s fairly complete. It supports all the blob operations (including block upload, which I’m proud to say I committed), all table operations (with continuation tokens), and the full queue API as well. I’m not aware of much of anything missing from this library. It’s what I use to power this blog and waz-cmd, my Ruby gem to interact with the Windows Azure Service Management API.
  • Perl: waz-storage-perl – This is a very minimal library written by yours truly. It only supports blob upload and download, but as with most of these libraries, the tricky part is constructing a correct authorization header, and I believe that work is done correctly. It should be easy to extend this to support operations like container creation/deletion and queue operations. (Table storage would require a bit more work.)
  • JavaScript (Node): waz-storage-js, wastorage.coffee – I don’t have much experience with waz-storage-js, which is a brand new library that supports a minimal set of blob operations. Wastorage.coffee is part of my smarxchat app, which supports table insertion and query and is tuned for speed. (I even made my own HTTP connection pooling library to go with it!) Neither of these is by any means “done,” but they both include some of the tricky parts of getting a library built: authorization and table entity serialization/deserialization.
  • Java: WindowsAzure4J – This is the result of a collaboration between Microsoft and Soyatec. It’s a fairly complete library.
  • PHP: phpazure – This is another collaboration, this time between Microsoft and RealDolmen. This library is also fairly complete and is based on the work of one of our Windows Azure MVPs, Maarten Balliauw.
  • Erlang: winazure.erl – This is a fairly minimal (just blob upload and download) library written in Erlang by Sriram Krishnan (the original author of the Python library).
  • Common LISP: cl-azure – Yeah, you read that correctly. Common LISP. I haven’t used this library at all, but I like that it exists.
  • Objective-C: watoolkitios-lib This library is part of the Windows Azure Toolkit for iOS, built by Wade Wegner and team. It supports two modes: making requests directly to storage, or proxying through a web service (so the storage key doesn’t have to be distributed to the client).
  • C#/VB on Windows Phone 7: The Windows Azure Toolkit for Windows Phone 7, also built by Wade and team, includes a storage library as well. Like the iOS library, this supports either directly accessing storage or proxying through a service. Look for the library under the WindowsPhoneCloud.StorageClient folder in the source.

Do you know of other libraries not on my list? I’ll  try to maintain this list as things get added and changed, so send me an email or tweet to me if you have a suggestion. (My contact info is on the right side of this blog.)

[UPDATE 2011-08-18] Added Objective-C and WP7.