Commit e26be66a authored by 朱允伟's avatar 朱允伟

<fix> 网关限流添加打印日志

parent 735b5728
......@@ -46,12 +46,11 @@ public class RefreshApiLimitSchedule {
try {
JSONObject jo = new JSONObject(queryResult);
JSONArray data = jo.getJSONArray("data");
ApiLimitCache.BUCKET_CACHE.clear();
for (int i = 0; i < data.length(); i++) {
JSONObject o = (JSONObject) data.get(i);
String name = o.get("name").toString();
Integer singleLimit = Integer.parseInt(o.get("single_limit").toString());
log.info("接口{}限流次数{}",name, singleLimit);
// log.info("接口{}限流次数{}",name, singleLimit);
//桶的最大容量,即能装载 Token 的最大数量
int capacity = singleLimit;
//每次 Token 补充量
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment