com.yammer.metrics.util
Class DeadlockHealthCheck

java.lang.Object
  extended by com.yammer.metrics.core.HealthCheck
      extended by com.yammer.metrics.util.DeadlockHealthCheck

public class DeadlockHealthCheck
extends HealthCheck

A HealthCheck implementation which returns a list of deadlocked threads, if any.


Nested Class Summary
 
Nested classes/interfaces inherited from class com.yammer.metrics.core.HealthCheck
HealthCheck.Result
 
Constructor Summary
DeadlockHealthCheck()
          Creates a new DeadlockHealthCheck.
DeadlockHealthCheck(VirtualMachineMetrics vm)
          Creates a new DeadlockHealthCheck with the given VirtualMachineMetrics instance.
 
Method Summary
protected  HealthCheck.Result check()
          Perform a check of the application component.
 
Methods inherited from class com.yammer.metrics.core.HealthCheck
execute, getName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DeadlockHealthCheck

public DeadlockHealthCheck(VirtualMachineMetrics vm)
Creates a new DeadlockHealthCheck with the given VirtualMachineMetrics instance.

Parameters:
vm - a VirtualMachineMetrics instance

DeadlockHealthCheck

public DeadlockHealthCheck()
Creates a new DeadlockHealthCheck.

Method Detail

check

protected HealthCheck.Result check()
                            throws Exception
Description copied from class: HealthCheck
Perform a check of the application component.

Specified by:
check in class HealthCheck
Returns:
if the component is healthy, a healthy HealthCheck.Result; otherwise, an unhealthy HealthCheck.Result with a descriptive error message or exception
Throws:
Exception - if there is an unhandled error during the health check; this will result in a failed health check


Copyright © 2012. All Rights Reserved.