<script type="application/ld+json">{"@context":"http://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://www.simcentric.com/tc/"},{"@type":"ListItem","position":2,"name":"在 API 閘道中設定速率限制與斷路器","item":"https://www.simcentric.com/tc/america-dedicated-server-tc/configure-rate-limiting-and-circuit-breaking-in-api-gateways/"}]}</script> {"id":34657,"date":"2026-09-15T14:37:58","date_gmt":"2026-09-15T06:37:58","guid":{"rendered":"https:\/\/www.simcentric.com\/uncategorized-tc\/configure-rate-limiting-and-circuit-breaking-in-api-gateways\/"},"modified":"2026-09-15T14:42:07","modified_gmt":"2026-09-15T06:42:07","slug":"configure-rate-limiting-and-circuit-breaking-in-api-gateways","status":"publish","type":"post","link":"https:\/\/www.simcentric.com\/tc\/america-dedicated-server-tc\/configure-rate-limiting-and-circuit-breaking-in-api-gateways\/","title":{"rendered":"\u5728 API \u9598\u9053\u4e2d\u8a2d\u5b9a\u901f\u7387\u9650\u5236\u8207\u65b7\u8def\u5668"},"content":{"rendered":"<div class=\"wpb-content-wrapper\"><p>[vc_row][vc_column][vc_column_text css=&#8221;&#8221;]\u8a2d\u60f3\u9019\u6a23\u4e00\u7a2e\u60c5\u6cc1\uff1a\u67d0\u500b\u884c\u70ba\u7570\u5e38\u7684\u7528\u6236\u7aef\u6bcf\u79d2\u9001\u51fa 1,000 \u500b\u8acb\u6c42\uff0c\u5f8c\u7aef\u8fc5\u901f\u98fd\u548c\uff1b\u4e0b\u6e38\u670d\u52d9\u5931\u53bb\u56de\u61c9\uff1b\u4f47\u5217\u4e0d\u65b7\u5806\u7a4d\uff0c\u6700\u7d42\u5f15\u767c\u9023\u9396\u6545\u969c\u3002\u4f60\u8a72\u5982\u4f55\u4fdd\u8b77 <a href=\"https:\/\/www.simcentric.com\/tc\/japan-dedicated-server-tc\/what-is-mcp-server-and-how-does-it-differ-from-api-server\/\" target=\"_blank\" rel=\"noopener\">API \u9598\u9053<\/a>\uff0c\u4f7f\u5176\u514d\u53d7\u6d41\u91cf\u9ad8\u5cf0\u8207\u670d\u52d9\u6545\u969c\u7684\u885d\u64ca\uff1f\u5169\u7a2e\u7d93\u904e\u9a57\u8b49\u7684\u6a21\u5f0f\u53ef\u4ee5\u63d0\u4f9b\u5e6b\u52a9\uff1a\u901f\u7387\u9650\u5236\u8207\u65b7\u8def\u5668\u3002GitHub \u5c07\u5df2\u9a57\u8b49 API \u4f7f\u7528\u8005\u9650\u5236\u70ba\u6bcf\u5c0f\u6642 5,000 \u6b21\u8acb\u6c42\u3002\u65b7\u8def\u5668\u5247\u6703\u5728\u670d\u52d9\u767c\u751f\u6545\u969c\u6642\u505c\u6b62\u7e7c\u7e8c\u5411\u5176\u9001\u51fa\u8acb\u6c42\u3002\u7576\u7528\u6236\u7aef\u8d85\u51fa\u9650\u5236\u6642\uff0c<a href=\"https:\/\/www.simcentric.com\/tc\/products\/dedicated-server-us\/\" target=\"_blank\" rel=\"noopener\">\u4f3a\u670d\u5668<\/a>\u6703\u56de\u50b3 HTTP 429\u3002\u672c\u6307\u5357\u5c07\u4ecb\u7d39\u5982\u4f55\u4f7f\u7528\u6b0a\u6756\u6876\u6f14\u7b97\u6cd5\u548c Redis \u8a08\u6578\u5668\u4f86\u8a2d\u5b9a\u901f\u7387\u9650\u5236\uff0c\u4e26\u5be6\u4f5c\u4e00\u500b\u5177\u5099 Closed\u3001Open \u8207 Half-Open \u4e09\u7a2e\u72c0\u614b\u7684\u65b7\u8def\u5668\u3002\u8b80\u5b8c\u5f8c\uff0c\u4f60\u5c07\u80fd\u5920\u900f\u904e YAML \u6216\u7a0b\u5f0f\u78bc\u5728\u9598\u9053\u4e0a\u8a2d\u5b9a\u9019\u5169\u7a2e\u7b56\u7565\uff0c\u9632\u6b62\u7cfb\u7d71\u904e\u8f09\u4e26\u5be6\u73fe\u512a\u96c5\u5fa9\u539f\u3002<\/p>\n<h2><strong>\u901f\u7387\u9650\u5236\u8207\u65b7\u8def\u5668\u7684\u57fa\u790e\u539f\u7406<\/strong><\/h2>\n<p>\u901f\u7387\u9650\u5236\u548c\u65b7\u8def\u5668\u89e3\u6c7a\u7684\u662f\u4e0d\u540c\u7684\u554f\u984c\uff0c\u800c\u4e00\u500b\u5177\u5099\u97cc\u6027\u7684 API \u9598\u9053\u901a\u5e38\u5169\u8005\u90fd\u9700\u8981\u3002\u901f\u7387\u9650\u5236\u63a7\u5236\u9032\u5165\u7cfb\u7d71\u7684\u6d41\u91cf\u898f\u6a21\uff1b\u65b7\u8def\u5668\u5247\u6c7a\u5b9a\u8acb\u6c42\u662f\u5426\u9084\u61c9\u8a72\u5230\u9054\u5df2\u7d93\u51fa\u73fe\u6545\u969c\u7684\u76f8\u4f9d\u670d\u52d9\u3002\u4e0b\u8868\u5c55\u793a\u4e86\u5169\u8005\u7684\u6838\u5fc3\u5dee\u7570\u3002<\/p>\n<div class=\"qc-default-table-wrapper \">\n<table style=\"min-width: 75px;\">\n<colgroup>\n<col style=\"min-width: 25px;\">\n<col style=\"min-width: 25px;\">\n<col style=\"min-width: 25px;\"><\/colgroup>\n<tbody>\n<tr>\n<th colspan=\"1\" rowspan=\"1\">\u9762\u5411<\/th>\n<th colspan=\"1\" rowspan=\"1\">\u901f\u7387\u9650\u5236<\/th>\n<th colspan=\"1\" rowspan=\"1\">\u65b7\u8def\u5668<\/th>\n<\/tr>\n<tr>\n<td colspan=\"1\" rowspan=\"1\">\u4e3b\u8981\u76ee\u6a19<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u63a7\u5236\u9032\u5165\u7cfb\u7d71\u7684\u8acb\u6c42\u91cf<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u9632\u6b62\u4e0b\u6e38\u76f8\u4f9d\u6545\u969c\u5e36\u4f86\u66f4\u5927\u5f71\u97ff<\/td>\n<\/tr>\n<tr>\n<td colspan=\"1\" rowspan=\"1\">\u4f5c\u7528\u65b9\u5411<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u5165\u7ad9\uff08\u7528\u6236\u7aef\u5230 API\uff09<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u51fa\u7ad9\uff08API \u5230\u4e0b\u6e38\u670d\u52d9\uff09<\/td>\n<\/tr>\n<tr>\n<td colspan=\"1\" rowspan=\"1\">\u89f8\u767c\u689d\u4ef6<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u8acb\u6c42\u6578\u8d85\u904e\u9580\u6abb<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u4e0b\u6e38\u5931\u6557\u7387\u8d85\u904e\u9580\u6abb<\/td>\n<\/tr>\n<tr>\n<td colspan=\"1\" rowspan=\"1\">\u5178\u578b\u56de\u61c9<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u56de\u50b3\u5e36\u6709\u91cd\u8a66\u63d0\u793a\u7684 HTTP 429<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u7acb\u5373\u5931\u6557\u6216\u56de\u50b3\u964d\u7d1a\u7d50\u679c<\/td>\n<\/tr>\n<tr>\n<td colspan=\"1\" rowspan=\"1\">\u72c0\u614b\u6a21\u578b<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u7121\u72c0\u614b\uff1a\u57fa\u65bc\u8a08\u6578\u5668\u8207\u6642\u9593\u8996\u7a97<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u6709\u72c0\u614b\uff1aClosed\u3001Open\u3001Half-Open<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<h3>\u4f55\u6642\u4f7f\u7528\u901f\u7387\u9650\u5236<\/h3>\n<p>\u7576\u67d0\u500b\u7528\u6236\u7aef\u53ef\u80fd\u6436\u5360\u5176\u4ed6\u7528\u6236\u7aef\u8cc7\u6e90\u6642\uff0c\u5c31\u61c9\u8a72\u4f7f\u7528\u901f\u7387\u9650\u5236\u3002\u4e00\u500b\u64c1\u6709\u5927\u91cf\u4f7f\u7528\u8005\u7684\u516c\u958b API \u9700\u8981\u516c\u5e73\u5b58\u53d6\uff0c\u56e0\u6b64\u4f60\u53ef\u4ee5\u5728\u6642\u9593\u8996\u7a97\u5167\u9650\u5236\u6bcf\u500b\u7528\u6236\u7aef\u7684\u8acb\u6c42\u6578\u3002\u540c\u6a23\u7684\u908f\u8f2f\u4e5f\u9069\u7528\u65bc\u4fdd\u8b77\u767b\u5165\u4ecb\u9762\u514d\u53d7\u66b4\u529b\u7834\u89e3\uff0c\u4ee5\u53ca\u963b\u6b62\u722c\u87f2\u8017\u76e1\u4f60\u7684\u7cfb\u7d71\u5bb9\u91cf\u3002<\/p>\n<p>\u4f60\u9084\u61c9\u900f\u904e\u8a2d\u5b9a\u901f\u7387\u9650\u5236\u4f86\u63a7\u5236\u6210\u672c\u3002\u7a81\u767c\u7684\u4f7f\u7528\u9ad8\u5cf0\u53ef\u80fd\u6703\u8fc5\u901f\u6d88\u8017\u57fa\u790e\u8a2d\u65bd\u9810\u7b97\u3002\u6839\u64da API key\u3001OAuth \u6b0a\u6756\u6216\u4f7f\u7528\u65b9\u6848\u8a2d\u5b9a\u9650\u5236\uff0c\u53ef\u4ee5\u8b93\u4f60\u70ba\u514d\u8cbb\u65b9\u6848\u63d0\u4f9b\u8f03\u4f4e\u4e0a\u9650\uff0c\u70ba\u4ed8\u8cbb\u65b9\u6848\u63d0\u4f9b\u66f4\u9ad8\u541e\u5410\u80fd\u529b\u3002\u9019\u6a23\u53ef\u4ee5\u8b93\u4f47\u5217\u4fdd\u6301\u7a69\u5b9a\uff0c\u4e5f\u8b93\u6240\u6709\u4f7f\u7528\u8005\u7684\u5ef6\u9072\u66f4\u53ef\u9810\u6e2c\u3002<\/p>\n<h3>\u4f55\u6642\u4f7f\u7528\u65b7\u8def\u5668<\/h3>\n<p>\u7576\u4e0b\u6e38\u670d\u52d9\u958b\u59cb\u5931\u6557\u6642\uff0c\u5c31\u8a72\u555f\u7528\u65b7\u8def\u5668\u6a21\u5f0f\u3002\u547c\u53eb\u5916\u90e8 ML API\u3001\u652f\u4ed8\u8655\u7406\u670d\u52d9\u6216\u5eab\u5b58\u670d\u52d9\u6642\uff0c\u90fd\u53ef\u80fd\u767c\u751f\u903e\u6642\u4e26\u9577\u6642\u9593\u5360\u7528\u57f7\u884c\u7dd2\u3002\u5982\u679c\u6c92\u6709\u4fdd\u8b77\u6a5f\u5236\uff0c\u6bcf\u500b\u8acb\u6c42\u90fd\u6703\u4e00\u76f4\u7b49\u5f85\u76f4\u5230\u903e\u6642\uff0c\u9023\u7dda\u6c60\u88ab\u8017\u76e1\uff0c\u6545\u969c\u4e5f\u6703\u5728\u5fae\u670d\u52d9\u4e4b\u9593\u64f4\u6563\u3002<\/p>\n<p>\u65b7\u8def\u5668\u6a21\u5f0f\u6703\u76e3\u63a7\u5931\u6557\u7387\u5347\u9ad8\u3001\u6162\u547c\u53eb\u548c\u903e\u6642\u7b49\u73fe\u8c61\u3002\u4e00\u65e6\u5931\u6557\u8d85\u904e\u9580\u6abb\uff0c\u65b7\u8def\u5668\u5c31\u6703\u5207\u63db\u5230 Open \u72c0\u614b\uff0c\u4e26\u7acb\u5373\u56de\u50b3\u964d\u7d1a\u56de\u61c9\u3002\u7d93\u904e\u4e00\u6bb5\u51b7\u537b\u6642\u9593\u5f8c\uff0c\u5b83\u6703\u9032\u5165 Half-Open \u72c0\u614b\uff0c\u4e26\u4ee5\u6709\u9650\u8acb\u6c42\u6e2c\u8a66\u670d\u52d9\u662f\u5426\u6062\u5fa9\u3002\u9019\u500b\u72c0\u614b\u6a5f\u65e2\u80fd\u9694\u96e2\u6545\u969c\uff0c\u4e5f\u80fd\u652f\u63f4\u81ea\u52d5\u5fa9\u539f\u3002\u5728\u5fae\u670d\u52d9\u67b6\u69cb\u4e2d\uff0c\u53ea\u8981\u67d0\u500b\u4e0d\u7a69\u5b9a\u76f8\u4f9d\u53ef\u80fd\u5f15\u767c\u9023\u9396\u6545\u969c\uff0c\u5c31\u61c9\u8003\u616e\u4f7f\u7528\u5b83\u3002<\/p>\n<h2><strong>\u5728 API \u9598\u9053\u4e0a\u8a2d\u5b9a\u901f\u7387\u9650\u5236<\/strong><\/h2>\n<p>\u73fe\u5be6\u4e2d\u7684 API \u5df2\u7d93\u5c55\u793a\u4e86\u901f\u7387\u9650\u5236\u7684\u5178\u578b\u65b9\u5f0f\u3002GitHub \u5c07\u5df2\u9a57\u8b49\u4f7f\u7528\u8005\u9650\u5236\u70ba\u6bcf\u5c0f\u6642 5,000 \u6b21\u8acb\u6c42\u3002\u9019\u4e9b\u6578\u503c\u53cd\u6620\u4e86\u5404\u5e73\u53f0\u81ea\u8eab\u7684\u5bb9\u91cf\u8207\u516c\u5e73\u6027\u76ee\u6a19\u3002\u4f60\u4e5f\u53ef\u4ee5\u5728\u81ea\u5df1\u7684 API \u9598\u9053\u4e0a\u7528\u985e\u4f3c\u908f\u8f2f\u8a2d\u5b9a\u901f\u7387\u9650\u5236\u3002\u9598\u9053\u6703\u7d71\u8a08\u50b3\u5165\u8acb\u6c42\uff0c\u4e00\u65e6\u67d0\u500b\u7528\u6236\u7aef\u8d85\u904e\u9580\u6abb\uff0c\u5c31\u62d2\u7d55\u5176\u984d\u5916\u8acb\u6c42\u3002<\/p>\n<p>Redis \u5e38\u88ab\u7528\u65bc\u5132\u5b58\u9019\u4e9b\u8acb\u6c42\u8a08\u6578\u5668\u3002\u96c6\u4e2d\u5f0f\u5132\u5b58\u53ef\u4ee5\u8b93\u591a\u500b\u9598\u9053\u5be6\u4f8b\u4e4b\u9593\u4fdd\u6301\u8a08\u6578\u4e00\u81f4\u3002\u7576\u7528\u6236\u7aef\u8d85\u904e\u9650\u5236\u6642\uff0c\u9598\u9053\u6703\u56de\u50b3 HTTP 429 Too Many Requests\u3002\u56de\u61c9\u4e2d\u9084\u53ef\u4ee5\u5305\u542b <code>X-RateLimit-Limit<\/code>\u3001<code>X-RateLimit-Remaining<\/code> \u548c <code>X-RateLimit-Reset<\/code> \u7b49\u6a19\u982d\u8cc7\u8a0a\uff0c\u7528\u65bc\u544a\u77e5\u7528\u6236\u7aef\u4f55\u6642\u53ef\u4ee5\u91cd\u8a66\u3002\u9019\u7a2e\u65b9\u5f0f\u65e2\u9069\u7528\u65bc\u91dd\u5c0d\u55ae\u4e00\u8def\u7531\u7684\u9650\u5236\uff0c\u4e5f\u9069\u7528\u65bc\u8de8\u6240\u6709\u8def\u7531\u7684\u5168\u57df\u9650\u5236\u3002<\/p>\n<h3>\u5982\u4f55\u5728\u6b0a\u6756\u6876\u8207\u6f0f\u6876\u4e4b\u9593\u505a\u9078\u64c7<\/h3>\n<p>\u5728\u901f\u7387\u9650\u5236\u8a2d\u8a08\u4e2d\uff0c\u6700\u5e38\u898b\u7684\u662f\u5169\u7a2e\u6f14\u7b97\u6cd5\uff0c\u5b83\u5011\u5c0d\u6d41\u91cf\u7684\u6574\u5f62\u65b9\u5f0f\u5404\u4e0d\u76f8\u540c\u3002\u4e0b\u8868\u7d66\u51fa\u4e86\u6bd4\u8f03\u3002<\/p>\n<div class=\"qc-default-table-wrapper \">\n<table style=\"min-width: 75px;\">\n<colgroup>\n<col style=\"min-width: 25px;\">\n<col style=\"min-width: 25px;\">\n<col style=\"min-width: 25px;\"><\/colgroup>\n<tbody>\n<tr>\n<th colspan=\"1\" rowspan=\"1\">\u6f14\u7b97\u6cd5<\/th>\n<th colspan=\"1\" rowspan=\"1\">\u7a81\u767c\u6d41\u91cf\u8655\u7406\u80fd\u529b<\/th>\n<th colspan=\"1\" rowspan=\"1\">\u6700\u4f73\u4f7f\u7528\u60c5\u5883<\/th>\n<\/tr>\n<tr>\n<td colspan=\"1\" rowspan=\"1\">\u6b0a\u6756\u6876<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u5141\u8a31\u5728\u6876\u5bb9\u91cf\u7bc4\u570d\u5167\u51fa\u73fe\u53ef\u63a7\u7a81\u767c<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u9762\u5411\u958b\u767c\u8005\u7684 API\uff0c\u5141\u8a31\u5076\u767c\u7a81\u767c\u6d41\u91cf<\/td>\n<\/tr>\n<tr>\n<td colspan=\"1\" rowspan=\"1\">\u6f0f\u6876<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u56b4\u683c\u63a7\u5236\u8f38\u51fa\u901f\u7387\uff0c\u4e0d\u5141\u8a31\u7a81\u767c<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u9700\u8981\u5e73\u6ed1\u3001\u5747\u52fb\u6d41\u91cf\u7684\u8106\u5f31\u4e0b\u6e38\u7cfb\u7d71<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<p>\u6b0a\u6756\u6876\u7684\u53c3\u6578\u5305\u62ec\u6b0a\u6756\u586b\u5145\u901f\u7387\u548c\u6876\u5bb9\u91cf\u3002\u586b\u5145\u901f\u7387\u8868\u793a\u6bcf\u79d2\u65b0\u589e\u591a\u5c11\u6b0a\u6756\uff0c\u6876\u5bb9\u91cf\u8868\u793a\u6876\u4e2d\u6700\u591a\u53ef\u5b58\u653e\u591a\u5c11\u6b0a\u6756\u3002\u4f60\u9700\u8981\u6839\u64da\u5f8c\u7aef\u5c0d\u7a81\u767c\u6d41\u91cf\u7684\u627f\u53d7\u80fd\u529b\u4f86\u9078\u64c7\u9019\u4e9b\u503c\u3002<\/p>\n<p>\u5982\u679c\u7528\u6236\u7aef\u9700\u8981\u5076\u723e\u7a81\u767c\u5b58\u53d6\uff0c\u9078\u64c7\u6b0a\u6756\u6876\u66f4\u5408\u9069\uff1b\u5982\u679c\u4e0b\u6e38\u670d\u52d9\u8981\u6c42\u7a69\u5b9a\u3001\u53ef\u9810\u6e2c\u7684\u6d41\u91cf\uff0c\u6f0f\u6876\u66f4\u9069\u5408\u3002\u5982\u679c\u6d41\u91cf\u672c\u8eab\u5177\u6709\u7a81\u767c\u6027\uff0c\u6b0a\u6756\u6876\u6216\u6ed1\u52d5\u8996\u7a97\u8a08\u6578\u5668\u901a\u5e38\u6548\u679c\u66f4\u597d\uff1b\u5982\u679c\u6d41\u91cf\u8f03\u5747\u52fb\uff0c\u6216\u8005\u4f60\u9700\u8981\u56b4\u683c\u9650\u5236\u8f38\u51fa\u901f\u7387\uff0c\u90a3\u9ebc\u6f0f\u6876\u662f\u66f4\u512a\u9078\u64c7\u3002<\/p>\n<h3>\u4f7f\u7528 YAML \u8a2d\u5b9a\u55ae\u4e00\u8def\u7531\u8207\u5168\u57df\u9650\u5236<\/h3>\n<p>\u4f60\u53ef\u4ee5\u4f9d\u8def\u7531\u5b9a\u7fa9\u901f\u7387\u9650\u5236\uff0c\u4e5f\u53ef\u4ee5\u5728\u6574\u500b\u9598\u9053\u7bc4\u570d\u5167\u5b9a\u7fa9\u5168\u57df\u9650\u5236\u3002\u4f9d\u8def\u7531\u7684\u9650\u5236\u53ea\u4f5c\u7528\u65bc\u7279\u5b9a\u7aef\u9ede\uff1b\u5168\u57df\u9650\u5236\u5247\u5c0d\u9598\u9053\u4e2d\u7684\u6240\u6709\u8def\u7531\u8a2d\u5b9a\u7d71\u4e00\u4e0a\u9650\u3002Redis \u4f5c\u70ba\u5171\u4eab\u8a08\u6578\u5132\u5b58\uff0c\u7528\u65bc\u5728\u5206\u6563\u5f0f\u74b0\u5883\u4e2d\u7d71\u4e00\u57f7\u884c\u9650\u5236\u3002<\/p>\n<p>\u4e0b\u9762\u662f\u4e00\u500b\u5f15\u7528 Redis \u7684 RequestRateLimiter \u904e\u6ffe\u5668 YAML \u8a2d\u5b9a\u7bc4\u4f8b\uff1a<\/p>\n<pre><code>spring:\r\n  cloud:\r\n    gateway:\r\n      routes:\r\n      - id: auditflow_service_route\r\n        uri: http:\/\/localhost:8080\r\n        predicates:\r\n        - Path=\/api\/v1\/audit\/**\r\n        filters:\r\n        - name: RequestRateLimiter\r\n          args:\r\n            key-resolver: \"#{@ipAddressKeyResolver}\"\r\n            redis-rate-limiter.replenishRate: 10\r\n            redis-rate-limiter.burstCapacity: 20\r\n            redis-rate-limiter.requestedTokens: 1<\/code><\/pre>\n<p><code>replenishRate<\/code> \u7528\u65bc\u8a2d\u5b9a\u6bcf\u79d2\u88dc\u5145\u591a\u5c11\u6b0a\u6756\uff1b<code>burstCapacity<\/code> \u5b9a\u7fa9\u53ef\u7528\u6b0a\u6756\u7684\u6700\u5927\u6578\u91cf\uff1b<code>requestedTokens<\/code> \u8868\u793a\u6bcf\u500b\u8acb\u6c42\u6703\u6d88\u8017\u591a\u5c11\u6b0a\u6756\u3002<code>key-resolver<\/code> \u5247\u6c7a\u5b9a\u9650\u6d41\u5668\u57fa\u65bc\u54ea\u500b\u8b58\u5225\u9032\u884c\u7d71\u8a08\uff0c\u4f8b\u5982 IP \u4f4d\u5740\u6216\u4f7f\u7528\u8005 ID\u3002<\/p>\n<p>\u9019\u6bb5\u8a2d\u5b9a\u5c07\u9650\u5236\u5957\u7528\u5230 <code>\/api\/v1\/audit\/**<\/code> \u8def\u5f91\u3002\u4f60\u53ef\u4ee5\u5c07\u985e\u4f3c\u904e\u6ffe\u5668\u52a0\u5165\u5176\u4ed6\u8def\u7531\uff0c\u4e26\u8a2d\u5b9a\u4e0d\u540c\u7684\u503c\u3002\u5168\u57df\u9650\u5236\u5247\u6703\u4f7f\u7528\u8de8\u6240\u6709\u8def\u7531\u5171\u4eab\u7684 key\u3002\u7576\u8d85\u51fa\u9650\u5236\u6642\uff0c\u9598\u9053\u6703\u56de\u50b3\u5e36\u6709 <code>Retry-After<\/code> \u6a19\u982d\u7684 HTTP 429\uff0c\u660e\u78ba\u544a\u77e5\u7528\u6236\u7aef\u4f55\u6642\u518d\u6b21\u5617\u8a66\u3002<\/p>\n<p>\u65b7\u8def\u5668\u6a21\u5f0f\u662f\u901f\u7387\u9650\u5236\u7684\u4e92\u88dc\u6a5f\u5236\uff0c\u5b83\u8655\u7406\u7684\u662f\u670d\u52d9\u6545\u969c\uff0c\u800c\u4e0d\u662f\u8acb\u6c42\u91cf\u3002\u901f\u7387\u9650\u5236\u63a7\u5236\u9032\u5165\u7cfb\u7d71\u7684\u8acb\u6c42\u6578\uff1b\u65b7\u8def\u5668\u5247\u963b\u6b62\u8acb\u6c42\u7e7c\u7e8c\u5230\u9054\u5df2\u6545\u969c\u7684\u76f8\u4f9d\u670d\u52d9\u3002\u5169\u8005\u914d\u5408\uff0c\u624d\u80fd\u540c\u6642\u9632\u7bc4\u6d41\u91cf\u9ad8\u5cf0\u8207\u9023\u9396\u6545\u969c\u3002<\/p>\n<h2><strong>\u5728 API \u9598\u9053\u4e0a\u5be6\u4f5c\u65b7\u8def\u5668<\/strong><\/h2>\n<p>\u73fe\u5728\u958b\u59cb\u5be6\u4f5c\u65b7\u8def\u5668\u6a21\u5f0f\u3002\u5b83\u6703\u963b\u6b62\u8acb\u6c42\u7e7c\u7e8c\u9001\u5f80\u6545\u969c\u4e2d\u7684\u4e0b\u6e38\u670d\u52d9\u3002\u4f60\u7684 API \u9598\u9053\u6703\u57f7\u884c\u4e00\u500b\u5165\u7ad9\u7b56\u7565\u4f86\u6aa2\u67e5\u65b7\u8def\u5668\u72c0\u614b\uff0c\u4e5f\u6703\u57f7\u884c\u4e00\u500b\u51fa\u7ad9\u7b56\u7565\u4f86\u66f4\u65b0\u8a72\u72c0\u614b\u3002\u9019\u500b\u72c0\u614b\u6a5f\u6703\u5728\u4e09\u7a2e\u72c0\u614b\u4e4b\u9593\u5207\u63db\uff1aclosed\u3001open \u548c half-open\u3002\u5b83\u8207\u901f\u7387\u9650\u5236\u5f62\u6210\u4e92\u88dc\uff1a\u901f\u7387\u9650\u5236\u5728\u5165\u53e3\u8655\u63a7\u5236\u8acb\u6c42\u91cf\uff1b\u65b7\u8def\u5668\u5247\u5728\u547c\u53eb\u93c8\u4e2d\u6bb5\u963b\u65b7\u6d41\u91cf\uff0c\u4f46\u524d\u63d0\u662f\u67d0\u500b\u670d\u52d9\u5df2\u7d93\u767c\u751f\u6545\u969c\u3002<\/p>\n<h3>\u5931\u6557\u9580\u6abb\u8207\u51b7\u537b\u6642\u9593<\/h3>\n<p>\u65b7\u8def\u5668\u4f9d\u8cf4\u591a\u500b\u95dc\u9375\u53c3\u6578\u3002\u5931\u6557\u9580\u6abb\u5b9a\u7fa9\u4e86\u9023\u7e8c\u5931\u6557\u591a\u5c11\u6b21\u5f8c\u5207\u63db\u5230 open \u72c0\u614b\u3002\u70ba\u4e86\u4fbf\u65bc\u5feb\u901f\u6e2c\u8a66\uff0c\u4f60\u53ef\u4ee5\u628a\u8a72\u503c\u8a2d\u70ba 3\uff1b\u5728\u6b63\u5f0f\u74b0\u5883\u4e2d\uff0c5 \u6b21\u9023\u7e8c\u5931\u6557\u901a\u5e38\u662f\u8f03\u5e73\u8861\u7684\u9078\u64c7\u3002\u9019\u500b\u8a2d\u5b9a\u65e2\u80fd\u907f\u514d\u56e0\u70ba\u77ed\u66ab\u7db2\u8def\u6296\u52d5\u800c\u8aa4\u5224\uff0c\u4e5f\u80fd\u5728\u771f\u6b63\u6545\u969c\u51fa\u73fe\u6642\u53ca\u6642\u5075\u6e2c\u3002\u903e\u6642\u6642\u9593\uff0c\u6216\u8005\u8aaa\u51b7\u537b\u6642\u9593\uff0c\u6c7a\u5b9a\u65b7\u8def\u5668\u5728 open \u72c0\u614b\u505c\u7559\u591a\u4e45\u5f8c\u624d\u5617\u8a66\u6062\u5fa9\u3002\u6b63\u5f0f\u74b0\u5883\u4e2d 60 \u79d2\u7684\u51b7\u537b\u6642\u9593\u901a\u5e38\u6bd4\u8f03\u5408\u9069\u2014\u2014\u8db3\u5920\u9577\uff0c\u53ef\u4ee5\u8b93\u5927\u591a\u6578\u670d\u52d9\u4f9b\u61c9\u5546\u6545\u969c\u5f97\u5230\u6062\u5fa9\uff1b\u53c8\u8db3\u5920\u77ed\uff0c\u4e0d\u81f3\u65bc\u5728\u77ed\u66ab\u7570\u5e38\u4e4b\u5f8c\u9577\u6642\u9593\u963b\u585e\u6d41\u91cf\u3002\u5982\u679c\u6062\u5fa9\u5617\u8a66\u5931\u6557\uff0cretry time period \u6703\u91cd\u65b0\u958b\u59cb\u8a08\u6642\u3002<\/p>\n<p>\u5728\u65b7\u8def\u5668\u8a2d\u5b9a\u4e2d\uff0c\u5982\u679c\u9580\u6abb\u8a2d\u5f97\u904e\u4f4e\uff0c\u5c31\u5bb9\u6613\u51fa\u73fe\u8aa4\u5831\u3002\u65b7\u8def\u5668\u6703\u56e0\u6b63\u5e38\u7684\u5c0f\u6ce2\u52d5\u800c\u88ab\u89f8\u767c\uff0c\u800c\u9019\u4e9b\u554f\u984c\u539f\u672c\u6703\u81ea\u884c\u6062\u5fa9\uff1b\u5982\u679c\u9580\u6abb\u8a2d\u5f97\u904e\u9ad8\uff0c\u53c8\u6703\u5c0e\u81f4\u5075\u6e2c\u904e\u6162\uff0c\u7cfb\u7d71\u5728\u53d7\u5230\u771f\u5be6\u640d\u5bb3\u5f8c\u624d\u958b\u59cb\u4fdd\u8b77\u3002\u56e0\u6b64\uff0c\u4f60\u5fc5\u9808\u6839\u64da\u5404\u81ea\u5c08\u6848\u7684\u5bb9\u932f\u80fd\u529b\u4f86\u8a2d\u5b9a\u9019\u4e9b\u503c\u3002<\/p>\n<h3>\u5229\u7528 Half-Open \u72c0\u614b\u9032\u884c\u5065\u5eb7\u6062\u5fa9<\/h3>\n<p>\u7576\u903e\u6642\u8a08\u6642\u5668\u5230\u671f\u5f8c\uff0c\u65b7\u8def\u5668\u6703\u5207\u63db\u5230 half-open \u72c0\u614b\u3002\u5728\u9019\u500b\u72c0\u614b\u4e0b\uff0c\u65b7\u8def\u5668\u53ea\u5141\u8a31\u5c11\u91cf\u63a2\u6e2c\u8acb\u6c42\u9001\u5f80\u4e0b\u6e38\u670d\u52d9\uff0c\u76ee\u7684\u662f\u6e2c\u8a66\u554f\u984c\u662f\u5426\u5df2\u7d93\u89e3\u6c7a\u3002\u5982\u679c\u9019\u4e9b\u63a2\u6e2c\u8acb\u6c42\u5168\u90e8\u6210\u529f\uff0c\u65b7\u8def\u5668\u5c31\u6703\u56de\u5230 closed \u72c0\u614b\uff0c\u7cfb\u7d71\u6062\u5fa9\u6b63\u5e38\u904b\u4f5c\uff0c\u540c\u6642\u5931\u6557\u8a08\u6578\u5668\u4e5f\u6703\u91cd\u8a2d\uff1b\u5982\u679c\u5176\u4e2d\u4efb\u610f\u4e00\u500b\u63a2\u6e2c\u8acb\u6c42\u5931\u6557\uff0c\u65b7\u8def\u5668\u5c31\u6703\u7acb\u5373\u91cd\u65b0\u56de\u5230 open \u72c0\u614b\uff0c\u4e26\u91cd\u65b0\u555f\u52d5\u903e\u6642\u8a08\u6642\u5668\u3002\u9019\u7a2e\u65b9\u5f0f\u53ef\u4ee5\u907f\u514d\u300c\u9a5a\u7fa4\u6548\u61c9\u300d\uff0c\u5426\u5247\u4e00\u500b\u5c1a\u672a\u5b8c\u5168\u6062\u5fa9\u7684\u670d\u52d9\u53ef\u80fd\u7a81\u7136\u518d\u6b21\u6536\u5230\u5927\u91cf\u8acb\u6c42\u3002<\/p>\n<p>half-open \u7684\u903e\u6642\u8a2d\u5b9a\u9700\u8981\u683c\u5916\u8b39\u614e\u3002\u5982\u679c retry time period \u8a2d\u5b9a\u5f97\u904e\u77ed\uff0c\u4f60\u53ef\u80fd\u6703\u53cd\u8986\u885d\u64ca\u5c1a\u672a\u6062\u5fa9\u7684\u670d\u52d9\uff1b\u5982\u679c\u8a2d\u5b9a\u5f97\u904e\u9577\uff0c\u53c8\u6703\u7121\u8b02\u5730\u963b\u585e\u672c\u53ef\u6b63\u5e38\u901a\u904e\u7684\u6d41\u91cf\u3002\u6e2c\u8a66\u6642\u7684\u6700\u4f73\u5be6\u52d9\u662f\u5f9e\u4fdd\u5b88\u503c\u958b\u59cb\uff0c\u4f8b\u5982\u4f7f\u7528\u6efe\u52d5\u8996\u7a97\u7d71\u8a08\u5931\u6557\u6b21\u6578\uff0c\u5982 60 \u79d2\u5167\u5931\u6557 5 \u6b21\uff0c\u518d\u6839\u64da\u5be6\u969b\u89c0\u5bdf\u9010\u6b65\u8abf\u6574\u3002<\/p>\n<p>\u4e0b\u8868\u7e3d\u7d50\u4e86\u72c0\u614b\u6a5f\u7684\u8f49\u63db\u908f\u8f2f\u3002<\/p>\n<div class=\"qc-default-table-wrapper \">\n<table style=\"min-width: 75px;\">\n<colgroup>\n<col style=\"min-width: 25px;\">\n<col style=\"min-width: 25px;\">\n<col style=\"min-width: 25px;\"><\/colgroup>\n<tbody>\n<tr>\n<th colspan=\"1\" rowspan=\"1\">\u72c0\u614b\u8f49\u63db<\/th>\n<th colspan=\"1\" rowspan=\"1\">\u89f8\u767c\u689d\u4ef6<\/th>\n<th colspan=\"1\" rowspan=\"1\">\u76f8\u95dc\u53c3\u6578<\/th>\n<\/tr>\n<tr>\n<td colspan=\"1\" rowspan=\"1\">Closed \u5230 Open<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u6efe\u52d5\u8996\u7a97\u5167\u7684\u5931\u6557\u6b21\u6578\u6216\u5931\u6557\u6bd4\u4f8b\u8d85\u904e\u9580\u6abb<\/td>\n<td colspan=\"1\" rowspan=\"1\">failureThreshold\u3001requestVolumeThreshold<\/td>\n<\/tr>\n<tr>\n<td colspan=\"1\" rowspan=\"1\">Open \u5230 Half-Open<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u903e\u6642\u8a08\u6642\u5668\u5230\u671f<\/td>\n<td colspan=\"1\" rowspan=\"1\">Timeout \u6216 cooldown period<\/td>\n<\/tr>\n<tr>\n<td colspan=\"1\" rowspan=\"1\">Half-Open \u5230 Closed<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u6240\u6709\u63a2\u6e2c\u8acb\u6c42\u5747\u6210\u529f<\/td>\n<td colspan=\"1\" rowspan=\"1\">successThreshold<\/td>\n<\/tr>\n<tr>\n<td colspan=\"1\" rowspan=\"1\">Half-Open \u5230 Open<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u4efb\u610f\u4e00\u500b\u63a2\u6e2c\u8acb\u6c42\u5931\u6557<\/td>\n<td colspan=\"1\" rowspan=\"1\">successThreshold<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<p>\u65b7\u8def\u5668\u8207\u901f\u7387\u9650\u5236\u662f\u5354\u540c\u904b\u4f5c\u7684\u3002\u901f\u7387\u9650\u5236\u5728\u6700\u524d\u7aef\u63a7\u5236\u8f38\u5165\u6d41\u91cf\uff1b\u65b7\u8def\u5668\u5247\u5728\u547c\u53eb\u93c8\u4e2d\u5207\u65b7\u6545\u969c\u50b3\u64ad\u3002\u7576\u65b7\u8def\u5668\u8655\u65bc open \u72c0\u614b\u6642\uff0c\u4e0d\u8981\u7e7c\u7e8c\u91cd\u8a66\uff0c\u5426\u5247\u53ea\u6703\u5c0e\u81f4\u91cd\u8a66\u98a8\u66b4\u548c\u66f4\u56b4\u91cd\u7684\u9023\u9396\u6545\u969c\u3002<\/p>\n<h2><strong>\u7d50\u5408\u5169\u7a2e\u6a21\u5f0f\u6253\u9020\u9ad8\u97cc\u6027 API<\/strong><\/h2>\n<h3>\u57f7\u884c\u9806\u5e8f\u8207\u7b56\u7565\u512a\u5148\u6b0a<\/h3>\n<p>\u73fe\u5728\u4f60\u5df2\u7d93\u64c1\u6709\u5169\u7a2e\u7b56\u7565\uff0c\u800c\u5b83\u5011\u7684\u57f7\u884c\u9806\u5e8f\u975e\u5e38\u95dc\u9375\u3002\u901f\u7387\u9650\u5236\u61c9\u5148\u5728\u9598\u9053\u5c64\u57f7\u884c\uff0c\u9019\u6a23\u53ef\u4ee5\u5728\u8acb\u6c42\u5360\u7528\u4efb\u4f55\u4e0b\u6e38\u8cc7\u6e90\u4e4b\u524d\uff0c\u5c31\u5148\u6514\u622a\u904e\u5ea6\u6d3b\u8e8d\u7684\u7528\u6236\u7aef\u3002\u65b7\u8def\u5668\u5247\u61c9\u5728\u547c\u53eb\u93c8\u66f4\u5f8c\u9762\u7684\u4f4d\u7f6e\u57f7\u884c\uff0c\u7528\u65bc\u963b\u6b62\u8acb\u6c42\u7e7c\u7e8c\u9001\u5f80\u5df2\u77e5\u6545\u969c\u4e2d\u7684\u670d\u52d9\u3002<\/p>\n<p>\u4e0b\u8868\u8aaa\u660e\u4e86\u6bcf\u7a2e\u6a21\u5f0f\u5982\u4f55\u70ba\u7cfb\u7d71\u97cc\u6027\u505a\u51fa\u8ca2\u737b\uff0c\u4ee5\u53ca\u70ba\u4ec0\u9ebc\u9019\u6a23\u7684\u9806\u5e8f\u66f4\u5408\u7406\u3002<\/p>\n<div class=\"qc-default-table-wrapper \">\n<table style=\"min-width: 75px;\">\n<colgroup>\n<col style=\"min-width: 25px;\">\n<col style=\"min-width: 25px;\">\n<col style=\"min-width: 25px;\"><\/colgroup>\n<tbody>\n<tr>\n<th colspan=\"1\" rowspan=\"1\">\u6a21\u5f0f<\/th>\n<th colspan=\"1\" rowspan=\"1\">\u4e3b\u8981\u97cc\u6027\u4f5c\u7528<\/th>\n<th colspan=\"1\" rowspan=\"1\">\u70ba\u4ec0\u9ebc\u5fc5\u9808\u8207\u53e6\u4e00\u7a2e\u6a21\u5f0f\u914d\u5408\u4f7f\u7528<\/th>\n<\/tr>\n<tr>\n<td colspan=\"1\" rowspan=\"1\">\u901f\u7387\u9650\u5236<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u4f9d\u6d88\u8cbb\u8005\u3001IP \u6216 API key \u9650\u5236\u8acb\u6c42\u901f\u7387<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u61c9\u5148\u65bc\u91cd\u8a66\u57f7\u884c\uff0c\u9019\u6a23\u91cd\u8a66\u4e0d\u6703\u6d88\u8017\u9650\u6d41\u914d\u984d<\/td>\n<\/tr>\n<tr>\n<td colspan=\"1\" rowspan=\"1\">\u65b7\u8def\u5668<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u6253\u958b\u65b7\u8def\u4ee5\u963b\u6b62\u91cd\u8a66\u98a8\u66b4<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u91cd\u8a66\u61c9\u767c\u751f\u5728\u65b7\u8def\u5668\u5167\u90e8\uff1b\u5982\u679c\u65b7\u8def\u5668\u5df2\u6253\u958b\uff0c\u7e7c\u7e8c\u91cd\u8a66\u6beb\u7121\u610f\u7fa9<\/td>\n<\/tr>\n<tr>\n<td colspan=\"1\" rowspan=\"1\">\u7d44\u5408\u9806\u5e8f<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u901f\u7387\u9650\u5236\uff0c\u7136\u5f8c\u91cd\u8a66\uff0c\u7136\u5f8c\u65b7\u8def\u5668<\/td>\n<td colspan=\"1\" rowspan=\"1\">\u78ba\u4fdd\u91cd\u8a66\u4e0d\u6703\u8017\u76e1\u914d\u984d\uff0c\u4e5f\u907f\u514d\u6301\u7e8c\u885d\u64ca\u6545\u969c\u670d\u52d9<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<p>\u5be6\u969b\u843d\u5730\u6642\u53ef\u4ee5\u9075\u5faa\u4e00\u500b\u6e05\u6670\u7684\u9806\u5e8f\uff1a\u5148\u52a0\u5165\u901f\u7387\u9650\u5236\uff0c\u56e0\u70ba\u5b83\u662f\u6700\u7c21\u55ae\u3001\u6548\u76ca\u4e5f\u6700\u5927\u7684\u6a21\u5f0f\uff1b\u7136\u5f8c\u70ba\u6bcf\u500b\u5f8c\u7aef\u9023\u7dda\u8a2d\u5b9a\u5408\u9069\u7684\u903e\u6642\u6642\u9593\uff1b\u63a5\u8457\u70ba\u95dc\u9375\u6216\u9ad8\u6545\u969c\u98a8\u96aa\u7684\u5f8c\u7aef\u5be6\u4f5c\u65b7\u8def\u5668\uff1b\u518d\u70ba\u8b80\u591a\u5beb\u5c11\u7684\u7aef\u9ede\u589e\u52a0\u5feb\u53d6\u964d\u7d1a\uff1b\u6700\u5f8c\u85c9\u7531\u9598\u9053\u53ef\u89c0\u6e2c\u6027\u8cc7\u6599\u6301\u7e8c\u76e3\u63a7\u8207\u8fed\u4ee3\u6700\u4f73\u5316\u3002<\/p>\n<h3>\u900f\u904e\u53ef\u89c0\u6e2c\u6027\u652f\u63f4\u6f38\u9032\u5f0f\u6062\u5fa9<\/h3>\n<p>\u4f60\u7121\u6cd5\u6700\u4f73\u5316\u770b\u4e0d\u898b\u7684\u554f\u984c\u3002\u61c9\u6301\u7e8c\u8ffd\u8e64\u6bcf\u500b\u76f8\u4f9d\u7684\u91cd\u8a66\u6b21\u6578\uff0c\u89c0\u5bdf\u65b7\u8def\u5668\u6253\u958b\u4e8b\u4ef6\u53ca\u5176\u6301\u7e8c\u6642\u9593\uff0c\u7d71\u8a08\u56e0\u9650\u6d41\u800c\u88ab\u62d2\u7d55\u6216\u5ef6\u9072\u7684\u8acb\u6c42\u6578\u91cf\uff0c\u6e2c\u91cf\u5e73\u5747\u56de\u61c9\u6642\u9593\u3001P95 \u8207 P99 \u5ef6\u9072\uff0c\u76e3\u63a7\u6bcf\u500b\u7aef\u9ede\u53ca\u6bcf\u500b\u5efa\u7f6e\u7248\u672c\u7684\u932f\u8aa4\u7387\uff0c\u6bd4\u8f03\u6bcf\u5206\u9418\u8acb\u6c42\u6578\u8207 429 \u56de\u61c9\u6578\uff0c\u8a18\u9304\u6bcf\u500b\u670d\u52d9\u7684\u65b7\u8def\u5668\u6253\u958b\u4e8b\u4ef6\uff0c\u4e26\u5728\u67d0\u500b\u7279\u5b9a\u76f8\u4f9d\u7684\u91cd\u8a66\u6b21\u6578\u7a81\u7136\u4e0a\u5347\u6642\u767c\u51fa\u8b66\u793a\u3002<\/p>\n<p>\u958b\u59cb\u6642\u61c9\u4fdd\u6301\u4fdd\u5b88\u3002\u8a2d\u5b9a\u8f03\u4f4e\u7684\u9650\u5236\u503c\u548c\u8f03\u4f4e\u7684\u5931\u6557\u9580\u6abb\uff0c\u5148\u89c0\u5bdf\u7cfb\u7d71\u884c\u70ba\u518d\u9010\u6b65\u8abf\u6574\u3002\u900f\u904e\u6e2c\u91cf\u5cf0\u503c\u9023\u7dda\u6578\u3001\u8acb\u6c42\u91cf\u8207\u932f\u8aa4\u7387\u4f86\u5efa\u7acb\u57fa\u6e96\uff0c\u518d\u628a\u521d\u59cb\u9580\u6abb\u8a2d\u70ba\u5cf0\u503c\u7684\u5169\u500d\uff0c\u4e26\u63a1\u7528\u9069\u5ea6\u7684\u7570\u5e38\u5075\u6e2c\u3002\u6301\u7e8c\u76e3\u63a7\u4e00\u5230\u5169\u9031\u5167\u7684\u6ea2\u51fa\u8207\u9a45\u9010\u60c5\u6cc1\uff1a\u5982\u679c\u6b63\u5e38\u6d41\u91cf\u4e0b\u6c92\u6709\u767c\u751f\u6ea2\u51fa\uff0c\u53ef\u9069\u5ea6\u6536\u7dca\u9580\u6abb\uff1b\u5982\u679c\u5408\u6cd5\u8acb\u6c42\u88ab\u62d2\u7d55\uff0c\u5247\u61c9\u9069\u5ea6\u653e\u5bec\u3002\u5728\u9810\u767c\u4f48\u74b0\u5883\u4e2d\u57f7\u884c\u58d3\u529b\u6e2c\u8a66\uff0c\u4ee5\u9a57\u8b49\u7cfb\u7d71\u5728\u6a21\u64ec\u904e\u8f09\u60c5\u5883\u4e0b\u7684\u4fdd\u8b77\u80fd\u529b\u3002\u7576\u6d41\u91cf\u6a21\u5f0f\u6216\u670d\u52d9\u5bb9\u91cf\u767c\u751f\u8b8a\u5316\u6642\uff0c\u61c9\u91cd\u8907\u9019\u4e00\u6700\u4f73\u5316\u9031\u671f\u3002<\/p>\n<div class=\"qc-divider-wrapper\">\n<div class=\"qc-divider\" style=\"border-top-style: solid; width: 100%; border-top-color: #d1d1d1;\"><\/div>\n<\/div>\n<p>\u901f\u7387\u9650\u5236\u63a7\u5236\u8acb\u6c42\u91cf\uff0c\u65b7\u8def\u5668\u8655\u7406\u670d\u52d9\u6545\u969c\u3002\u5169\u8005\u7d50\u5408\uff0c\u624d\u80fd\u5efa\u69cb\u4e00\u500b\u9ad8\u97cc\u6027\u7684 API \u9598\u9053\u3002\u73fe\u5728\uff0c\u4f60\u5df2\u7d93\u638c\u63e1\u4e86\u9019\u5169\u9805\u95dc\u9375\u80fd\u529b\u3002<\/p>\n<p>\u9580\u6abb\u61c9\u4f9d\u64da\u58d3\u529b\u6e2c\u8a66\u7d50\u679c\u548c\u6545\u969c\u76ee\u6a19\u4f86\u8a2d\u5b9a\uff0c\u800c\u4e0d\u662f\u6191\u611f\u89ba\u731c\u6e2c\u3002\u53ea\u6709\u5167\u90e8\u9650\u5236\uff0c\u624d\u80fd\u771f\u6b63\u5b9a\u7fa9\u4f60\u7684\u7cfb\u7d71\u7a76\u7adf\u80fd\u627f\u53d7\u591a\u5c11\u8ca0\u8f09\u3002<\/p>\n<p>\u5f9e\u4fdd\u5b88\u503c\u958b\u59cb\uff0c\u89c0\u5bdf\u53ef\u89c0\u6e2c\u6027\u8cc7\u6599\uff0c\u518d\u96a8\u8457\u771f\u5be6\u6d41\u91cf\u6a21\u5f0f\u9010\u6b65\u8abf\u6821\u3002\u65b7\u8def\u5668\u734e\u52f5\u7684\u662f\u8010\u5fc3\uff0c\u800c\u4e0d\u662f\u6fc0\u9032\u3002<\/p>\n<p>\u4eca\u5929\u5c31\u6aa2\u67e5\u4f60\u7684\u9598\u9053\u8a2d\u5b9a\u5427\u3002\u900f\u904e YAML \u6216\u7a0b\u5f0f\u78bc\u5957\u7528\u9019\u4e9b\u6a21\u5f0f\u3002\u4e0b\u4e00\u6b21\u6d41\u91cf\u9ad8\u5cf0\u6216\u670d\u52d9\u6545\u969c\u4e0d\u6703\u7b49\u4f60\u6e96\u5099\u597d\u3002\u8d81\u5b83\u5230\u4f86\u4e4b\u524d\uff0c\u5148\u628a\u4f60\u7684\u8acb\u6c42\u8655\u7406\u6a5f\u5236\u5efa\u7acb\u5b8c\u5584\u3002<\/p>\n<h2><strong>\u5e38\u898b\u554f\u984c<\/strong><\/h2>\n<h3>\u901f\u7387\u9650\u5236\u61c9\u8a72\u5148\u65bc\u65b7\u8def\u5668\u57f7\u884c\u55ce\uff1f<\/h3>\n<p>\u662f\u7684\u3002\u61c9\u5148\u5728\u9598\u9053\u5c64\u57f7\u884c\u901f\u7387\u9650\u5236\uff0c\u9019\u6a23\u53ef\u4ee5\u5728 API \u547c\u53eb\u5360\u7528\u4e0b\u6e38\u5bb9\u91cf\u4e4b\u524d\uff0c\u5148\u9650\u5236\u9ad8\u983b\u7528\u6236\u7aef\u3002\u65b7\u8def\u5668\u5247\u5728\u547c\u53eb\u93c8\u5f8c\u7e8c\u968e\u6bb5\u57f7\u884c\u3002\u9019\u6a23\u7684\u9806\u5e8f\u53ef\u4ee5\u9632\u6b62\u91cd\u8a66\u6d88\u8017\u4f60\u7684\u9650\u6d41\u914d\u984d\uff0c\u4e5f\u80fd\u907f\u514d\u6545\u969c\u670d\u52d9\u7e7c\u7e8c\u627f\u53d7\u66f4\u591a\u8ca0\u8f09\u3002<\/p>\n<h3>\u6211\u8a72\u5982\u4f55\u70ba\u65b7\u8def\u5668\u9078\u64c7\u5931\u6557\u9580\u6abb\uff1f<\/h3>\n<p>\u53ef\u4ee5\u5f9e 5 \u6b21\u9023\u7e8c\u5931\u6557\u548c 60 \u79d2\u51b7\u537b\u6642\u9593\u958b\u59cb\u3002\u89c0\u5bdf\u932f\u8aa4\u7387\u548c\u4f47\u5217\u6df1\u5ea6\uff1a\u5982\u679c\u611f\u89ba\u5075\u6e2c\u592a\u6162\uff0c\u5c31\u964d\u4f4e\u9580\u6abb\uff1b\u5982\u679c\u6b63\u5e38\u5c0f\u6ce2\u52d5\u5c31\u6703\u89f8\u767c\u65b7\u8def\u5668\uff0c\u5c31\u63d0\u9ad8\u9580\u6abb\u3002\u8acb\u900f\u904e\u58d3\u529b\u6e2c\u8a66\u4f86\u8abf\u6821\uff0c\u800c\u4e0d\u662f\u6191\u76f4\u89ba\u6c7a\u5b9a\u3002<\/p>\n<h3>HTTP 429 \u5c0d\u7528\u6236\u7aef\u610f\u5473\u8457\u4ec0\u9ebc\uff1f<\/h3>\n<p>HTTP 429 \u8868\u793a\u7528\u6236\u7aef\u9001\u51fa\u4e86\u904e\u591a\u8acb\u6c42\u3002\u9598\u9053\u6703\u62d2\u7d55\u8d85\u51fa\u7684\u8acb\u6c42\uff0c\u4e26\u56de\u50b3 Retry-After \u6a19\u982d\u3002\u4f60\u61c9\u8a72\u5728\u6587\u4ef6\u4e2d\u8aaa\u660e\u9019\u500b\u56de\u61c9\u6a19\u982d\u7684\u542b\u7fa9\uff0c\u9019\u6a23\u7528\u6236\u7aef\u5c31\u6703\u9078\u64c7\u9000\u907f\u91cd\u8a66\uff0c\u800c\u4e0d\u662f\u7e7c\u7e8c\u885d\u64ca\u4f60\u7684\u7aef\u9ede\u3002<\/p>\n<h3>\u6211\u771f\u7684\u9700\u8981\u540c\u6642\u4f7f\u7528\u9019\u5169\u7a2e\u6a21\u5f0f\u55ce\uff1f<\/h3>\n<p>\u9700\u8981\u3002\u901f\u7387\u9650\u5236\u63a7\u5236\u5165\u7ad9\u6d41\u91cf\u4e0a\u9650\uff1b\u65b7\u8def\u5668\u9694\u96e2\u6545\u969c\u76f8\u4f9d\u3002\u524d\u8005\u6c7a\u5b9a\u6709\u591a\u5c11\u6d41\u91cf\u9032\u5165\u7cfb\u7d71\uff0c\u5f8c\u8005\u6c7a\u5b9a\u9019\u4e9b\u6d41\u91cf\u662f\u5426\u61c9\u8a72\u7e7c\u7e8c\u5230\u9054\u5df2\u6545\u969c\u7684\u670d\u52d9\u3002\u5169\u8005\u7d50\u5408\uff0c\u624d\u80fd\u540c\u6642\u9632\u6b62\u904e\u8f09\u8207\u9023\u9396\u6545\u969c\u3002[\/vc_column_text][\/vc_column][\/vc_row]<\/p>\n<\/div>","protected":false},"excerpt":{"rendered":"<p>[vc_row][vc_column][vc_column_text css=&#8221;&#8221;]\u8a2d [&#8230;]<\/p>\n<p><a class=\"btn btn-secondary understrap-read-more-link\" href=\"https:\/\/www.simcentric.com\/tc\/america-dedicated-server-tc\/configure-rate-limiting-and-circuit-breaking-in-api-gateways\/\">Read More&#8230;<\/a><\/p>\n","protected":false},"author":1,"featured_media":34655,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[4815],"tags":[13292,13293,13294,13295,6817],"class_list":["post-34657","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-america-dedicated-server-tc","tag-api-gateway","tag-circuit-breaker","tag-redis-throttling","tag-microservice-fault-tolerance","tag-rate-limiting-tc"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>\u5728 API \u9598\u9053\u4e2d\u8a2d\u5b9a\u901f\u7387\u9650\u5236\u8207\u65b7\u8def\u5668<\/title>\n<meta name=\"description\" content=\"\u8a2d\u5b9a\u901f\u7387\u9650\u5236\uff08\u4f7f\u7528\u6b0a\u6756\u6876\u6f14\u7b97\u6cd5\uff09\u548c\u65b7\u8def\u5668\uff08\u4f7f\u7528\u72c0\u614b\u6a5f\uff09\uff0c\u4fdd\u8b77\u4f60\u7684 API \u9598\u9053\u514d\u53d7\u6d41\u91cf\u7a81\u589e\u8207\u6545\u969c\u5f71\u97ff\u3002\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.simcentric.com\/tc\/wp-json\/wp\/v2\/posts\/34657\" \/>\n<meta property=\"og:locale\" content=\"zh_TW\" \/>\n<meta property=\"og:type\" content=\"company\" \/>\n<meta property=\"og:title\" content=\"\u5728 API \u9598\u9053\u4e2d\u8a2d\u5b9a\u901f\u7387\u9650\u5236\u8207\u65b7\u8def\u5668\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.simcentric.com\/tc\/wp-json\/wp\/v2\/posts\/34657\" \/>\n<meta property=\"og:site_name\" content=\"\u65b0\u5929\u57df\u4e92\u806f\" \/>\n<meta property=\"article:published_time\" content=\"2026-09-15T06:37:58+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2026-09-15T06:42:07+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.simcentric.com\/wp-content\/uploads\/2026\/09\/Picture1-4.png\" \/>\n\t<meta property=\"og:image:width\" content=\"623\" \/>\n\t<meta property=\"og:image:height\" content=\"416\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"\u5728 API \u9598\u9053\u4e2d\u8a2d\u5b9a\u901f\u7387\u9650\u5236\u8207\u65b7\u8def\u5668","description":"\u8a2d\u5b9a\u901f\u7387\u9650\u5236\uff08\u4f7f\u7528\u6b0a\u6756\u6876\u6f14\u7b97\u6cd5\uff09\u548c\u65b7\u8def\u5668\uff08\u4f7f\u7528\u72c0\u614b\u6a5f\uff09\uff0c\u4fdd\u8b77\u4f60\u7684 API \u9598\u9053\u514d\u53d7\u6d41\u91cf\u7a81\u589e\u8207\u6545\u969c\u5f71\u97ff\u3002","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.simcentric.com\/tc\/wp-json\/wp\/v2\/posts\/34657","og_locale":"zh_TW","og_type":"company","og_title":"\u5728 API \u9598\u9053\u4e2d\u8a2d\u5b9a\u901f\u7387\u9650\u5236\u8207\u65b7\u8def\u5668","og_url":"https:\/\/www.simcentric.com\/tc\/wp-json\/wp\/v2\/posts\/34657","og_site_name":"\u65b0\u5929\u57df\u4e92\u806f","article_published_time":"2026-09-15T06:37:58+00:00","article_modified_time":"2026-09-15T06:42:07+00:00","og_image":[{"width":623,"height":416,"url":"https:\/\/www.simcentric.com\/wp-content\/uploads\/2026\/09\/Picture1-4.png","type":"image\/png"}],"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.simcentric.com\/tc\/america-dedicated-server-tc\/configure-rate-limiting-and-circuit-breaking-in-api-gateways\/#article","isPartOf":{"@id":"https:\/\/www.simcentric.com\/tc\/america-dedicated-server-tc\/configure-rate-limiting-and-circuit-breaking-in-api-gateways\/"},"author":{"name":"Tommy Cheung","@id":"https:\/\/simcentric.com\/tc\/#\/schema\/person\/631e153fdae3d1c71e500611868451e8"},"headline":"\u5728 API \u9598\u9053\u4e2d\u8a2d\u5b9a\u901f\u7387\u9650\u5236\u8207\u65b7\u8def\u5668","datePublished":"2026-09-15T06:37:58+00:00","dateModified":"2026-09-15T06:42:07+00:00","mainEntityOfPage":{"@id":"https:\/\/www.simcentric.com\/tc\/america-dedicated-server-tc\/configure-rate-limiting-and-circuit-breaking-in-api-gateways\/"},"wordCount":105,"publisher":{"@id":"https:\/\/simcentric.com\/tc\/#organization"},"image":{"@id":"https:\/\/www.simcentric.com\/tc\/america-dedicated-server-tc\/configure-rate-limiting-and-circuit-breaking-in-api-gateways\/#primaryimage"},"thumbnailUrl":"https:\/\/www.simcentric.com\/wp-content\/uploads\/2026\/09\/Picture1-4.png","keywords":["API \u9598\u9053","\u65b7\u8def\u5668","Redis \u9650\u6d41","\u5fae\u670d\u52d9\u5bb9\u932f","\u901f\u7387\u9650\u5236"],"articleSection":["\u7f8e\u570b\u4f3a\u670d\u5668"],"inLanguage":"zh-HK"},{"@type":"WebPage","@id":"https:\/\/www.simcentric.com\/tc\/america-dedicated-server-tc\/configure-rate-limiting-and-circuit-breaking-in-api-gateways\/","url":"https:\/\/www.simcentric.com\/tc\/america-dedicated-server-tc\/configure-rate-limiting-and-circuit-breaking-in-api-gateways\/","name":"\u5728 API \u9598\u9053\u4e2d\u8a2d\u5b9a\u901f\u7387\u9650\u5236\u8207\u65b7\u8def\u5668","isPartOf":{"@id":"https:\/\/simcentric.com\/tc\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.simcentric.com\/tc\/america-dedicated-server-tc\/configure-rate-limiting-and-circuit-breaking-in-api-gateways\/#primaryimage"},"image":{"@id":"https:\/\/www.simcentric.com\/tc\/america-dedicated-server-tc\/configure-rate-limiting-and-circuit-breaking-in-api-gateways\/#primaryimage"},"thumbnailUrl":"https:\/\/www.simcentric.com\/wp-content\/uploads\/2026\/09\/Picture1-4.png","datePublished":"2026-09-15T06:37:58+00:00","dateModified":"2026-09-15T06:42:07+00:00","description":"\u8a2d\u5b9a\u901f\u7387\u9650\u5236\uff08\u4f7f\u7528\u6b0a\u6756\u6876\u6f14\u7b97\u6cd5\uff09\u548c\u65b7\u8def\u5668\uff08\u4f7f\u7528\u72c0\u614b\u6a5f\uff09\uff0c\u4fdd\u8b77\u4f60\u7684 API \u9598\u9053\u514d\u53d7\u6d41\u91cf\u7a81\u589e\u8207\u6545\u969c\u5f71\u97ff\u3002","breadcrumb":{"@id":"https:\/\/www.simcentric.com\/tc\/america-dedicated-server-tc\/configure-rate-limiting-and-circuit-breaking-in-api-gateways\/#breadcrumb"},"inLanguage":"zh-HK","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.simcentric.com\/tc\/america-dedicated-server-tc\/configure-rate-limiting-and-circuit-breaking-in-api-gateways\/"]}]},{"@type":"ImageObject","inLanguage":"zh-HK","@id":"https:\/\/www.simcentric.com\/tc\/america-dedicated-server-tc\/configure-rate-limiting-and-circuit-breaking-in-api-gateways\/#primaryimage","url":"https:\/\/www.simcentric.com\/wp-content\/uploads\/2026\/09\/Picture1-4.png","contentUrl":"https:\/\/www.simcentric.com\/wp-content\/uploads\/2026\/09\/Picture1-4.png","width":623,"height":416,"caption":"API \u9598\u9053\u4e2d\u7684\u901f\u7387\u9650\u5236\u8207\u65b7\u8def\u5668\u793a\u610f\u5716"},{"@type":"BreadcrumbList","@id":"https:\/\/www.simcentric.com\/tc\/america-dedicated-server-tc\/configure-rate-limiting-and-circuit-breaking-in-api-gateways\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.simcentric.com\/tc\/"},{"@type":"ListItem","position":2,"name":"\u5728 API \u9598\u9053\u4e2d\u8a2d\u5b9a\u901f\u7387\u9650\u5236\u8207\u65b7\u8def\u5668"}]},{"@type":"WebSite","@id":"https:\/\/simcentric.com\/tc\/#website","url":"https:\/\/simcentric.com\/tc\/","name":"Simcentric Solutions","description":"","publisher":{"@id":"https:\/\/simcentric.com\/tc\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/simcentric.com\/tc\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"zh-HK"},{"@type":"Organization","@id":"https:\/\/simcentric.com\/tc\/#organization","name":"Simcentric Solutions","url":"https:\/\/simcentric.com\/tc\/","logo":{"@type":"ImageObject","inLanguage":"zh-HK","@id":"https:\/\/simcentric.com\/tc\/#\/schema\/logo\/image\/","url":"https:\/\/www.simcentric.com\/wp-content\/uploads\/2023\/06\/sim-logo-2023.png","contentUrl":"https:\/\/www.simcentric.com\/wp-content\/uploads\/2023\/06\/sim-logo-2023.png","width":800,"height":222,"caption":"Simcentric Solutions"},"image":{"@id":"https:\/\/simcentric.com\/tc\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/simcentric.com\/tc\/#\/schema\/person\/631e153fdae3d1c71e500611868451e8","name":"Tommy Cheung","image":{"@type":"ImageObject","inLanguage":"zh-HK","@id":"https:\/\/secure.gravatar.com\/avatar\/a2e7d94371b76574e2ddc0f18834f815c0329507429c6613f6a7bc9435dc6fd2?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/a2e7d94371b76574e2ddc0f18834f815c0329507429c6613f6a7bc9435dc6fd2?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/a2e7d94371b76574e2ddc0f18834f815c0329507429c6613f6a7bc9435dc6fd2?s=96&d=mm&r=g","caption":"Tommy Cheung"},"sameAs":["https:\/\/simrevamp2023.sim-dp.com"]}]}},"_links":{"self":[{"href":"https:\/\/www.simcentric.com\/tc\/wp-json\/wp\/v2\/posts\/34657","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.simcentric.com\/tc\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.simcentric.com\/tc\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.simcentric.com\/tc\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.simcentric.com\/tc\/wp-json\/wp\/v2\/comments?post=34657"}],"version-history":[{"count":2,"href":"https:\/\/www.simcentric.com\/tc\/wp-json\/wp\/v2\/posts\/34657\/revisions"}],"predecessor-version":[{"id":34660,"href":"https:\/\/www.simcentric.com\/tc\/wp-json\/wp\/v2\/posts\/34657\/revisions\/34660"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.simcentric.com\/tc\/wp-json\/wp\/v2\/media\/34655"}],"wp:attachment":[{"href":"https:\/\/www.simcentric.com\/tc\/wp-json\/wp\/v2\/media?parent=34657"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.simcentric.com\/tc\/wp-json\/wp\/v2\/categories?post=34657"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.simcentric.com\/tc\/wp-json\/wp\/v2\/tags?post=34657"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}