Cloud storage

We are all aware of SQL Server (if not, do not worry). Azure SQL is just SQL Server deployed on Azure. We will not be discussing Azure SQL in this section as we will be using Azure SQL in the next chapter and hence will be discussing it at length then. We will check out the storage accounts. Storage accounts can store hundreds of terabytes (roughly speaking 1 Terabyte = 1,000 Gigabytes) of data. We will discuss how to use Azure storage as a place to keep uploaded files for our web application and how we can enable users to download files from storage by creating and handing out what's known as a shared access signature (SAS). So, lets get started.

In the Azure portal, click on New and select Storage and then click Storage account - blob, file, table, queue, as shown in the following screenshot:

 

There is also a link to a Quickstart tutorial, which I would highly recommend as it has great getting-started videos and tutorials from the leading tech evangelists to get you up and running with Azure storage. On clicking Storage account - blob, file, table, queue, a new blade named Create storage account will display, as shown in the following screenshot: 

In the blade, enter the required fields:

  • Name: This should comprise 3-24 characters in lowercase or numeric text that should be unique across all Azure storage, as it is exposed on .core.windows.net.
  • Deployment model: This should be kept as Resource manager.
  • Account kind: This can be a general storage V1 or V2 or dedicated blob storage. We will keep it as general storage.
  • Performance: This can be chosen as Premium or Standard as required.
  • Secure transfer required: This should be Enabled for any serious web app.
  • Resource group: This can be created new or reused.
  • Location: Select the location which is nearest to your business requirement.

You can choose to pin the storage account to the dashboard by checking the Pin to dashboard checkbox. Click Create. After a while, the storage account will be created. Once the storage account is created, click on the pinned tile on the dashboard and it will take you to the storage account overview blade, which summarizes the storage account details. The important thing to note is in the middle of the blade and lists the different types of storage, as shown in the following screenshot:

So we can use four types of storage with the storage account. Let's briefly discuss these:

  • Blob storage: Blob is an abbreviation of Binary large object. We can store any type of file in blob storage. 
  •  Table storage: Table storage is a no-SQL database and is similar to a document DB but instead of storing documents, table storage is optimized for storing key value pairs. Table storage is really cheap and it's a good place to store large volumes of data. 
  • File storageFile storage allows us to set up Server Message Block (SMB 3.0 protocol) file shares in the cloud. This storage is preferred generally when we have an existing application that needs to be migrated to Azure and the application already uses file shares.
  • Queue storageQueues allow us to store and retrieve messages. And they are an important technology to have if we want to build reliable high-scale websites because they allow us to put a buffer between an application and the backend services that it uses. 

Blobs and queues are more frequently used and we shall be using blob storage in our next chapter when we develop our movie booking site, so we will conclude our brief discussion of storage. How to upload and download data from storage using an SAS token is something we will see in the next chapter in detail. This brings us to the end of this discussion and chapter on cloud introduction. We should now be ready to develop and deploy in Azure, which we will do in the next chapter.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.116.239.195