Category Archives: Azure

Programming Windows Azure eBook for $20

Programming Windows Azure is a recent book which is published by O’Reilly.  So far there are not many books covering Azure specifically so this was seen as a positive move.  It is written by Sriram Krishnan who works for Microsoft on the
Azure team.

When I first heard about this book, I searched Amazon for a Kindle edition.  Since last December I have been using the Kindle I have more and more.  Unfortunately Amazon does not have this format.

However, O’Reilly does have a program whereby you can buy the electronic versions of their books.  In this offer, you can get DRM-free copies of the book in formats for all the popular devices (PDF, iPhone, iPad, Android, Kindle, Sony Reader).

Knowing that the Kindle would work, I then discovered an excellent discount code.  Normally the Azure book costs $39.95 but with the discount code “4cast” the price is cut in half.  This obviously is to promote the new digital formats.

Once I purchased the book for $20, I could then download the book to my machine.  The next trick was to send the book to the Kindle.  This works by just sending from a trusted email account (for the Kindle) to the Kindle email address reserved during initial setup.  Typically the name is something like jeff@kindle.com .  The simple act of sending the book as an attachment to this Kindle email address is enough to start the wireless transfer to your Kindle.  The catch is that it needs to be coming from a trusted email address and that the transfer is going to cost money (on whispernet).

The Azure book is about 2.7MB in the Kindle format which happened to be bigger than the default maximum cost for an email transfer.  It costs around $1 per MB to download to the Kindle.

The default can be changed if you go to Amazon and select “Manage My Kindle” for the Kindle home page.

Kindle help:

Limit section to be updated:

Once your limit is high enough, it will get through.  In fact, it probably took less than 30 minutes.  This is a real plus for a number of reasons.

  • Virtual books means no shipping costs from US to Australia
  • It is so fast it is hard to believe it worked
  • The massive computer books are now light and easy to read anywhere (not just for reference)

The charge on the transfer would have been around $3 so the total cost was $23.  If I had wanted, I could have just transferred the book using USB.  Or, if I had a newer Kindle, I could have used WiFi.  Both of those options are supposed to be free.

I’m still reading the book so I cannot given an accurate review.  However, the book covers some of the original thinking for Azure (used to be called Project Red Dog) and how some of the features have evolved.  The most useful bit so far is running native code from an existing web role to supporting things like PHP.

It looks to be a great summary of Azure and even though it might not be perfectly up to date, it still provides plenty of useful information.

Azure Development Fabric with HTTPS

127.0.0.1

It always helps to have tips for common problems. Lately I’ve been looking for helpful hints related to Azure. Usually there is something to be found with the help of Google. Sometimes it is spread around a few different places for one topic.

The hints for this blog post is using HTTPS with Azure Development Fabric. Here are the things I wish someone had told me.

  1. You can select HTTPS on the Web Role properties for an endpoint. You cannot select a hostname to go with this.
  2. All connections are based on using 127.0.0.1 for the server web address.
  3. If IIS is installed (or some other web server), the Windows Azure Web Server will pick the next highest port (either HTTP 81 or HTTPS 444).
  4. The development web server for Azure is not connected to IIS and this can cause confusion sometimes.
  5. Starting the code from Visual Studio will start up to two instances of web browser based on HTTP and HTTPS.  You can control which start from the properties for the web role.
  6. The Azure SDK automatically creates a certificate for 127.0.0.1 when it is first run in Dev Fabric.  This certificate is the same for everyone and it appears to be impossible to switch to a different certificate for Dev Fabric.
  7. Do not ever delete the 127.0.0.1 certificate using the certificate management tools unless you want to re-install the Azure SDK.
  8. You can get the 127.0.0.1 certificate to be trusted by copying the certificated to trusted root (very important for your sanity).
  9. Typically the address for HTTPS is https://127.0.0.1:444/ for your web role.
  10. It is possible to use HTTPS with 127.0.0.1 and have it work with Windows Identity Framework and ADFS.
  11. The settings in the configuration for certificates and the SSL certificate only apply to Azure and not Dev Fabric

If you are only interested in providing HTTPS on Azure, there is a really good post here.

Initially I was only focusing on running the web role without the Dev Fabric.  This gives more flexibility with the configuration (server name and real IIS) but it simply does not work with the Dev Fabric.

After a bit of churn, the code now conforms to using 127.0.0.1 and luckily this should make it easier to share code with team workers.

The philosophy, perhaps, was to make the code not care about the host in any way so that it would easily be published to Azure.

HTTPS is key to supporting Federated Identity.  Without it, there is not much hope for passive federation.