Can we directly connect the Windows Azure mobile service to the BLOB repository?

I have a question about how I can implement Windows Azure and Blob storage using the Windows 8 application (Javascript). Can we directly connect the Windows Azure mobile service to the BLOB repository?

+4
source share
2 answers

Yes, you can access the blob repository through Windows Azure Mobile Services. In essence, you are going to work with the blob repository through server scripts. You are about to use the "azure" module in the Windows Azure SDK for Node.js.

If you copied the following into a script, you will get a link to the Windows Azure blob, after which you can request it or paste data into it.

var azure = require('azure'); var blobService = azure.createBlobService("<< account name >>", "<< access key >>"); 

You can check Scott Guthrie's post reporting this here: http://weblogs.asp.net/scottgu/archive/2012/10/16/windows-azure-mobile-services-new-support-for-ios-apps- facebook-twitter-google-identity-emails-sms-blobs-service-bus-and-more.aspx .

This is a post detailing the use of the Scheduler to run a scheduled script that backs up your data in memory storage: http://www.thejoyofcode.com/Using_the_scheduler_to_backup_your_Mobile_Service_database.aspx

This is a post on how to upload an image to blob from mobile services: http://www.nickharris.net/2012/11/how-to-upload-an-image-to-windows-azure-storage-using-mobile -services /

There is more information about working with blobs here: http://www.windowsazure.com/en-us/develop/nodejs/how-to-guides/blob-storage/

Hope this helps.

+4
source

I personally have not tried, but using the Windows Azure Storage Client library for Windows 8, this should be possible. There are two ways to access the storage:

  • Using the account name and storage key : not recommended in the case of the client application, because you will need to separate the account name and the storage key, a risk, since anyone who has the key is essentially the administrator of this storage account.
  • Use of shared access subscription (SAS) . This is a recommended practice as you provide limited and time-limited permissions for your blob repository. Users with a SAS URL can only do what you allow them to (for example, you can prevent users from deleting blob files in the blob container and only allow them to specify blobs in it or upload a file.

Take a look at the following code example, where the SAS URL is created using the Mobile Service and transferred to the Windows 8 application, through which the application interacts directly with Windows Azure Blob Storage: http://code.msdn.microsoft.com/windowsapps/ Upload-File-to-Windows-c9169190 .

+1
source

All Articles