Archive

Posts Tagged ‘Azure’

Azure Set custom Cache Expiration on items stored in a blob

// cache time
var cacheMaxAge = (60 * 60);

 // 3600 second (1 hour) caching// file upload
blobFile.UploadByteArray(data.Data);

// setting Content-Type
blobFile.Properties.ContentType = contentType;

// setting cache for CDN
blobFile.Properties.CacheControl = "max-age=" + cacheMaxAge;

blobFile.SetProperties();

 

Advertisements
Categories: DEV Tags: ,

Mocking Azure TableStorage

In these links you will understand how to Mock Azure Table Storage…

Unit Testing and Azure is not an easy job, but it is worth doing it sometimes.

http://blogs.southworks.net/fboerr/2010/07/23/windows-azure-storage-tdd-and-mocks/

http://stackoverflow.com/questions/4636248/how-to-fake-azure-table-storage-in-net-for-unit-testing

http://stackoverflow.com/questions/3291629/unit-testing-code-for-azure

Categories: DEV, Test Tags: ,

Running an EXE in an Azure WebRole

As you can Image running an Exe file on Azure is not a “best practice” bust sometimes you don’t have any other option….

In these 2 articles explain how to use the Local Storage…

http://www.codeproject.com/Articles/331425/Running-an-EXE-in-a-WebRole-on-Windows-Azure

http://stackoverflow.com/questions/5915870/running-native-code-on-azure

Categories: DEV Tags: