azure-storage-blobs

Transactional Access of Azure Blob Storage

人盡茶涼 提交于 2019-12-18 20:49:32
问题 I would like to store files in Azure Blob Storage. So far so good. I also would like to store addtional meta-data about the file; for that I use a Azure SQL Database (so I can easily query for files on the blob storage). So when I add a new file to the store I would like to make sure, that the blob as well as the meta-data was successfully written. So using something like a transaction-context comes to my mind. Is there any way, to create such a transaction-context using blob storage as well

Transactional Access of Azure Blob Storage

北城以北 提交于 2019-12-18 20:48:28
问题 I would like to store files in Azure Blob Storage. So far so good. I also would like to store addtional meta-data about the file; for that I use a Azure SQL Database (so I can easily query for files on the blob storage). So when I add a new file to the store I would like to make sure, that the blob as well as the meta-data was successfully written. So using something like a transaction-context comes to my mind. Is there any way, to create such a transaction-context using blob storage as well

Cannot delete blob: There is currently a lease on the blob and no lease ID was specified in the request

非 Y 不嫁゛ 提交于 2019-12-18 18:54:14
问题 When I attempt to delete a blob from my storage account container, I get an error message, " There is currently a lease on the blob and no lease ID was specified in the request. " I have 4 virtual machine instances. I also have 8 virtual machine disks, 4 of which are in use (one by each of the virtual machine instances). Strangely, I have 10 blobs listed in my single storage account's lone container, called vhds . Here is a screenshot of the 10 blobs, highlighting the two that I cannot delete

Python: How to move or copy Azure Blob from one container to another

眉间皱痕 提交于 2019-12-18 16:10:44
问题 I am using Microsoft Azure SDK for Python in project. I want to move or copy Blob from one container to another. for exmaple https://demostorage.blob.core.windows.net/image-container/pretty.jpg I want to move this blob to https://demostorage.blob.core.windows.net/demo-container/ I have found following method in python SDK but unable to understand it. def copy_blob(self, container_name, blob_name,...): How can I do this? Thank you 回答1: I have done in this way. from azure.storage.blob import

Query JSON data from Azure Blob Storage with jQuery

荒凉一梦 提交于 2019-12-18 13:40:24
问题 I have some data in an Azure blob storage. The data is JSON and it has been saved with the "application/json" content type. My app would be hosted at "myapp.com", a domain that contains a CNAME to "myapp.cloudapp.net". I guess I should create a custom domain name like "storage.myapp.com" that poins to my Azure storage. But then? Can I use JSONP or other way to make JSON ajax calls to Azure storage? How would be the better way to do this? Thanks a lot. 回答1: Well, apparently Azure blob storage

windows azure : set blob CORS properties using NodeJS

和自甴很熟 提交于 2019-12-18 12:42:28
问题 REST API has been released in february to set blob CORS property, but this hasn't been implemented for NodeJS yet. Since I need this feature, I tried to implement it in a module for my azure website running NodeJS. Based on REST API documentation to change CORS properties and to generate authentification key, on this implementation of authentification key generation using NodeJS, I tried to follow the accepted answer from this post, but it didn't work for me. Here is what I've got in

Azure Blob - Read using Python

核能气质少年 提交于 2019-12-18 12:22:15
问题 Can someone tell me if it is possible to read a csv file directly from Azure blob storage as a stream and process it using Python? I know it can be done using C#.Net (shown below) but wanted to know the equivalent library in Python to do this. CloudBlobClient client = storageAccount.CreateCloudBlobClient(); CloudBlobContainer container = client.GetContainerReference("outfiles"); CloudBlob blob = container.GetBlobReference("Test.csv");* 回答1: Yes, it is certainly possible to do so. Check out

Serving Video Content from Azure Blob Storage

余生颓废 提交于 2019-12-18 11:56:01
问题 I am trying to serve MP4 Video content from Azure Blob Storage. I can get the video to play in modern browsers by ensuring that the Blob's Content Type is set to video/mp4 ; however I am unable to seek backwards. Dropping the same video into an S3 bucket yields the desired result so I am ruling out problems with the content. Do I need to configure the Storage role in a specific way to serve video content? 回答1: it was not clear for me from @smarx's answer how to set that for my blob container

How to upload huge files to the Azure blob from a web page

强颜欢笑 提交于 2019-12-18 11:55:20
问题 Internally ASP.NET has a 2 GB addressing space, but in reality you only have less than 1 GB free for uploads (see http://support.microsoft.com/?id=295626 ). In addition IIS 7 has a cap of 30 MB ( see http://www.iislogs.com/steveschofield/iis7-post-40-adjusting-file-upload-size-in-iis7 ) and you supposedly have to run appcmd set config "My Site/MyApp" -section:requestFiltering -requestLimits.maxAllowedContentLength:104857600 -commitpath:apphost on the server to go beyond this 30 MB limit. But

Stream uploaded file to Azure blob storage with Node

二次信任 提交于 2019-12-18 11:03:03
问题 Using Express with Node, I can upload a file successfully and pass it to Azure storage in the following block of code. app.get('/upload', function (req, res) { res.send( '<form action="/upload" method="post" enctype="multipart/form-data">' + '<input type="file" name="snapshot" />' + '<input type="submit" value="Upload" />' + '</form>' ); }); app.post('/upload', function (req, res) { var path = req.files.snapshot.path; var bs= azure.createBlobService(); bs.createBlockBlobFromFile('c', 'test