Skip to main content

Posts

Showing posts with the label Microsoft Azure

Understanding Block Blobs, Append Blobs, and Page Blobs

The storage service offers three types of blobs, block blobs, append blobs, and page blobs. You specify the blob type when you create the blob. Once the blob has been created, its type cannot be changed, and it can be updated only by using operations appropriate for that blob type, i.e., writing a block or list of blocks to a block blob, appending blocks to a append blob, and writing pages to a page blob. All blobs reflect committed changes immediately. Each version of the blob has a unique tag, called an ETag, that you can use with access conditions to assure you only change a specific instance of the blob. Any blob can be leased for exclusive write access. When a blob is leased, only calls that include the current lease ID can modify the blob or (for block blobs) its blocks. Any blob can be duplicated in a snapshot.  Block Blob Block blobs let you upload large blobs efficiently. Block blobs are comprised of blocks, each of which is identifi...

Append Blob In Azure

An append blob is a new type of blob, introduced with version 5.x of the Azure storage client library for .NET. An append blob is optimized for append operations, such as logging. Like a block blob, an append blob is comprised of blocks, but when you add a new block to an append blob, it is always appended to the end of the blob. You cannot update or delete an existing block in an append blob. The block IDs for an append blob are not exposed as they are for a block blob. Each block in an append blob can be a different size, up to a maximum of 4 MB, and an append blob can include a maximum of 50,000 blocks. The maximum size of an append blob is therefore slightly more than 195 GB (4 MB X 50,000 blocks). The example below creates a new append blob and appends some data to it, simulating a simple logging operation. Copy //Parse the connection string for the storage account. CloudStorageAccount storageAccount = CloudStorageAccount . Parse ( Microsoft . Azure . CloudConfig...

Managing Large Web Server Farms: Microsoft's AutoPilot

Whenever you read stories about how Web companies like Facebook have  10,000 servers including 1800 database servers  or that  Google has one million servers , do you ever wonder how the system administrators that manage these services deal with deployment, patching, failure detection and system repair without going crazy? This post is the first in a series of posts that examines some of the technologies that successful Web companies use to manage large Web server farms. Last year,  Michael Isard  of Microsoft Research wrote a paper entitled  Autopilot: Automatic Data Center Management  which describes the technology that Windows Live and Live Search services have used to manage their server farms. The abstract of his paper is as follows Microsoft is rapidly increasing the number of large-scale web services that it operates. Services such as Windows Live Search and Windows Live Mail operate from data centers that contain  tens or hundreds of t...

Accessing Windows Azure Blob Storage using jQuery

Did you know it was possible to access the Windows Azure Blob Storage directly from JavaScript, for example using jQuery? At first, it sounds obvious, since Blobs are after all acessible from a public URL… But in practice, there is a very big hurdle: the Web browser’s Same Origine Policy or SOP , that restricts JavaScript code to accessing resources originating from the same site the script was loaded from. This means that you will never be able to load a Windows Azure Blob using XMLHttpRequest for example! Fortunately, there is a popular workaround called JSONP (“JSON with Padding”). The idea behind this technique is that the script tag is not submitted to the SOP: an HTML page can thus load a JavaScript file from any site. So, if you expose your data in an “executable” form in JavaScript, a page will be able to load this data using a script tag. For example: <script type="text/javascript" src=" http://toto.com/exemple.jsonp" > </script> But how can y...

How to Use the Service Bus Relay Service

This guide shows you how to use the Service Bus relay service. The samples are written in C# and use the Windows Communication Foundation API with extensions contained in the Service Bus assembly that is part of the .NET Azure SDK. For more information on the Service Bus relay, see the "Next Steps" section. What is the Service Bus Relay The Service Bus  Relay  service enables you to build  hybrid applications  that run in both an Azure datacenter and your own on-premises enterprise environment. The Service Bus relay facilitates this by enabling you to securely expose Windows Communication Foundation (WCF) services that reside within a corporate enterprise network to the public cloud, without having to open up a firewall connection or requiring intrusive changes to a corporate network infrastructure. The Service Bus relay allows you to host WCF services within your existing enterprise environment. You can then delegate listening for incoming sessions and re...