应用与数据集成平台 ROMA CONNECT-配置响应缓存策略:脚本配置示例

时间:2024-12-10 19:05:17

脚本配置示例

{
  "cache_key": {
    "system_params": [
      "$context.sourceIp",
      "$context.requestId"
    ],
    "parameters": [
      "demo_parameters"
    ],
    "headers": [
      "demo_header"
    ]
  },
  "cache_http_status_and_ttl": [
    {
      "http_status": [
        200
      ],
      "ttl": 300
    }
  ],
  "client_cache_control": {
    "mode": "apps",
    "datas": [
      "demo_app_id_1,demo_app_id_2"
    ]
  },
  "cacheable_headers": [
    "demo_cacheable_headers_1,demo_cacheable_headers_2"
  ]
}
support.huaweicloud.com/usermanual-roma/roma_03_2560.html