public interface TunnelManagerFacade extends Service
| Modifier and Type | Method and Description |
|---|---|
boolean | addAlias(Destination dest,
ClientTunnelSettings settings,
Destination existingClient)Add another destination to the same tunnels. |
void | buildTunnels(Destination client,
ClientTunnelSettings settings)The client connected (or updated their settings), so make sure we have the tunnels
for them, and whenever necessary, ask them to authorize leases. |
void | fail(Hash peer) |
int | getFreeTunnelCount()how many free inbound tunnels do we have available? |
GhostPeerManager | getGhostPeerManager()Get the ghost peer manager for tracking peers with consistent tunnel build timeouts. |
int | getInboundBuildQueueSize()count how many inbound tunnel requests we have received but not yet processed |
Map<Hash,TunnelPool> | getInboundClientPools()for TunnelRenderer in router console |
int | getInboundClientTunnelCount()how many free inbound client tunnels do we have available? |
int | getInboundClientTunnelCount(Hash destination)how many inbound client tunnels in this pool? |
TunnelPool | getInboundExploratoryPool()for TunnelRenderer in router console |
TunnelPool | getInboundPool(Hash client) |
TunnelPoolSettings | getInboundSettings()getInboundSettings(). |
TunnelPoolSettings | getInboundSettings(Hash client)client). |
long | getLastParticipatingExpiration()When does the last tunnel we are participating in expire? |
Map<Hash,TunnelPool> | getOutboundClientPools()for TunnelRenderer in router console |
int | getOutboundClientTunnelCount()how many outbound client tunnels do we have available? |
int | getOutboundClientTunnelCount(Hash destination)how many outbound client tunnels in this pool? |
TunnelPool | getOutboundExploratoryPool()for TunnelRenderer in router console |
TunnelPool | getOutboundPool(Hash client) |
TunnelPoolSettings | getOutboundSettings()getOutboundSettings(). |
TunnelPoolSettings | getOutboundSettings(Hash client)client). |
int | getOutboundTunnelCount()how many outbound tunnels do we have available? |
int | getParticipatingCount()how many tunnels are we participating in? |
double | getShareRatio()getShareRatio(). |
boolean | isValidTunnel(Hash client,
TunnelInfo tunnel)Is a tunnel a valid member of the pool? |
void | listPools(List<TunnelPool> out)for TunnelRenderer in router console |
void | removeAlias(Destination dest)Remove another destination to the same tunnels. |
void | removeTunnels(Destination client)Must be called AFTER deregistration by the client manager. |
TunnelInfo | selectAnyInboundTunnel()Pick a random inbound tunnel from any pool — client pools first,
then exploratory. |
TunnelInfo | selectAnyOutboundTunnel()Pick a random outbound tunnel from any pool — client pools first,
then exploratory. |
TunnelInfo | selectInboundExploratoryTunnel(Hash closestTo)Pick the inbound exploratory tunnel with the gateway closest to the given hash. |
TunnelInfo | selectInboundTunnel()Pick a random inbound exploratory tunnel |
TunnelInfo | selectInboundTunnel(Hash destination)Pick a random inbound tunnel from the given destination's pool |
TunnelInfo | selectInboundTunnel(Hash destination,
Hash closestTo)Pick the inbound tunnel with the gateway closest to the given hash
from the given destination's pool. |
TunnelInfo | selectOutboundExploratoryTunnel(Hash closestTo)Pick the outbound exploratory tunnel with the endpoint closest to the given hash. |
TunnelInfo | selectOutboundTunnel()Pick a random outbound exploratory tunnel |
TunnelInfo | selectOutboundTunnel(Hash destination)Pick a random outbound tunnel from the given destination's pool |
TunnelInfo | selectOutboundTunnel(Hash destination,
Hash closestTo)Pick the outbound tunnel with the endpoint closest to the given hash
from the given destination's pool. |
Set<Hash> | selectPeersInTooManyTunnels() |
void | setInboundSettings(Hash client,
TunnelPoolSettings settings)settings). |
void | setInboundSettings(TunnelPoolSettings settings)settings). |
void | setOutboundSettings(Hash client,
TunnelPoolSettings settings)settings). |
void | setOutboundSettings(TunnelPoolSettings settings)settings). |
renderStatusHTML, restart, shutdown, startupboolean addAlias(Destination dest, ClientTunnelSettings settings, Destination existingClient)
IllegalArgumentException - if notvoid buildTunnels(Destination client, ClientTunnelSettings settings)
void fail(Hash peer)
int getFreeTunnelCount()
GhostPeerManager getGhostPeerManager()
int getInboundBuildQueueSize()
Map<Hash,TunnelPool> getInboundClientPools()
int getInboundClientTunnelCount()
int getInboundClientTunnelCount(Hash destination)
TunnelPool getInboundExploratoryPool()
TunnelPool getInboundPool(Hash client)
TunnelPoolSettings getInboundSettings()
TunnelPoolSettings getInboundSettings(Hash client)
long getLastParticipatingExpiration()
Map<Hash,TunnelPool> getOutboundClientPools()
int getOutboundClientTunnelCount()
int getOutboundClientTunnelCount(Hash destination)
TunnelPool getOutboundExploratoryPool()
TunnelPool getOutboundPool(Hash client)
TunnelPoolSettings getOutboundSettings()
TunnelPoolSettings getOutboundSettings(Hash client)
int getOutboundTunnelCount()
int getParticipatingCount()
double getShareRatio()
boolean isValidTunnel(Hash client, TunnelInfo tunnel)
void listPools(List<TunnelPool> out)
void removeAlias(Destination dest)
void removeTunnels(Destination client)
TunnelInfo selectAnyInboundTunnel()
TunnelInfo selectAnyOutboundTunnel()
TunnelInfo selectInboundExploratoryTunnel(Hash closestTo)
closestTo - non-nullTunnelInfo selectInboundTunnel()
TunnelInfo selectInboundTunnel(Hash destination)
destination - if null, returns inbound exploratory tunnelTunnelInfo selectInboundTunnel(Hash destination, Hash closestTo)
destination - if null, returns inbound exploratory tunnelclosestTo - non-nullTunnelInfo selectOutboundExploratoryTunnel(Hash closestTo)
closestTo - non-nullTunnelInfo selectOutboundTunnel()
TunnelInfo selectOutboundTunnel(Hash destination)
destination - if null, returns outbound exploratory tunnelTunnelInfo selectOutboundTunnel(Hash destination, Hash closestTo)
destination - if null, returns outbound exploratory tunnelclosestTo - non-nullSet<Hash> selectPeersInTooManyTunnels()
void setInboundSettings(Hash client, TunnelPoolSettings settings)
void setInboundSettings(TunnelPoolSettings settings)
void setOutboundSettings(Hash client, TunnelPoolSettings settings)
void setOutboundSettings(TunnelPoolSettings settings)