Archive for the ‘Blob’ Category

Talk: Cloud Storage (Windows Azure Blob and Amazon S3) – Boston Azure User Group

July 1, 2013

On June 27, I had the privilege of speaking at the Boston Azure User Group in Boston, MA. The topic covered a in-depth discussion of Azure Blob Storage and Amazon S3.  It was an very interactive session with lots of great questions from the attendees.  The topics that we covered

  • Storage
    • Overview
    • Azure Blob Storage
    • Amazon S3
    • Comparing Azure Blob and Amazon S3
    • Benchmark comparisons for performance, stability, and scalability
  • CDN
  • Shared Access Signature
  • Best Practice
  • Resource

Click here to download the power point presentation.

click here to download the sample project

Please note you need to set the keys in config file prior to executing the samples.  I also removed .PEM and KEY file for signing amazon URL.  You can create your own files and change the code to use your PEM and KEY file for signing URLs.

 

 

Windows Azure SDK 1.7 and new features

June 21, 2012

NHDN Cloud Computing talk Jun 20th, 2012.

We discussed All new features from Jun 7th announcement and SDK 1.7.  How to utilize all the cloud services, cloud storage and virtual machine and the web sites.

click here to download the presentation

click here to download the sample code on caching and service bus ( before running the sample replace the value for appsetting keys )

Cloud Storage (Azure Blob and Amazon S3)

April 19, 2012

Today @NHDN Cloud Computing User group meeting @ Daniel Webster College (DWC) Nashua, we talked all about the cloud storage.  Talk includes the overview of cloud storage including Azure Blob and Amazon S3.  Blob storage, Azure Drive and S3 using REST and API.

You can download the presentation here

download the sample source here

Azure Application Drive size limit and Running Multiple WebSites in the cloud

January 13, 2012

First thing i tried was i deployed multiple websites (with minimum templates and config) in one packages.  And then from the background task i was downloading all the dynamic templates (*.aspx, *.ascx)  from the corresponding blob and copying to site root.  I got an exception because it exceed the size limit of 1GB.  In my project every site consumed 300MB worth of dynamic templates including some static files.  I had 10+ sites and hence i need atleast 3GB application drive size but by default Azure will provide only 1GB of application drive either E or F.  Unfortunately this cannot be changed.  Then I tried this work arounds proposed by microsoft support person.  it seems to be working for me but yet to run the performance test…

  1. Create the empty or minimum files with package for all the sites so that your package is deployed
  2. Move the rest of the dynamic template or static files to blob storage.
  3. Run the background task (you must configure this in your package)
    1. Use Local Storage in your code and download all the data in specific folders at local storage
    2. Windows Server 2008 supports Symbolic links and this way even when your files are stored in Local Storage, still they appear to be inside the Application drive.
    3. After you download the blob from Azure Storage please create symbolic link from your application folder to local storage.
    4. Use mklink command to create the symbolic link to the folder (ex.,)

i.            Mklink /D <targetdrive> <source drive>

ii.            Ex., MKLINK /d E:\Sitesroot\help  C:\Resource\help

iii.            MKLINK /d E:\Sitesroot\1\help  C:\Resource\help

iv.            MKLINK /d E:\Sitesroot\2\help  C:\Resource\help

You can find related documents from the following url:

http://msdn.microsoft.com/en-us/library/gg433110.aspx

http://en.wikipedia.org/wiki/NTFS_symbolic_link

Udai @ WPC, Los Angeles

July 18, 2011

I attend the WPC 2011 @ Los Angeles, July 10-14,2011.  Presented Ektron in Azure @ Azure Theater ISV booth between 11.30 AM – 12.30 PM on July 11th.  This demo includes the synchronizing data between on-premises and cloud both Data(SQL Server to SQL Azure) and Blob (Filesystem to Azure Blob store), AppFabric caching, using FileSystem API to write data in files and blobs, etc., A public  Press release also available.

Case-sensitive Azure BLOB Urls-Fix

March 25, 2011

Blob Urls are case sensitive.  If you had ever stored file or image in a windows azure blob container then you need to access the url in exact case otherwise you will get blob NOT found error.  To resolve this issue

While writing blob always use lower case.

While reading blob convert your url to lowercase and redirect to blob.

For example you can write HttpHandler or HttpModule to redirect to your blob after.  Here is the simple code snippet.

public class BlobModule : IHttpModule    {
public void Dispose()        {            //throw new NotImplementedException();        }
public void Init(HttpApplication context)        {            context.BeginRequest += new EventHandler(context_BeginRequest);        }
void context_BeginRequest(object sender, EventArgs e)        {

string contextUrl=HttpContext.Current.Request.Url.LocalPath.ToLower();

if (contextUrl.Contains(“myfile/”))            {

string blobUrl = RoleEnvironment.GetConfigurationSettingValue(“BlobOrCdnUrl”) + RoleEnvironment.GetConfigurationSettingValue(“ContainerName”) + contextUrl;                HttpContext.Current.Response.Redirect(blobUrl, true);

}        }    }

And then from your web.config you can add the following snippet under module.

<modules runAllManagedModulesForAllRequests=”true”>

<add name=”myname” type=”mynamespace.blobmodule,myassembly” preCondition=”integratedMode” />

</modules>

Thats it.  Now your blob can be accessed using mixed url.