public class HintedHandOffManager extends java.lang.Object implements HintedHandOffManagerMBean
Modifier and Type | Field and Description |
---|---|
static HintedHandOffManager |
instance |
static java.lang.String |
MBEAN_NAME |
HintedHandoffMetrics |
metrics |
Constructor and Description |
---|
HintedHandOffManager() |
Modifier and Type | Method and Description |
---|---|
static int |
calculateHintTTL(RowMutation mutation) |
protected void |
compact() |
void |
deleteHintsForEndpoint(java.net.InetAddress endpoint) |
void |
deleteHintsForEndpoint(java.lang.String ipOrHostname)
Nuke all hints from this node to `ep`.
|
RowMutation |
hintFor(RowMutation mutation,
long now,
int ttl,
java.util.UUID targetId)
Returns a mutation representing a Hint to be sent to
targetId
as soon as it becomes available again. |
java.util.List<java.lang.String> |
listEndpointsPendingHints()
List all the endpoints that this node has hints for.
|
void |
pauseHintsDelivery(boolean b)
pause hints delivery process
|
void |
scheduleHintDelivery(java.net.InetAddress to,
boolean precompact) |
void |
scheduleHintDelivery(java.lang.String to)
force hint delivery to an endpoint
|
void |
start() |
void |
truncateAllHints()
Truncate all the hints
|
public static final java.lang.String MBEAN_NAME
public static final HintedHandOffManager instance
public final HintedHandoffMetrics metrics
public RowMutation hintFor(RowMutation mutation, long now, int ttl, java.util.UUID targetId)
targetId
as soon as it becomes available again.public static int calculateHintTTL(RowMutation mutation)
public void start()
public void deleteHintsForEndpoint(java.lang.String ipOrHostname)
HintedHandOffManagerMBean
deleteHintsForEndpoint
in interface HintedHandOffManagerMBean
ipOrHostname
- String rep. of endpoint address to delete hints for, either ip address ("127.0.0.1") or hostnamepublic void deleteHintsForEndpoint(java.net.InetAddress endpoint)
public void truncateAllHints() throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
HintedHandOffManagerMBean
truncateAllHints
in interface HintedHandOffManagerMBean
java.util.concurrent.ExecutionException
java.lang.InterruptedException
protected void compact()
public void scheduleHintDelivery(java.net.InetAddress to, boolean precompact)
public void scheduleHintDelivery(java.lang.String to) throws java.net.UnknownHostException
HintedHandOffManagerMBean
scheduleHintDelivery
in interface HintedHandOffManagerMBean
java.net.UnknownHostException
public void pauseHintsDelivery(boolean b)
HintedHandOffManagerMBean
pauseHintsDelivery
in interface HintedHandOffManagerMBean
public java.util.List<java.lang.String> listEndpointsPendingHints()
HintedHandOffManagerMBean
listEndpointsPendingHints
in interface HintedHandOffManagerMBean
Copyright © 2015 The Apache Software Foundation