类 OrderedHealthAggregator
- java.lang.Object
- org.springframework.boot.actuate.health.AbstractHealthAggregator
- org.springframework.boot.actuate.health.OrderedHealthAggregator
- 所有已实现的接口:
HealthAggregator
public class OrderedHealthAggregator extends AbstractHealthAggregator
DefaultHealthAggregator
implementation that aggregatesHealth
instances and determines the final system state based on a simple ordered list.If a different order is required or a new
Status
type will be used, the order can be set by callingsetStatusOrder(List)
.- 从以下版本开始:
- 1.1.0
构造器概要
构造器 构造器 说明 OrderedHealthAggregator()
Create a newOrderedHealthAggregator
instance.
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 protected Status
aggregateStatus(List<Status> candidates)
Return the single 'aggregate' status that should be used from the specified candidates.void
setStatusOrder(List<String> statusOrder)
Set the ordering of the status.void
setStatusOrder(Status... statusOrder)
Set the ordering of the status.从类继承的方法 org.springframework.boot.actuate.health.AbstractHealthAggregator
aggregate, aggregateDetails
构造器详细资料
OrderedHealthAggregator
public OrderedHealthAggregator()
Create a newOrderedHealthAggregator
instance.
方法详细资料
setStatusOrder
public void setStatusOrder(Status... statusOrder)
Set the ordering of the status.- 参数:
statusOrder
- an ordered list of the status
setStatusOrder
public void setStatusOrder(List<String> statusOrder)
Set the ordering of the status.- 参数:
statusOrder
- an ordered list of the status codes
aggregateStatus
protected Status aggregateStatus(List<Status> candidates)
从类复制的说明:AbstractHealthAggregator
Return the single 'aggregate' status that should be used from the specified candidates.- 指定者:
aggregateStatus
在类中AbstractHealthAggregator
- 参数:
candidates
- the candidates- 返回:
- a single status