我正在遵循指南并更新我的代码以在 GAE 中使用新的 Cloud Storage API,我确实需要设置 cachecontrol 标头,以前这很容易:
files.gs.create(filename, mime_type='image/png', acl='public-read', cache_control='public, max-age=100000, must-revalidate' )
但是,使用新的 API,指南说“cache_control”不可用......当我尝试将 cachecontrol 放在选项中时出现此错误:
ValueError: option cache_control is not supported.
尝试使用 Cache-Control 和相同的错误...
像往常一样,新 API 的文档并不好。
有人可以帮助我如何使用 PYTHON 在新的 Cloud Storage API 中设置缓存标头。如果不可能,我还能在我的项目中使用旧的 api 吗?
谢谢。