public class NetworkDiagnostics
extends java.util.Observable
implements java.lang.AutoCloseable
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
OS_STATUS_BADFCVERSION |
static java.lang.String |
OS_STATUS_THIRDPARTY |
static java.lang.String |
OS_STATUS_UNKNOWN |
| Modifier | Constructor and Description |
|---|---|
protected |
NetworkDiagnostics(boolean isUnitTest,
int unitTestMtuSize) |
|
NetworkDiagnostics(NetworkDiagnosticsData diagnosticData) |
|
NetworkDiagnostics(java.lang.String host,
int port,
boolean useSSL,
boolean enableAuth,
java.util.function.Supplier<ClientCredentials> credentials,
boolean useServlet,
java.lang.String servletLocation) |
| Modifier and Type | Method and Description |
|---|---|
int[] |
calculateOptimalDiskParameters(int rtt,
int maxBandwidth) |
void |
close() |
java.lang.String |
getAgentID() |
int |
getClientIdentifier() |
int |
getClientSubIdentifier() |
java.lang.String |
getHost() |
int |
getMaxSupportedUnitSize() |
int |
getPathMTU(java.lang.String host) |
int |
getProgress() |
java.lang.String |
getSiteOS() |
java.lang.String |
getStatus() |
protected FCClientEngine |
getTestEngine() |
protected FCClientEngine |
getTestEngine(boolean useEnableAuth) |
boolean |
isFileCatalystServer() |
boolean |
isFirewallBlockingIncomingUDP(int udpPort) |
boolean |
isFirewallBlockingOutgoingUDP() |
boolean |
isSupportsUDP() |
protected void |
quitTestEngine(FCClientEngine test) |
void |
setClientConnectKey(java.lang.String clientConnectKey) |
void |
setClientIdentifier(int clientIdentifier) |
void |
setClientSubIdentifier(int clientSubIdentifier) |
protected void |
setUnitTest(boolean ut) |
protected void |
setUnitTestMTU(int mtu) |
void |
testControl() |
boolean |
testMultiStreamTCPDataConnections() |
boolean |
testPacket(java.lang.String host,
int packetSize)
Test if a packet of the given size can travel to the destination unfragmented
|
double |
testPacketLoss() |
double |
testPacketLoss(int packetSize,
int numPackets,
int rate) |
long |
testRTT()
Calculates time for a round trip to server, returns time in milliseconds.
|
boolean |
testSingleStreamTCPDataConnections() |
boolean |
testSingleStreamTCPDataConnections(boolean portFallback) |
java.lang.String |
toString() |
public static final java.lang.String OS_STATUS_UNKNOWN
public static final java.lang.String OS_STATUS_BADFCVERSION
public static final java.lang.String OS_STATUS_THIRDPARTY
protected NetworkDiagnostics(boolean isUnitTest,
int unitTestMtuSize)
public NetworkDiagnostics(java.lang.String host,
int port,
boolean useSSL,
boolean enableAuth,
java.util.function.Supplier<ClientCredentials> credentials,
boolean useServlet,
java.lang.String servletLocation)
public NetworkDiagnostics(NetworkDiagnosticsData diagnosticData)
public java.lang.String toString()
toString in class java.lang.Objectpublic void testControl()
throws java.lang.Exception
java.lang.Exceptionpublic long testRTT()
throws java.lang.Exception
java.lang.Exceptionpublic double testPacketLoss()
throws java.lang.Exception
java.lang.Exceptionpublic double testPacketLoss(int packetSize,
int numPackets,
int rate)
throws java.lang.Exception
packetSize - numPackets - rate - java.lang.Exceptionpublic int getMaxSupportedUnitSize()
throws java.lang.Exception
java.lang.Exceptionpublic boolean testSingleStreamTCPDataConnections()
public boolean testSingleStreamTCPDataConnections(boolean portFallback)
public boolean testMultiStreamTCPDataConnections()
public boolean isFirewallBlockingOutgoingUDP()
public boolean isFileCatalystServer()
throws java.lang.Exception
java.lang.Exceptionpublic boolean isFirewallBlockingIncomingUDP(int udpPort)
protected void quitTestEngine(FCClientEngine test) throws java.io.IOException, FCException
java.io.IOExceptionFCExceptionprotected FCClientEngine getTestEngine() throws java.io.IOException, FCException
java.io.IOExceptionFCExceptionprotected FCClientEngine getTestEngine(boolean useEnableAuth) throws java.io.IOException, FCException
java.io.IOExceptionFCExceptionpublic int getPathMTU(java.lang.String host)
throws java.lang.Exception
java.lang.Exceptionpublic int[] calculateOptimalDiskParameters(int rtt,
int maxBandwidth)
public boolean testPacket(java.lang.String host,
int packetSize)
throws java.lang.Exception
host - destinationpacketSize - Size of packet in bytes INCLUDING the 8 byte ICMP header and the 20 byte IP headerjava.lang.Exceptionpublic int getProgress()
public java.lang.String getStatus()
public void setClientConnectKey(java.lang.String clientConnectKey)
public int getClientIdentifier()
public void setClientIdentifier(int clientIdentifier)
clientIdentifier - the clientIdentifier to setpublic int getClientSubIdentifier()
public void setClientSubIdentifier(int clientSubIdentifier)
public java.lang.String getHost()
public boolean isSupportsUDP()
public java.lang.String getSiteOS()
public java.lang.String getAgentID()
protected void setUnitTest(boolean ut)
protected void setUnitTestMTU(int mtu)
public void close()
close in interface java.lang.AutoCloseable