azure-storage-blobs

'ControllerBase.File(byte[], string)' is a method, which is not valid in the given context (CS0119) - in method

元气小坏坏 提交于 2020-05-17 08:52:26
问题 I am trying to create an app where user can upload a text file, and gets the altered text back. I am using React as FE and ASP.NET Core for BE and Azure storage for the database storage. This is how my HomeController looks like. I created a separate "UploadToBlob" method, to post the data public class HomeController : Controller { private readonly IConfiguration _configuration; public HomeController(IConfiguration Configuration) { _configuration = Configuration; } public IActionResult Index()

How to improve performance of downloading large size azure blob file over a stream?

别等时光非礼了梦想. 提交于 2020-05-15 17:18:24
问题 I have JSON blob file of size around 212 MB. On Local while debugging it is taking around 15 minutes to download. When i deploy code to Azure app service it runs for 10 minutes and fails with error : (locally it fails intermittently with same error) Server failed to authenticate the request. Make sure the value of Authorization header is formed correctly including the signature Code Attempt 1: // Create SAS Token for referencing a file for a duration of 5 min SharedAccessBlobPolicy

Azure Edit blob

孤者浪人 提交于 2020-05-13 07:37:06
问题 I have various file types that are uploaded into blob storage. I am needing to edit/read these files using third party tools (Exiftool, Imagemagick, etc. - I know I could possibly use the Media Services but I am required to use these tools). Once the files are in blob storage does my worker role have to download the blob from storage in order to work with the file? The reason for the questions is that I am working with very large files (videos, images, etc.) and I don't necessarily want to

Cloud Explorer - cannot access development Blob Containers

本小妞迷上赌 提交于 2020-05-13 05:25:19
问题 I am developing with Azure storage locally using VS2015. I created and accessed my development storage blob container fine. I upload three images and have code to calculate the size of the images. For some unknown reason, I cannot expand the Blob Containers node in Cloud Explorer any more. I.e. Cloud explorer > Storage Accounts > (Development) > Blob Containers. Doing so results in the following error message: Cloud Explorer has encountered an unexpected error: Unable to retrieve child

How to compute Azure Storage Container Size in Java?

我是研究僧i 提交于 2020-05-11 03:44:50
问题 While the following link details the way you can compute the storage size using C#, I don't see similar methods in Java. Appreciate if someone can post a sample code for Java please. Azure Storage container size 回答1: Here is my sample code. For more details, please refer to the javadocs of Azure Storage SDK for Java. String accountName = "<your-storage-account-name>"; String accountKey = "<your-storage-account-key>"; String storageConnectionString = "DefaultEndpointsProtocol=https;AccountName

How to compute Azure Storage Container Size in Java?

拟墨画扇 提交于 2020-05-11 03:39:40
问题 While the following link details the way you can compute the storage size using C#, I don't see similar methods in Java. Appreciate if someone can post a sample code for Java please. Azure Storage container size 回答1: Here is my sample code. For more details, please refer to the javadocs of Azure Storage SDK for Java. String accountName = "<your-storage-account-name>"; String accountKey = "<your-storage-account-key>"; String storageConnectionString = "DefaultEndpointsProtocol=https;AccountName

Is there a way to get file structure from azure blob?

别来无恙 提交于 2020-05-09 07:28:26
问题 I'm new to Azure and playing around with blobs in my .Net application. I want to be able to get structure with folders, subfolders and files inside. For now I've figured a way to get the files from all folders and subfolders altogether with parents. Is there any way to get folder structure some other way than parse Prefix of those files' parents? File structure is the following: root container -folder1 -subfolder1 -file -file -subfolder2 -file -file -file I've tried this, but it only gives me

How to copy a file in Azure from a one storage account to another using Python?

十年热恋 提交于 2020-04-30 09:07:58
问题 I have written a piece of code to copy a file from one container to another within the same storage account. block_blob_service = BlockBlobService( account_name='', account_key='') blob_name = file_name copy_from_container = source copy_to_container = destination blob_url = block_blob_service.make_blob_url(copy_from_container, blob_name) # blob_url:https://demostorage.blob.core.windows.net/image-container/pretty.jpg block_blob_service.copy_blob(copy_to_container, blob_name, blob_url) But now

Write dataframe to blob using azure databricks

强颜欢笑 提交于 2020-04-16 02:27:47
问题 Is there any link or sample code where we can write dataframe to azure blob storage using python (not using pyspark module). 回答1: Below is the code snippet for writing (dataframe) CSV data directly to an Azure blob storage container in an Azure Databricks Notebook. # Configure blob storage account access key globally spark.conf.set( "fs.azure.account.key.%s.blob.core.windows.net" % storage_name, sas_key) output_container_path = "wasbs://%s@%s.blob.core.windows.net" % (output_container_name,

Azure Blob Storage “Authorization Permission Mismatch” error for get request with AD token

走远了吗. 提交于 2020-04-09 19:17:21
问题 I am building an Angular 6 application that will be able to make CRUD operation on Azure Blob Storage. I'm however using postman to test requests before implementing them inside the app and copy-pasting the token that I get from Angular for that resource. When trying to read a file that I have inside the storage for test purposes, I'm getting: <Code>AuthorizationPermissionMismatch</Code> <Message>This request is not authorized to perform this operation using this permission. All in production