API缓存持续时间限制 [英] API Cache Duration Limit

查看:103
本文介绍了API缓存持续时间限制的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们有一些参考数据很少(通常是每年一次)更改,我们希望通过我们的组织共享这些数据,但又不想从数据库中不断调用它.

We have some reference data that changes extremely infrequently (normally on a yearly cycle) that we want to share through our organisation but don't want to continually call it from the database.

能够缓存的局限性是什么?

What are the limits of being able to cache?

我们是否还可以使用Logic App根据时间表重建API数据?

Could we also use a Logic App to rebuild the API data based on a schedule?

推荐答案

您是否已使用Azure API Management实施了缓存策略?在这种情况下,以下是您可以选择的选项 可以用于API管理,

Have you implemented caching policy with Azure API Management? If this is the case, below are the options which you could use for API Management,

  • 响应缓存策略

从缓存获取-执行高速缓存查找并在有效时返回有效的高速缓存响应.存储到缓存-缓存响应 根据指定的缓存控制配置.

Get from cache - Perform cache look up and return a valid cached response when available. Store to cache - Caches responses according to the specified cache control configuration.

  • 价值缓存政策

从缓存中获取价值-通过键检索缓存的项目.将值存储在缓存中-通过键将项目存储在缓存中.去除价值 从缓存中-通过键删除缓存中的项目.

Get value from cache - Retrieve a cached item by key. Store value in cache - Store an item in the cache by key. Remove value from cache - Remove an item in the cache by key.

有关更多详细信息,您可以参考此文档: https://docs.microsoft.com/zh-CN/azure/api-management/api-management-caching-policies#CachingPolicies .

For more details, you may refer to this document: https://docs.microsoft.com/en-us/azure/api-management/api-management-caching-policies#CachingPolicies.


这篇关于API缓存持续时间限制的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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