Package org.miaixz.bus.limiter.metric
Class ResourceManager
java.lang.Object
org.miaixz.bus.limiter.metric.ResourceManager
资源管理
- Since:
- Java 17+
- Author:
- Kimi Liu
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
ResourceManager
public ResourceManager()
-
-
Method Details
-
contain
判断资源是否是保护的- Parameters:
resourceKey- 资源标识- Returns:
- the true/false
-
add
添加到保护资源- Parameters:
resourceKey- 资源标识
-
entry
查看资源是否可以执行- Parameters:
resourceKey- 资源标识limiting- 限流注解- Returns:
- the true/false
- Throws:
IllegalStateException
-
isClear
public boolean isClear()清理- Returns:
- the true/false
-