Package com.tangosol.net
Interface Guardian
public interface Guardian
A Guardian is responsible for monitoring the registered
Guardable
objects.- Since:
- Coherence 3.5
- Author:
- rhl
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic interface
A GuardContext represents the lifecycle status of a Guardable. -
Method Summary
Modifier and TypeMethodDescriptionfloat
Default recovery percentage for Guardables monitored by this Guardian.long
Default timeout interval (in milliseconds) for Guardables monitored by this Guardian.Register the specified Guardable based on the Guardian's SLA parameters.Register the specified Guardable with the specified SLA parameters.
-
Method Details
-
guard
Register the specified Guardable based on the Guardian's SLA parameters.It's possible that the Guardian's defaults will prevent the Guardable from being registered. In such a case, this method returns null.
- Parameters:
guardable
- the Guardable to be monitored by this Guardian- Returns:
- the GuardContext for the specified Guardable (could be null)
-
guard
Register the specified Guardable with the specified SLA parameters.- Parameters:
guardable
- the Guardable to be guarded by this GuardiancMillis
- the timeout for the specified GuardableflPctRecover
- the percentage of the timeout after which to attempt recovery of the Guardable; 0 < flPctRecover <= 1.0- Returns:
- the GuardContext for the specified Guardable
-
getDefaultGuardTimeout
long getDefaultGuardTimeout()Default timeout interval (in milliseconds) for Guardables monitored by this Guardian.- Returns:
- the default timeout interval
-
getDefaultGuardRecovery
float getDefaultGuardRecovery()Default recovery percentage for Guardables monitored by this Guardian.- Returns:
- the default recovery percentage
-