amazon-web-services - 使用 s3 中的元数据检索/列出对象 - aws sdk
问题描述
我已使用用户定义的元数据数据将文件存储在 S3 存储桶中。可以说我的元数据就像
metaData = {
"title": "some random user title",
"description": "some random user description"
}
我知道我可以使用对象键和存储桶名称下载文件。我正在查看是否有任何方法/选项可以通过仅传递用于在 S3 中上传的对象的存储桶名称和用户定义的元数据来获取/检索/列出文件。
以及了解用户定义元数据的实际使用情况
任何指导或建议都会非常有帮助。!
解决方案
There is no native operation in Amazon S3 that can locate/retrieve objects via Metadata.
Metadata can be retrieved from objects, but cannot be used to search for objects. Also, only limited Metadata can be retrieved as part of an object listing.
An alternative would be to use Amazon S3 Inventory - Amazon Simple Storage Service. This only provides the listing once per day, but it can include metadata. You could use these files to locate objects based on metadata.
See:
推荐阅读
- apollo - 查询适用于 useQuery 钩子,但不适用于 ApolloClient 实例
- postgresql - postgresql:带有符号引用的转储数据库?
- python - 使用更大的 spacy 模型加速测试运行的好方法是什么?
- node.js - mongo db数据写入问题 - oauth
- python - 将多个调用分配给单个变量,否则对性能无关紧要
- java - 使用 Junit4 测试一个检查文件是否存在的函数
- javascript - 为什么这仍然是一个承诺?
- python - 如何添加具有分类特征的辅助 x 轴?
- angular - p-tablecheckbox 和 p-tableheadercheckbox
- python - 如何向 Netmiko 发送变量发送命令