如何在 azure blob 存储中创建空文件夹 [英] How to create empty folder in azure blob storage

查看:40
本文介绍了如何在 azure blob 存储中创建空文件夹的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何像在Azure Explorer"工具中创建空文件夹一样在 azure blob 存储中创建空文件夹

How to create empty folder in azure blob storage just like empty folder in tool "Azure Explorer"

推荐答案

从技术上讲,Azure Blob 存储中不能有空文件夹,因为 Blob 存储有 2 级层次结构 - Blob 容器和 Blob.您本质上通过在文件名前加上您喜欢的文件夹名称来创建文件夹的错觉,例如假设你想要在 css 文件夹中的样式表(比如 site.css),你将样式表文件命名为 css/site.css.

Technically speaking, you can't have an empty folder in Azure Blob Storage as blob storage has a 2 level hierarchy - blob container and blob. You essentially create an illusion of a folder by prefixing the file name with the folder name you like e.g. assuming you want a style sheet (say site.css) in say css folder, you name the stylesheet file as css/site.css.

有些工具的作用是为了创建一个空文件夹,它们创建一个零字节 blob 并在它前面加上文件夹的名称,然后不显示该零字节 blob.如果你愿意,你可以这样做.

What some of the tools do is in order to create an empty folder, they create a zero byte blob and prefix it with the name of the folder and then don't show that zero byte blob. If you want, you can do that.

这篇关于如何在 azure blob 存储中创建空文件夹的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆