public async Task <IActionResult> Upload(IFormFile file) { if (file != null) { using (var stream = file.OpenReadStream()) { var fileId = await fileStore.SaveFile(stream); //var metadata = new byte[fileStream.Length]; //await fileStream.ReadAsync(metadata, 0, (int)fileStream.Length); //metadata.ToString(); await fileStore.AddMessageToQueue(fileId, file.FileName); return(RedirectToAction("Show", new { fileId })); } } return(View()); }