azure-storage-blobs

Cant post to Azure storage? Invalid Path error

大兔子大兔子 提交于 2019-12-08 09:10:55
问题 I am trying to add an image I am receiving like this. [FunctionName("Imageupload")] public static async System.Threading.Tasks.Task<HttpResponseMessage> RunAsync([HttpTrigger(AuthorizationLevel.Anonymous, "get", "post", Route = "HttpTriggerCSharp/name/{name}")]HttpRequestMessage req, string name, TraceWriter log) { //Check if the request contains multipart/form-data. if (!req.Content.IsMimeMultipartContent()) { return req.CreateResponse(HttpStatusCode.UnsupportedMediaType); } var

Grabbing a thumbnail from a video when uploading. (Azure Blob Storage)

自闭症网瘾萝莉.ら 提交于 2019-12-08 07:45:08
问题 I currently has a system that uploads videos to Azure blob storage and works fine. I would like to implement a feature that grabs a thumbnail from the video while uploading and pushes it to Azure as well. I tried using this as suggested: new FFMpegConverter().GetVideoThumbnail(file, outputJPEG); The problem is that I am not sure what to use as outputJPEG as I don't have a file I am writing to, but rather want to write that file to Azure's blob storage. Can anyone help me figure out this issue

Using the connection String to Authenticate into Azure

主宰稳场 提交于 2019-12-08 07:17:18
问题 I have given an Connection String. I need to use this to authenticate into Azure Blob Storage. The connection String, as it appears, contains: Key, AccountName, protocol, Suffix. Connection String Example: DefaultEndpointsProtocol=https;AccountName=$$$$$*****;AccountKey=kjdjkfhdjskhfsdfhlksdhfkldshfishishfldslflkjfklsVvJDynYEkiEqWCZkdfkhdkjshfdshfs==;EndpointSuffix=core.windows.net Now when I look up the authorization article there are multiple methods mentioned and there are no article or

Transfer data from azure blob storage to hdfs file system

↘锁芯ラ 提交于 2019-12-08 07:08:37
问题 I have data in azure storage blob which is in parquet format. What I need to do is to transfer all those storage files to a hdfs. Is there any way I can do that? couldn't find any helpful method to do it, Thanks. 回答1: using @jay's solution I was able to transfer data using following command. command: hadoop distcp -D fs.azure.account.key.<account name>.blob.core.windows.net=<Key> wasb://<container>@<account>.blob.core.windows.net<path to wasb file> hdfs://<hdfs path> distcp copies directory

How can I read a text file from Azure blob storage directly without downloading it to a local file(using python)?

独自空忆成欢 提交于 2019-12-08 06:44:26
问题 How can i reads a text blob in Azure without downloading it? I am able to download the file and then read it but, i prefer it to be read without downloading. print("\nList blobs in the container") generator = block_blob_service.list_blobs(container_name) for blob1 in generator: print("\t Blob name: " + blob.name) Is there any operation in 'blob1' object, which would allow me to read the text file directly.(like blob1.read or blob1.text or something like this)? 回答1: You can use get_blob_to

Azure function to copy files from FTP to blob storage using FluentFTP

放肆的年华 提交于 2019-12-08 06:42:39
问题 I have an FTP source that adds daily file and I need to copy the files on daily basis from FTP to blob storage using FluentFTP library in azure function I am using C# in Azure function, and I did all the coding part but missing to download the file from FTP to copy it directly to the blob destination. //#r "FluentFTP" #r "Newtonsoft.Json" #r "System.Data" #r "Microsoft.WindowsAzure.Storage" using Newtonsoft.Json; using Newtonsoft.Json.Linq; using System.Collections.Generic; using System

How to zip huge files in a blob using stream

北战南征 提交于 2019-12-08 06:42:26
问题 I'm using Azure with blob storage ans Azure Functions. I got a lot of files and sometimes I want to generate a zip, save it in the storage and generate a link. As my zip can be big (1 or 2 Go) I would like to do this "on the fly", meaning without using all the memory before save it: stream on a zipentry write to the blob flush the stream create next zipentry I know I must use the method PutBlock() in the container, but I'm missing the code between ICSharpZipLib and BlobContainer. Has someone

CloudBlob not found in the new Microsoft.WindowsAzure.Storage what is its equivalent

时间秒杀一切 提交于 2019-12-08 05:43:58
问题 I had the following code which was using the deprecated Microsoft.WindowsAzure.StorageClient and have upgraded to Microsoft.WindowsAzure.Storage and now I am unable to use the code below as it is not recognising the CloudBlob class, has this been totally removed or is there an equivalent class I can use in a similar manner //blob client now CloudBlobClient blobClient = storageAccount.CreateCloudBlobClient(); //the container for this is customerlogo CloudBlobContainer container = blobClient

Uploading to azure blob storage from SAS URL returns 404 status

混江龙づ霸主 提交于 2019-12-08 04:41:26
问题 I am using Azure Mobile Services API endpoint to return a private shared access signature URL to my azure storage container like so: var blobService = azure.createBlobService(accountName, key, host); blobService.createContainerIfNotExists(containerName, function(err) { if (err) { cb(err, null); return; } // Generate a 5 minute access var expiryDate = minutesFromNow(5); var sharedAccessPolicy = { AccessPolicy: { Permissions: azure.Constants.BlobConstants.SharedAccessPermissions.WRITE, Expiry:

List Files in Azure Blob Storage

混江龙づ霸主 提交于 2019-12-08 04:37:44
问题 I am trying to list all the jpg files in my blob. When I use this code CloudStorageAccount storageAccount1 = CloudStorageAccount.Parse(CloudConfigurationManager.GetSetting("ConnString")); CloudBlobContainer container1 = blobClient.GetContainerReference(imageFolder); var blobs = container1.ListBlobs(); All the files in that particular blob are listed I have tried to modify the above code but the modified code does not list anything. CloudStorageAccount storageAccount1 = CloudStorageAccount